One Logo Pool Ball
StoreKit · IOS API REFERENCE

ExternalPurchaseLink

enum · iOS 15.4+ · SDK 27.1

enum ExternalPurchaseLink

Members (4)

get · iOS 17.5+

eligibleURLs

TypeScript
static get eligibleURLs(): Promise<(Array<string>) | null>
Swift declaration
static var eligibleURLs: [URL]? { get async }
static · iOS 17.5+

open

TypeScript
static openUrl(url: string): Promise<void>
Swift declaration
static func open(url: URL) async throws
static · iOS 15.4+

open

TypeScript
static open(): Promise<void>
Swift declaration
static func open() async throws

Opens the external link in the user's default browser. Only call this method as a result of deliberate user interaction, such as tapping a button. If `canOpen` is `false`, this method will always fail. This method does not guarantee the user was redirected to the external link if an error is not thrown. - Throws: A `StoreKitError`

get · iOS 15.4+

canOpen

TypeScript
static get canOpen(): Promise<boolean>
Swift declaration
static var canOpen: Bool { get async }

Whether the app can open the external link. Check this property before showing any UI controls that the user can use to open the external link Check the value of this property again and update your UI if `Storefront.current` changes. - Important: If this property is `false`, do not show UI controls that call `open()` as the method will always fail.

Skipped declarations

No declarations were skipped in this snapshot.

All StoreKit types →