passkit

Downloading PKPass in an iOS custom app from my server

孤街醉人 提交于 2020-01-03 03:06:31
问题 I've setup a server which returns a PKPass. If I copy the URL to the browser, a pass is shown (both in my Mac and in my iPhone). The code I'm using to download the pass is the following one: NSData *data = [[NSData alloc] initWithContentsOfURL:[NSURL URLWithString:kAPIPass]]; if (nil != data) { PKPass *pass = [[PKPass alloc] initWithData:data error:nil]; PKAddPassesViewController *pkvc = [[PKAddPassesViewController alloc] initWithPass:pass]; pkvc.delegate = self; [self presentViewController

Downloading PKPass in an iOS custom app from my server

孤街醉人 提交于 2020-01-03 03:05:57
问题 I've setup a server which returns a PKPass. If I copy the URL to the browser, a pass is shown (both in my Mac and in my iPhone). The code I'm using to download the pass is the following one: NSData *data = [[NSData alloc] initWithContentsOfURL:[NSURL URLWithString:kAPIPass]]; if (nil != data) { PKPass *pass = [[PKPass alloc] initWithData:data error:nil]; PKAddPassesViewController *pkvc = [[PKAddPassesViewController alloc] initWithPass:pass]; pkvc.delegate = self; [self presentViewController

passkit - pass not refreshing via push notification. (Server response was malformed)

半城伤御伤魂 提交于 2020-01-01 17:28:29
问题 I have successfully integrated passkit but I am facing issue when updating passbook via push notification. Notification successfully received to wallet but pass not updated. Following are steps which I have implemented: Used XMPP server (PHP). used this library in php to generate pass (https://github.com/tschoffelen/PHP-PKPass). I have replaced pass type and team identifier. Swift code to add pass to wallet. Pass successfully created and add to wallet. To refresh pass "pull to refresh" is

Apple Wallet Not Auto Updating Pass

醉酒当歌 提交于 2019-12-31 04:52:05
问题 Finally im able to push new changed compiled bundle. There is one issue im facing in order to see new changes. i have to go in my wallet card & disable "Automatic updates" then enable. then i can see my new compiled pass card. $result = $pdo->query($query); if($result->rowCount() > 0) { $myPass = $result->fetch(); $data = $myPass['data']; $nameFile = 'passbook_'.time().'.pkpass'; file_put_contents($nameFile, $data); $stream = function () use ($nameFile) { readfile($nameFile); }; return $app-

Which passes can I access in Apple Wallet

我们两清 提交于 2019-12-19 11:11:33
问题 I am new to iOS development and want to work on a small project using the PassKit library. After a lot of searching (Apple docs, stackoverflow) I just can't seem to get a clear understanding of possible answers to my question: "Is it possible to access passes that I did not create?" Now, I'm not talking about payment related passes like bank cards etc. I simply want an overview of things like event tickets, transportation passes and so on. Is there any way to achieve this? (with the users

How to create “Add to apple wallet” button using PKAddPassButton for passes with localisation

烂漫一生 提交于 2019-12-13 03:52:12
问题 In my iOS project I have a screen which allows the user to create apple passes and add it to the wallet. Apple recommends creating "Add to apple wallet" button using PKAddPassButton. When I tried creating apple pass using following code: let passButton = PKAddPassButton(addPassButtonStyle: PKAddPassButtonStyle.black) passButton.frame = CGRect(x:45.0, y: 340.0, width: 320, height: 50) view.addSubview(passButton) Button has got couple of issues: Wallet image is not visible. Even after changing

Update Passbook wallet failed to connect

旧城冷巷雨未停 提交于 2019-12-12 04:16:21
问题 i'm struck with update wallet push notiifcation,i used bellow code,server not connected error. I missed any credentials.please help to me ,fix this issue. I registered my passbook and get back pushtoken to server. this key same as the passbook generate certificate key. $certifile = 'passbook/certificates/AppleWWDRCA.pem'; $passphrase = 'xxxxxxxx'; $trust =''; $url = 'ssl://gateway.push.apple.com:2195'; $ctx = stream_context_create(); stream_context_set_option($ctx, 'ssl', 'local_cert',

How to debug iBeacons and Passbook

℡╲_俬逩灬. 提交于 2019-12-11 13:23:44
问题 I have a pass (which eveyrthing works on, pushs, registrations, pull to refresh, locations, etc) that I've created a Beacons array on. It has a dictionary with a UUID, message, major and minor for an Estimote iBeacon. "beacons": [ { "proximityUUID":"B9407F30-F5F8-466E-AFF9-25556B57FE6D", "major":5723, "minor":49600, "relevantText":"Welcome to goldstar" } ], I can see the iBeacon in the Estimote app, but I get no message on the lock screen for my Passbook. Is there a trick to this? Are there

Apple Wallet NFC-Enabled Pass use cases

僤鯓⒐⒋嵵緔 提交于 2019-12-11 06:35:27
问题 We are trying to bring Apple Wallet NFC-Enabled Pass based loyalty card program to a territory without Apple Pay support. In order to build a strong use case for Apple representatives we are trying to gather a list of merchants who are using Apple Wallet NFC-Enabled Passes without supporting Apple Pay. Both in territories with Apple Pay and without. Is it possible to support Apple Wallet NFC Passes without supporting Apple Pay? If yes, an example of someone doing it would be greatly

how to call the apple wallet from ios app using swift

淺唱寂寞╮ 提交于 2019-12-10 12:06:19
问题 I want to display apple wallet add cards page whenever user clicks the add cards to wallet button in my ios app. how to call the apple wallet from ios app. I enabled wallet capabilities in my ios app and also generate the wallet entitlements to my app. How to use PKAddPaymentPassViewControler using swift. please give some idea about it 回答1: NOTE: This is for Card Issuers only. If you want to redirect a user to add a payment method, use the openPaymentSetup method. See my answer here for more