SeamCredential
public struct SeamCredential : Equatable, Hashable
Represents a Seam access credential for display, selection, and management.
Example:
let credential = SeamCredential( id: "123", name: "Main Door", location: "Lobby", expiry: Date().addingTimeInterval(3600), cardNumber: "0001", code: nil, errors: [] )
Note
Instances are immutable snapshots; refresh by reading Seam.shared.credentials
.
Parameters
id
|
The unique identifier for this credential. |
name
|
The display name for this credential. |
location
|
The credential’s associated location. |
expiry
|
The expiration date of the credential, if available. |
cardNumber
|
The card number for this credential, if any. |
code
|
The access code for this credential, if any. |
errors
|
List of credential-specific errors in priority order. |
-
The unique identifier for this credential.
Declaration
Swift
public let id: String
-
Indicates whether this credential was created and managed by the Seam API (
true
) or was discovered directly through the provider integration (false
).Declaration
Swift
public let isManaged: Bool
-
The display name associated with this credential.
Declaration
Swift
public let name: String
-
The credential’s associated location.
Declaration
Swift
public let location: String
-
The expiration date of the credential, if available.
Declaration
Swift
public let expiry: Date?
-
The card number associated with this credential, if any.
Declaration
Swift
public let cardNumber: String?
-
The code associated with this credential, if any.
Declaration
Swift
public let code: String?
-
The list of errors currently affecting this credential.
The order of errors is significant and can be used to prioritize error display or handling.
Declaration
Swift
public let errors: [SeamCredentialError]
-
Undocumented
Declaration
Swift
public init( id: String, isManaged: Bool, name: String, location: String, expiry: Date?, cardNumber: String?, code: String?, errors: [SeamCredentialError] )