RequestOTPResponse
public struct RequestOTPResponse : Codable, Equatable
The response received after requesting a one-time password (OTP).
-
The type of the contact item associated with the OTP.
Declaration
Swift
public let type: String
-
The value of the contact item associated with the OTP.
Declaration
Swift
public let value: String
-
The ID of the contact item associated with the OTP.
Declaration
Swift
public let contactItemId: String
-
The creation date of the OTP.
Declaration
Swift
public let createdAt: Date
-
A flag indicating whether the OTP has been verified.
Declaration
Swift
public let verified: Bool
-
The date when the next challenge can be requested.
Declaration
Swift
public let nextChallengeNotBefore: Date
-
HAL links to related resources.
Declaration
Swift
public let links: Links
-
Creates an instance of
RequestOTPResponse
with the specified properties.Declaration
Swift
public init( type: String, value: String, contactItemId: String, createdAt: Date, verified: Bool, nextChallengeNotBefore: Date, links: Links )
Parameters
type
The type of the contact item associated with the OTP.
value
The value of the contact item associated with the OTP.
contactItemId
The ID of the contact item associated with the OTP.
createdAt
The creation date of the OTP.
verified
A flag indicating whether the OTP has been verified.
nextChallengeNotBefore
The date when the next challenge can be requested.
links
HAL links to related resources.
-
HAL links to related resources in the context of a
See moreRequestOTPResponse
.Declaration
Swift
struct Links : Codable, Equatable
-
Converts the
RequestOTPResponse
to aContactItemVerification
struct for easier access to the verification links.Declaration
Swift
var toContactItemVerification: ContactItemVerification { get }
-
A stub instance of
RequestOTPResponse
for testing purposes.Declaration
Swift
static let stub: RequestOTPResponse