Delve into the world of built-in app and system services available to developers. Discuss leveraging these services to enhance your app's functionality and user experience.

Post

Replies

Boosts

Views

Activity

Why isn't the user data being returned every time?
I am implementing Sign in with Apple using the JS framework.When the user (me, right now) signs in for the first time, I get data I need!The parameters look like thisParameters:{"state"=>"[state]", "code"=>"[code]", "id_token"=> "[jws token]", "user"=>"{\"email\":\"[the email I need]\"}"}My scope is just "email," I don't need (or want) their name.Next, I try signing in again (same everything)But, I get this optionWhen I click "continue" the data looks like thisParameters:{"state"=>"[state]", "code"=>"[code]", "id_token"=> "[id token]"}As you can tell, there is no user object, no email, nothing I can use!If I do the code response and get an access token, I can't use it. There's no public, known endpoints to just get the email they used. There's no point in storing the email if I can never check for it the next time they sign in.This is happening on multiple browsers on macOS 10.14.4.On my iPhone running iOS 13 developer beta 3, every time I click the button, I get the option to "share" or "hide" my email (even though, as shown above, I've sign in before), and sharing the email actually shares it, while hiding it.. well hides it.However, the user data is always there.This bug(?) only appears when clicking Continue, which I can assume appears on devices that aren't running iOS 13. It's quite a problem on devices that aren't this small set of devices, so I hope this is either known, easily fixable, or something! Thanks for any help you can provide.
40
1
26k
Jul ’19
apple-app-site-association not updating for my app, next update time in swcutil_show is in past
I am unable to get Universal Links opening in my app despite the fact that it is working for others.I used sysdiagnose to retrieve swcutil_show.txt and it shows the next update time for the entry in my app to be: 0001-01-01 03:54:56 +0000Which is in the past. I can't seem to be able to reset this entry even after uninstalling and reinstalling the app. Is there anyway to clear this entry on my device?I'm not sure how it got into this state, but I hope it's only me and not any of my end users.
8
0
7.1k
Oct ’19
verify the refresh token up to once a day
I saw the descriptionYou may verify the refresh token up to once a day to confirm that the user’s Apple ID on that device is still in good standing with Apple’s servers.in https://developer.apple.com/documentation/signinwithapplerestapi/verifying_a_user .I have two question about the description:Why should we verify the refresh token instead of access token to confirm the user's Apple ID is still in good standing with Apple's server?The doc said refresh token can only verify once a day. But i can verify refresh token multiple times in practice. Is there some conflict between documentation and implementation?https://www.dropbox.com/s/l6ncxxvumil6sfs/1571217862017.png?dl=0Update on 10/17/2019:For apps running on other systems, use the periodic successful verification of the refresh token to determine the lifetime of the user session.I also saw the description above in in https://developer.apple.com/documentation/signinwithapplerestapi/verifying_a_user . I think periodic is also conflict with once a day.
1
0
1.1k
Oct ’19
id_token not unique across platforms?
We've implementing SIWA on iOS and a web application using Sign in with Apple JS. I've setup a service ID tied to the application ID and can succesfully get callbacks on both platforms. I'm noticing that the user id provided by the iOS app is different than the id provided by the web application.We were expecting these to be different so we can store on our end and identify the user without having to use their email.
1
0
688
Oct ’19
Verifying JWS E256 signature using the server’s public key Apple sign-in
https://developer.apple.com/documentation/signinwithapplerestapi/verifying_a_userAs per the above link, to verify an IDToken signature, Apple's public key needs to be used.I am able to fetch Apple's public key, but I am unable to verify the signature of IDToken via the public key. I am trying to implement this in Java.. What exactly is meant by "JWS E256 signature"? Which algorithm?Also, once public key is fetched (sample PK posted below), which algorithm to use to form the public key? { "keys": [ { "kty": "RSA", "kid": "AIDOPK1", "use": "sig", "alg": "RS256", "n": "someValue", "e": "someValue" } ] }
3
0
7.8k
Nov ’19
Emulating NFC Tag using iPhone Device
I'm trying to transfer data from one device to another using NFC. I'm trying to figure out if this is possible, I downloaded apple's sample project about CoreNFC, I was able to read NFC Tags (it wasn't a real NFC Tag, rather it was an NFC Tag emulated with an android device). Can I use my iPhone to emulate an NFC Tag to transfer data to another iPhone or Android device?
16
4
27k
Feb ’20
Siri custom intent and watchOS
Hi there,We're working on a companion watchOS app for our main Application. The main app has already Siri Extension support and it works quite well: we are able to disambiguate our requests and let the INIntent open the main app once we've a correctly identified request.We saw that watchOS also has support for Siri and Siri extensions in a stand-alone way. Our idea was to port most of the work done with iOS onto watchOS.- Let's assume that the working iOS siri extension is called: SiriExtension. It handles quite well the siri interaction from the iPhone and it allows to open our main app into the specified task and/or do some work in the background. No issues here.- Let's assume, also, that the watchOS siri extension we are working on is called: SiriWatchExtension. It should replicate the work done by its counterpart on iOS, but on watchOS and without a direct interaction with the iOS device: just like a stand-alone app.What's unclear to us is how watchOS and Siri extensions works in respect to the counter part on iOS. Specifically:- We all know that, if we exclude some specific special apps, the main interaction with Siri is done with INIntents donations and Shortcut (pretty much like SoupChef example).- We couldn't see a clear way to add Shortcuts from the watchOS app. Seems that the Shortcuts from iOS are "magically" available also on watchOS, but that is somewhat "unidirectional". - The shortcut that we invoke from the watchOS is triggering the IntentHandler from iOS, not the one we built into watchOS. Is this an intended behaviour? Are we missing something?- Is there a way to donate an intent from watchOS to Shortcut and let this intent trigger just only when we're talking with our watch device?- Also, is there a way to complete an action into the watch app other then the iOS app?Many thanks for the patience, and sorry again for the very long post.--c.
2
0
1.2k
Feb ’20
(How) can I use AVAudioRecorder with(in) CarPlay?
Hi!Currently I'm experimenting with building an iOS app that allows a motorist (app user) to do the following;Activate the app by using Siri Shortcut;Open up a specific ViewController within the app;Start a record session automatically and record speech from the user by using the AVAudioRecorder;Stop record session automatically when the users stopped speaking;Upload the recording.Now, I found out that when the user has its iPhone connected to CarPlay, Siri doesn't allow users to open an app that doesn't have CarPlay support. Following this finding I have two questions:Is there a workaround to activate/open an app with Siri, while it doesn't have CarPlay support?Is there a way to use AVAudioRecorder in order to achieve the goal to let the user record his speech, within CarPlay?Thanks!Luc.
1
0
604
Mar ’20
Hoe to create a ringtones on iPhone
Hello. I would like some advice on how to create ringtones from My Music Library. I would like to use iOS but might be willing to try using the Mac if that will work better. I know absolutely nothing about Audio editing and find it very intimidating. Not all of the ringtones I want to make are at the beginning of songs.I tried the free version of Ringtone Maker, and even got to the song I wanted, but I couldn't tell where I was in the track, as it told me where I was by a minute and second but wasn't playing through the headphones or speaker, so I was lost. Do I have to get this information from some other App beforehand? Any help would be much appreciated, preferably in layman's terms. Thanks.
1
0
1.4k
Mar ’20
Mac Catalyst can't schedule local notifications
Here is a list of things that Mac Catalyst do not appear to be able to do. Does anyone else experience this ?- MultiPeer connectivity on Mac Catalyst will not connect to an ios device. catalyst ask to join , Then accept on ipad I get this message on Ipad and catatlyst stalls out . [MCNearbyServiceBrowser] Browser got invite response with nil connectionData.- Playing Sounds ( AVAudioPlayer ) on Mac Catalyst does not play audio.- Scheduling local notifications on Mac Catalyst does not work.- Selection of a UICollectionView Cell does not select on Mac Catalystlet selectedItems = colVw.indexPathsForSelectedItems // Works fine on ipad but always empty for MacCatalyst
3
0
1.3k
Mar ’20
WidgetKit TimelineProvider calling timeline() continuously
A newly created Widget extension, with the default code created by Xcode will continuously call the timeline() function while the widget is being debugged. Code provided below: import WidgetKit import SwiftUI struct Provider: TimelineProvider { &#9;&#9;public typealias Entry = SimpleEntry &#9;&#9;public func snapshot(with context: Context, completion: @escaping (SimpleEntry) -> ()) { &#9;&#9;&#9;&#9;NSLog("getting snapshot") &#9;&#9;&#9;&#9;let entry = SimpleEntry(date: Date()) &#9;&#9;&#9;&#9;completion(entry) &#9;&#9;} &#9;&#9;public func timeline(with context: Context, completion: @escaping (Timeline&lt;Entry&gt;) -> ()) { &#9;&#9;&#9;&#9;NSLog("getting timeline") &#9;&#9;&#9;&#9;var entries: [SimpleEntry] = [] &#9;&#9;&#9;&#9;let currentDate = Date() &#9;&#9;&#9;&#9;for hourOffset in 0 ..< 5 { &#9;&#9;&#9;&#9;&#9;&#9;let entryDate = Calendar.current.date(byAdding: .hour, value: hourOffset, to: currentDate)! &#9;&#9;&#9;&#9;&#9;&#9;let entry = SimpleEntry(date: entryDate) &#9;&#9;&#9;&#9;&#9;&#9;entries.append(entry) &#9;&#9;&#9;&#9;} &#9;&#9;&#9;&#9;NSLog("\(entries)") &#9;&#9;&#9;&#9;let timeline = Timeline(entries: entries, policy: .atEnd) &#9;&#9;&#9;&#9;completion(timeline) &#9;&#9;} } struct SimpleEntry: TimelineEntry { &#9;&#9;public let date: Date } struct PlaceholderView : View { &#9;&#9;var body: some View { &#9;&#9;&#9;&#9;Text("Placeholder View") &#9;&#9;} } struct SampleWidgetEntryView : View { &#9;&#9;var entry: Provider.Entry &#9;&#9;var body: some View { &#9;&#9;&#9;&#9;VStack { &#9;&#9;&#9;&#9;&#9;&#9;Text(entry.date, style: .time) &#9;&#9;&#9;&#9;} &#9;&#9;} } @main struct SampleWidget: Widget { &#9;&#9;private let kind: String = "SampleWidget" &#9;&#9;public var body: some WidgetConfiguration { &#9;&#9;&#9;&#9;StaticConfiguration(kind: kind, provider: Provider(), placeholder: PlaceholderView()) { entry in &#9;&#9;&#9;&#9;&#9;&#9;SampleWidgetEntryView(entry: entry) &#9;&#9;&#9;&#9;} &#9;&#9;&#9;&#9;.configurationDisplayName("My Widget") &#9;&#9;&#9;&#9;.description("This is an example widget.") &#9;&#9;} }
5
0
2.2k
Jun ’20
Debugging WidgetKit install error "Failed to get descriptors for extensionBundleID"
I'm trying to create an iOS 14 WidgetKit widget. It's compiling, but when I try to run it, on either simulator or device, I get the error below: Any suggestions on how to debug this? Details SendProcessControlEvent:toPid: encountered an error: Error Domain=com.apple.dt.deviceprocesscontrolservice Code=8 "Failed to show Widget 'com.myapp.dev.WidgetKitExtension' error: Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)}." UserInfo={NSLocalizedDescription=Failed to show Widget 'com.myapp.dev.WidgetKitExtension' error: Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)}., NSUnderlyingError=0x7fc0b0d12540 {Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.myapp.dev.WidgetKitExtension)}}} Domain: DTXMessage Code: 1- System Information macOS Version 10.15.5 (Build 19F101) Xcode 12.0 (17177)
34
0
19k
Jun ’20
Any chance to survive after “Apple Developer Program membership will be terminated” message?
Hello. I get the message from Apple: Hello, Thank you for your patience while we thoroughly evaluated the activity associated with your Apple Developer Program membership. We have completed our investigation and have determined that your Apple Developer Program membership, or another membership associated with your developer account, has been used for dishonest or fraudulent activity. This is prohibited by Section 3.2(f) of the Apple Developer Program License Agreement: "You will not, directly or indirectly, commit any act intended to interfere with the Apple Software or Services, the intent of this Agreement, or Apple’s business practices including, but not limited to, taking actions that may hinder the performance or intended use of the App Store, Custom App Distribution, or the Program." For this reason, your Apple Developer Program membership will be terminated. This appeal decision is final, and any subsequent appeals you file will be closed without review. The guiding principle of the App Store is to provide a safe and enjoyable experience for users and a great opportunity for all developers to be successful. We work hard to make the App Store a trustworthy ecosystem and expect our app developers to be honest with users and with us. Manipulative or misleading behavior degrades user trust in the App Store and is grounds for removal from the Apple Developer Program. We have found a pattern of manipulative or misleading behavior that has led to the termination of your Apple Developer Program membership. These behaviors can include, but are not limited to, inaccurate metadata describing your app or service, misleading app content, engaging in inauthentic ratings and reviews manipulation, providing misleading customer support responses, providing misleading responses in Resolution Center, engaging in misleading purchasing or bait and switch schemes, or other dishonest or fraudulent activity within or outside of the app. This notification is not intended to be a complete statement of the facts regarding this matter, and nothing in this letter should be construed as a waiver of any rights or remedies Apple may have, all of which are hereby reserved. Once your Apple Developer Program membership is formally terminated in our systems, we will deny your reapplication to the Apple Developer Program for one year. After one year, you may petition the App Review Board to reinstate your account by completing this form: Re-instate a Terminated Developer Program Membership. In your petition, provide the specific reasons why the App Review Board should consider re-instating your Apple Developer Program membership. Best regards, App Review Board Is this decision is final? Can I argue it somehow and send them letter and urge them not to delete my account? Can I do something or not? I deleted all the apps, which I think can cause the termination. Does it help me or not?
1
1
1.8k
Jun ’20