DeviceFlowStatus

public enum DeviceFlowStatus : Sendable

Represents the status of an RFC 8628 device authorization flow.

  • The device authorization request succeeded. The associated value carries the server response including the userCode and verificationUri to display to the end user.

    Declaration

    Swift

    case started(DeviceAuthorizationResponse)
  • The polling loop is active. Carries the current poll count, current interval (seconds), and the Date at which the next poll will be attempted.

    Declaration

    Swift

    case polling(pollCount: Int, pollInterval: Int, nextPollAt: Date)
  • Authorization succeeded. The associated value is the authenticated User.

    Declaration

    Swift

    case success(any User)
  • The device code has expired before the user authorized the request.

    Declaration

    Swift

    case expired
  • The user denied the authorization request.

    Declaration

    Swift

    case accessDenied
  • A terminal error occurred that does not map to a specific RFC 8628 error code.

    Declaration

    Swift

    case failure(any Error)