iOS Passbook how to work with - ios

I try to work with passbook. SO as i understand from guide i need to create certificate, generate json and than i need to upload passbook to my server, after that if i open page in safari from iPhone i can see my own passbook in passbook app.
But is it way to get passbook on button click on my app without opening safari?
Please, correct me if i've error on work logic with passbook

Yes. You will need a server that can create the pass, and your app will need to call your server to request the pass. Then your app needs to use the PKPassViewController to display the pass to the user so the user can add it to their Passbook. See the Apple Passbook Programming Guide: https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/PassKit_PG/Chapters/Introduction.html

Related

How to invoke safari browser from wallet pass

I am trying to invoke safari from wallet pass. I did not get any clue how doing these. For wallet pass to invoke a custom app its asking for the app store identifier. We are unable to find the app store Id for mobile safari application. Please help me with this.

Apple Passbook(Wallet) device Registration not by app

I'm trying to build up a web service to push discount information to end-users. My question is that I know we can push coupon by my own app but is there any possible way to avoid end-user installing our app? Is there any possible way that we only use web service to get device_library_identifier from our users to push notification to apple passbooks?
Very Thanks!
Pkpass files can be downloaded from web pages, attached to emails or loaded via QR code, for example. You don't need to use an app to deliver them.
When a .pkpass file is added to a user's wallet, it will register itself with your webService and you can then push updates to the pass.
This web service is outlined in Apple's documentation and covers what you need to record the pass:
https://developer.apple.com/library/ios/documentation/PassKit/Reference/PassKit_WebService/WebService.html
The section under "Update a Pass" in Apple's Wallet Overview, explains how this works in the context of a pass
https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/PassKit_PG/Updating.html#//apple_ref/doc/uid/TP40012195-CH5-SW1
If normally you have new promotion to send coupon to customer time to time, you may start with member pass first so you can send link to download new coupon with notification to your member to load new coupon when they want without coming to your place to download new coupon.

How do I create a custom url scheme that will be recognized as a link?

My url scheme looks like "foo://".
This works great when I type into the browser.
The application requires I send this link in an e-mail and the e-mail opens from there. How can I configure the url scheme to be recognized as a link? I tried doing http://foo:// but of course my browser caught that.
One solution is to ping my server http://foo.com/redirect_to_app. If there is a way to do this with the app only I would like to know.
If you put the URL as foo:// in the email body, then that is all you need to do. Of course it requires that the user reads the email using the Mail app on their iOS device and the user must have your app installed on their iOS device as well.
Your foo:// URL will mean nothing if the email is read on a non-iOS device or computer or if the user doesn't have your app installed.
This all assumes that your goal is for one user of your app to send an email to another user of your app and tapping on the link in the email will launch your app on the receiver's iOS device.
There is a way. You need to create a webpage and create redirect code(url scheme) to your app.
Check this out... Check if URL scheme is supported in javascript

Exchange data between iOS apps

I know about x-callback-url, and how it's possible to e.g. send a string to an app in iOS.
But is it possible to do this the other way around, e.g is it possible for an iOS app to fetch the song currently playing in Music.app? Can an app fetch a message with a specific caller ID from Messages.app?
I believe, you need to have access to their API/backend to do that. Talking directly to another iOS app is not possible.
No, I'm not a crook ;) I want my app to read the content of an SMS that my gateway has sent, for device authorization.
register a scheme for your app. add a link with that scheme in your sms, with the registration code as uri-path. by clicking that should open your app and you can process the uri.

Facebook App Requests aren't shown on iOS devices?

I've sent an app invitation from an iPad app to a test Facebook account via Facebook's API. When I login to the test account on my PC, the app request is there.
When I login to the test account on my iPad (either via Safari or via the Facebook App), I can see the number "1" next to the App Centre tab, but when I click it and go to the App Centre, there's no request. In fact, I can't see any App Centre areas dedicated to requests on Facebook for iOS - there's only Social Picks and Top Apps. Any explanation for this?
This is caused by an incorrect configuration on the Facebook app setting page. When you are setting up the app, you need to make sure the following is set correctly.
Go to developers.facebook.com then select "Apps". Edit your app and fill in the following..
iOS App Bundle (dont think it's essential but fill it in, this the bundle id from Xcode (com.companyname.appname))
iPhone/iPad App Store ID - This is ESSENTIAL, one of these must be filled in with a valid app store ID. You get this when you create an app with iTunes Connect. If you create an app, and fill in the details right up to the point where it asks you to submit the binary, it will generate what Apple refers to as an Apple ID (or iTunes Id?). It's just a long integer value. It doesn't have to be for the corresponding app, if you already have apps in the app store just log in to iTunes connect and use an existing one for testing.
Configured for iOS SSO - Enabled
Configured for Deep Linking - Enabled
The only functionality you get from Facebook when a user clicks an app notification on iOS is the user being redirected to the app, if installed, or to the App Store if not. Also if you want your app notifications to show up on desktop, you'll need a Canvas URL under the "App On Facebook" section.
In my tests I had to have a canvas URL to get iOS notifications working, but I'm not sure if this is a bug with Facebook or intended behaviour, so if it doesn't work with just iOS enabled, enable app on Facebook too and stick in a random url if you don't have one.
I just figured there can be another reason for this symptom: if your app has location restriction (only available in certain countries), the user who receives the request has to be in that country (e.g. I had to connect with mine via GeoEdge).

Resources