Instance Method


Indicates whether the user’s pass library contains the specified pass.


func containsPass(_ pass: PKPass) -> Bool



The pass being queried.

Return Value

true if the user’s pass library contains the pass; otherwise, false.


This method lets you determine that the pass library contains a pass even though your app wouldn’t be able to read or modify the pass. For example, an email client would not have entitlements to read or write any passes from the library.

Your app can use this method to provide a UI indicating whether a pass is already in the library.

See Also

Accessing Passes

class func isPassLibraryAvailable() -> Bool

A Boolean value that indicates whether the pass library is available.

func passes() -> [PKPass]

Returns the passes in the user’s pass library to which the app has access.

func pass(withPassTypeIdentifier: String, serialNumber: String) -> PKPass?

Returns the pass with the given pass type identifier and serial number.

func passes(of: PKPassType) -> [PKPass]

Returns the passes of the specified pass type.

func remotePaymentPasses() -> [PKPaymentPass]

Returns a list of passes stored on a remote device.