Reputation: 1801
I have to test the smart app banners in an application, which is still in development, especially passing some 'app-argument' to this app. The application exists on iTunes Connect, and his status is of course still "Prepare for Upload".
The banner is on my website's home page. But when I try to reach this page with my iPhone (Safari), the banner shows up, totally empty, and disappears after about 1 second...
Here is the banner code on my website:
<meta content="app-id=myAppId, app-argument=myScheme://123456" name="apple-itunes-app">
Is it possible to test this smart app banners before publishing the applications on the store?
Upvotes: 13
Views: 4638
Reputation: 4437
As of now, Xcode 8 and iOS 10, I have tried all the methods but Cannot Debug the smart banners URL that is being opened, as it needs the store versions of the application.
I have found a workaround of this, and have tested my application using this.
Apart from the <meta ...>
tag I have also added a link button on the page that uses the scheme to open the app.
<!doctype html>
<html>
<head>
<meta name="apple-itunes-app" content="app-id=xxxx,pt=xxxxx,ct=xxxxx,app-argument=myappscheme://www.mymobilesite.com/link/detailpage?query=x">
<title>Banner Debug Sample</title>
</head>
<body>
<p>Visit <a href="myappscheme://www.mymobilesite.com/link/detailpage?query=x">App Using Scheme</a>.</p>
</body>
</html>
With this link I can debug the Dev builds and works well.
Though this only works when the app has registered a scheme for itself, but just for testing we can register a dummy scheme say appscheme://
and replace http://
scheme with dummy scheme, test it, and then revert links from app scheme://
to http://
Upvotes: 2
Reputation: 2562
The answer is sadly, no. You must first publish your app before the smart app banner will work.
But you CAN test Universal Links without a published app. You just have to have Apple crawl your website after you set it up.
Upvotes: 4