How to test web markup (iOS 9 search APIs)

After watching "Introduction to Search APIs" from this year's WWDC, I have a few questions around the web markup that I'm supposed to add to my website to get Applebot to index my deep links. Here we go:


- If a user taps on a Spotlight search result for a deep link that was picked up by Applebot, which application delegate method gets called? The new application:continueUserActivity:restorationHandler: or the old application:openURL:sourceApplication:annotation? Does this depend on whether I've uploaded the signed JSON file to turn on universal http links?


Some other questions I have:


- Is there any way to know if my website has already been crawled by Applebot or if I'm currently in Apple's index?

- After I add the web markup to my website, is there a way to see what it's going to look like as a Spotlight/Safari search result? I can't seem to find any of these search results in the current beta (iOS 9 beta 2).

- The talk mentioned a web markup tool that's going to be availabel this year. When is this tool coming and what will it do?


So many questions, so little time.

You should also check the iOS 9 section of What's New in iOS as that has some additional information. In particular it says:

When users tap a search result for an item that you added to the index, your app should open and restore the context associated with that item. To accomplish this, your app delegate implements

application:continueUserActivity:restorationHandler:
, checking the type of the incoming activity to see if the app is opening because the user tapped an indexed item in a search result. Listing 5 shows a skeletal implementation of
application:continueUserActivity:restorationHandler:
.


As for the Applebot and web markup tool, that's not quite ready. We'll post something here in the forums when there's more information available.

"When users tap a search result for an item that you added to the index". does that include deep links from web markup?


If so, there's the possibility that the web markup deep link gets indexed from an existing Smart Banner. However, the app may not have implemented application:continueUserActivity:restorationHandler:. What does the OS do then?

Yes, it does. In the case that you describe, then the app will simply be launched.

Just for clarity, could you please confirm that application:openURL:sourceApplication:annotation will not be called for app launches resulting from a tap on web indexing-sourced search entries (based on Smart App Banner app-argument values)?

Hi pmd!


Could you please connect the replies here with my questions at https://forums.developer.apple.com/message/23053#23053 ?


Regards

Confirmed. If the user is tapping on an item that was indexed by way of a smart app banner, then that will come into your app through the Handoff delegate methods, not through application:openURL:sourceApplication:annotation:.

How to test web markup (iOS 9 search APIs)
 
 
Q