AppClip sharing

It appears that sharing the appropriate URL FROM our app to another user via iMessage SHOULD pass along the app clip. Instead, the user is routed to our website which then shows the App Clip banner. Not ideal.

I have seen other apps that this works with, particularly Confide.

Is there some way to setup / configure the UIActivityViewController so that it sends the AppClip instead of a 'regular' URL
There are multiple requirements for the app clip link presentation to be displayed in Messages:
  • The device sending the link must be running iOS 14 or newer

  • The device receiving the link must also be running iOS 14 or newer

  • The device receiving the link must have the sender as a contact

  • The link must be sent over iMessage (not SMS)

  • The webpage being shared must contain the requisite metadata for the Smart App Banner for app clips

  • Associated Domains must be configured in order for the Smart App Banner for app clips to be displayed in Safari

If all of these requirements are being satisfied then please file a bug report with details about the URL being shared, a screen recording, and a sysdiagnose.

Please see Profiles and Logs for details on how to capture a sysdiagnose.
Thanks, that is a very helpful list. We do meet all of those requirements. We will file a bug report.
Hi @againwithanaccount,

In my experience, this requirement:
  • The webpage being shared must contain the requisite metadata for the Smart App Banner for app clips

is not required for QR codes via the Camera app or Control Center QR Scanner, but is required for the Messages app. If your URL works as a QR code but not when sent in Messages, this is likely the problem. In my case, the URL was being redirected to another page the didn't have the required metadata.

Note that the Messages web user agent does not contain "iPhone" when it visits the URL to determine if there is an app clip to be shown, which is good in my case since my URL will redirect the user to the app in the app store when the user agent contains "iPhone" -- for iOS 13 and below.

I too am running into this issue. Any updates?
@Againwithanaccount I was able to work around this by adding an additional text item to the UIActivityViewController. Definitely not ideal, but works in the meantime. Seems to be what Confide is doing to get around this as well.

For example this doesn't work:
Code Block
let urlString = "https://app-clip-url"
let items: [Any] = [URL(string: urlString)!]
let activityViewController = UIActivityViewController(activityItems: items, applicationActivities: [])

but this does:
Code Block
let urlString = "https://app-clip-url"
let items: [Any] = [URL(string: urlString)!, "Click the \"Open\" button above to open this App Clip."]
let activityViewController = UIActivityViewController(activityItems: items, applicationActivities: [])

https://developer.apple.com/forums/thread/666929
@Againwithanaccount, @camji55 ,

Can you pls share more details and even a live example if you have one:
  1. The target site with app-clip smart banner

  2. The actual link that you are sharing (if different than above)


Your associated domains - although I understand that Safari works, so I guess it is fine

Thanks
@liazkam

App Clip site and shared url:
Code Block
https://app.wificonnect.xyz/connect?to=TcUk3hSMtKmagb1A:JYo2VEUqI4YniAnzcejM3w5WdlNWlAZo6hLIZYeNIL6dlv06YZnLsnY7hhZktmq06P5LfJC/a1MXC/AQwlqE+/0UDs+VqxGtGcbYc4wTxFE=

doing a curl on the url does return the meta tag for the smart banner so I don't think it's a redirect issue.
@camji55 

I'm sorry, but from my Safari (device v14.2) I don't see an App Clip banner going to that site.
Is it published? Else, it won't show up
@liazkam

Odd, now I'm not seeing the banner either, but if I tap the Safari share button it's recognized as an app clip. The Clip is published.
Code Block
https://imgur.com/dsLqB40


The website is a Next.js project hosted on Vercel. Don't think that should matter as it's server-side rendered, but could be related???
AppClip sharing
 
 
Q