universal Link's apple-app-site-association file in iOS14

975 views Asked by At

Using iOS14.5,

My URL looks like this: https://www.myexample.com/invitation?invitationCode=123456

Inside my apple-app-site-association file, which components is correct ?

(Please notice the tiny difference of /invitation vs. /invitation* vs. /invitation/ vs. /invitation/* inside the component)

A) ?

"components": [
    {   "/": "/invitation",
        "?": { "invitationCode": "??????" }
    }
]

or B) ?

"components": [
    {   "/": "/invitation*",
        "?": { "invitationCode": "??????" }
    }
]

or C) ?

"components": [
    {   "/": "/invitation/",
        "?": { "invitationCode": "??????" }
    }
]

or D) ?

"components": [
    {   "/": "/invitation/*",
        "?": { "invitationCode": "??????" }
    }
]

Or is it even something else ?

1

There are 1 answers

7
Alihan On BEST ANSWER

Option D looks okay it means that, "Matches any URL whose path starts with /invitation/ and which has a query item with name 'invitationCode' and a value of exactly 6 characters". If you invitation code always be 6 characters it works otherwise you can remove query parameter value.

For more information you can check the Apple Documentation which is my reference.