digits
TypeScriptget digits(): numberSwift declarationvar digits: UInt16The number of digits in the code used by the generator.
struct · iOS 26.0+ · SDK 27.1
struct TOTPA representation of TOTP as defined in the [Credential Exchange Format (CXF) specs] This represents a TOTP code generator.
get digits(): numberSwift declarationvar digits: UInt16The number of digits in the code used by the generator.
set digits(value: number)Swift declarationvar digits: UInt16The number of digits in the code used by the generator.
get issuer(): (string) | nullSwift declarationvar issuer: String?Optional: The issuer of the generator.
set issuer(value: (string) | null)Swift declarationvar issuer: String?Optional: The issuer of the generator.
get period(): numberSwift declarationvar period: UInt16The period, in seconds, used by the generator to refresh codes.
set period(value: number)Swift declarationvar period: UInt16The period, in seconds, used by the generator to refresh codes.
get secret(): ArrayBufferSwift declarationvar secret: DataThe secret associated with this generator. Must be Base32 encoded when encoded to JSON.
set secret(value: ArrayBuffer)Swift declarationvar secret: DataThe secret associated with this generator. Must be Base32 encoded when encoded to JSON.
static init(secret: ArrayBuffer, period: number, digits: number, userName: (string) | null, algorithm: ASImportableCredential_TOTP_Algorithm, issuer?: (string) | null): ASImportableCredential_TOTPSwift declarationinit(secret: Data, period: UInt16, digits: UInt16, userName: String?, algorithm: ASImportableCredential.TOTP.Algorithm, issuer: String? = nil)get userName(): (string) | nullSwift declarationvar userName: String?The user name associated with the generator. When instantiating from JSON, this property will be populated from the "username" field.
set userName(value: (string) | null)Swift declarationvar userName: String?The user name associated with the generator. When instantiating from JSON, this property will be populated from the "username" field.
get algorithm(): ASImportableCredential_TOTP_AlgorithmSwift declarationvar algorithm: ASImportableCredential.TOTP.AlgorithmThe algorithm used by the generator. Must be one of "sha1", "sha256", or "sha512".
set algorithm(value: ASImportableCredential_TOTP_Algorithm)Swift declarationvar algorithm: ASImportableCredential.TOTP.AlgorithmThe algorithm used by the generator. Must be one of "sha1", "sha256", or "sha512".
No declarations were skipped in this snapshot.