Class: Privy::Models::DeviceAuthorizationResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/privy/models/device_authorization_response.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(device_code:, expires_in:, interval:, user_code:, verification_uri:, verification_uri_complete:) ⇒ Object

Some parameter documentations has been truncated, see Privy::Models::DeviceAuthorizationResponse for more details.

Response from the device authorization endpoint per RFC 8628. Contains codes and URIs for the device flow.

Parameters:

  • device_code (String)

    A long-lived code used by the device to poll for authorization status.

  • expires_in (Integer)

    The lifetime in seconds of the device_code and user_code.

  • interval (Integer)

    The minimum number of seconds the device should wait between polling requests.

  • user_code (String)

    A short code displayed to the user, who enters it at the verification URI to aut

  • verification_uri (String)

    The URI where the user navigates to enter the user_code.

  • verification_uri_complete (String)

    The verification URI with the user_code pre-filled as a query parameter.



# File 'lib/privy/models/device_authorization_response.rb', line 43

Instance Attribute Details

#device_codeString

A long-lived code used by the device to poll for authorization status.

Returns:

  • (String)


10
# File 'lib/privy/models/device_authorization_response.rb', line 10

required :device_code, String

#expires_inInteger

The lifetime in seconds of the device_code and user_code.

Returns:

  • (Integer)


16
# File 'lib/privy/models/device_authorization_response.rb', line 16

required :expires_in, Integer

#intervalInteger

The minimum number of seconds the device should wait between polling requests.

Returns:

  • (Integer)


22
# File 'lib/privy/models/device_authorization_response.rb', line 22

required :interval, Integer

#user_codeString

A short code displayed to the user, who enters it at the verification URI to authorize the device.

Returns:

  • (String)


29
# File 'lib/privy/models/device_authorization_response.rb', line 29

required :user_code, String

#verification_uriString

The URI where the user navigates to enter the user_code.

Returns:

  • (String)


35
# File 'lib/privy/models/device_authorization_response.rb', line 35

required :verification_uri, String

#verification_uri_completeString

The verification URI with the user_code pre-filled as a query parameter.

Returns:

  • (String)


41
# File 'lib/privy/models/device_authorization_response.rb', line 41

required :verification_uri_complete, String