0

My app has three separate environments named

  1. int
  2. sbx
  3. prod

Here are my three AASA files on my webservers.

  1. https://app.int.croissant.com/.well-known/apple-app-site-association
  2. https://app.sbx.croissant.com/.well-known/apple-app-site-association
  3. https://app.croissant.com/.well-known/apple-app-site-association

Here are the same three AASA files on Apple's CDN

  1. https://app-site-association.cdn-apple.com/a/v1/app.int.croissant.com
  2. https://app-site-association.cdn-apple.com/a/v1/app.sbx.croissant.com
  3. https://app-site-association.cdn-apple.com/a/v1/app.croissant.com

I have two questions.

  1. How can I invalidate the Apple CDN so that my new AASA files are pulled in?
  2. Do my new AASA files look like they will support all possible paths? Does * capture any path e.g., /collection/123, /wallet/oauth?code=123, /sign-in

I've done the generic Googling and docs reading around this. I can't seem to find anything specifically related to Apple's CDN.

Alex
  • 952
  • 7
  • 12
  • You can't force the update. You have to wait for apple to refresh (this can be a few days from memory). You can configure developer mode in your info.plist to bypass the CDN for non-production domains – Paulw11 Jul 06 '23 at 20:07
  • Thanks @Paulw11 ... two questions. 1. I made the the updates to my ASAA 3 weeks ago. Any other ideas? 2. I'm using Expo and React-Native. Do you know if the bypass is possible there? – Alex Jul 07 '23 at 15:42
  • The developer mode is set in the [associated domains entitlement](https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_developer_associated-domains) so it shouldn't matter which development environment you are using. – Paulw11 Jul 10 '23 at 07:18
  • I pulled the various files you linked to and they were all the same, except I got a 404 on the https://app-site-association.cdn-apple.com/a/v1/app.int.croissant.com url. – Paulw11 Jul 10 '23 at 07:22
  • It seems like this issue is resolved with all the files being identical? How did this happen? – Markus Rohlof Aug 07 '23 at 06:40
  • I updated my Cache-Control header for this file to no-cache and several days later they all matched up. – Alex Aug 07 '23 at 20:41

1 Answers1

0

Updating my AASA file's Cache-Control header to no-cache fixed this for me.

I use Next.js, so here is my next.config.js that fixed this for me.

 {
    source: "/.well-known/apple-app-site-association",
    headers: [
      { key: "Content-Type", value: "application/json" },
      { key: "Cache-Control", value: "no-cache" },
    ],
  },
Alex
  • 952
  • 7
  • 12