One Logo Pool Ball
_AuthenticationServices_SwiftUI · IOS API REFERENCE

DeliveredVerificationCodesManager

struct · iOS 27.0+ · SDK 27.1

@MainActor struct DeliveredVerificationCodesManager

Members (2)

method · iOS 27.0+

oneTimeCodes

TypeScript
oneTimeCodes(preferredDuration: number): Promise<SDKHandle>
Swift declaration
@MainActor func oneTimeCodes(preferredDuration: TimeInterval) async throws -> some AsyncSequence<ASVerificationCode, any Error>

Stream one-time codes received by the system. When requested, the user may decide whether your app may receive one-time codes. This stream will automatically disconnect after a period of time. - Parameters: - preferredDuration: How long the stream should ideally remain connected. This duration is not guaranteed. - Throws: `DeliveredVerificationCodesManager.VerificationError` if one-time codes can not be delivered. - Note: Only enabled credential providers may call this method.

method · iOS 27.0+

consumeOneTimeCode

TypeScript
consumeOneTimeCode(oneTimeCode: _AuthenticationServices_ASVerificationCode): Promise<void>
Swift declaration
@MainActor func consumeOneTimeCode(_ oneTimeCode: ASVerificationCode) async throws

Mark a one-time code as "consumed" by the current process. A code should only be marked as consumed if it was submitted to a service for the purposes of authentication. Consuming a code will mark a code's containing message as read in the Messages and Mail apps. Depending on the user's preference, this may also delete the code's containing message. - Parameters: - oneTimeCode: The code to mark as consumed. - Throws: `DeliveredVerificationCodesManager.VerificationError` if the system failed to accept the update. - Note: Only consume codes that you submit to a service. You should make a best effort to ensure it is accepted before calling this.

Skipped declarations

No declarations were skipped in this snapshot.

All _AuthenticationServices_SwiftUI types →