Class: Inttegro::OTP::InitiateRequest
- Inherits:
-
T::Struct
- Object
- T::Struct
- Inttegro::OTP::InitiateRequest
- Defined in:
- lib/inttegro/otp/initiate_request.rb
Overview
Typed representation of the initiate request object in the Inttegro API.
This generated model is immutable. Construct it with .new, or decode a string-keyed API
payload with .from_hash. #serialize produces a string-keyed hash using the original wire
field names and serialized enum values.
Instance Attribute Summary collapse
-
#async_delivery ⇒ Boolean?
readonly
Return after accepting the transaction while delivery continues asynchronously.
-
#message_template ⇒ String?
readonly
SMS body or email copy containing the required
{token}placeholder and optional{service}placeholder. -
#preferred_gateway ⇒ String?
readonly
Optional SMS gateway; not valid for email OTP delivery.
-
#purpose ⇒ Inttegro::OTP::Purpose
readonly
Customer action protected by the OTP.
-
#recipient ⇒ String
readonly
Phone number in international format (E.164) or bare email address.
-
#sender ⇒ String?
readonly
Optional SMS sender identifier (3-12 characters).
-
#service_name ⇒ String
readonly
Service name substituted for
{service}(2-20 characters). -
#token_alphabet ⇒ String?
readonly
Custom alphabet for token generation (mutually exclusive with token_alphabet_type).
-
#token_alphabet_type ⇒ Inttegro::OTP::AlphabetType?
readonly
Predefined alphabet type (mutually exclusive with token_alphabet).
-
#token_size ⇒ Integer
readonly
Length of generated token (5-10 characters).
-
#transport ⇒ Inttegro::Chime::Transport?
readonly
Optional delivery transport.
-
#validity_duration_in_minutes ⇒ Integer?
readonly
How long the token remains valid (3-10080 minutes).
Instance Attribute Details
#async_delivery ⇒ Boolean? (readonly)
Return after accepting the transaction while delivery continues asynchronously.
Optional in the API payload; omitted values default to nil. Wire name: async_delivery.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#message_template ⇒ String? (readonly)
SMS body or email copy containing the required {token} placeholder and optional
{service} placeholder. Email templates must contain {token} exactly once. A custom
template replaces the purpose-specific default body, while purpose still controls the
email subject and heading. Email sends this as the plain-text fallback and renders the copy
around a prominent code in the HTML version. Defaults are transport-specific.
Optional in the API payload; omitted values default to nil. Wire name: message_template.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#preferred_gateway ⇒ String? (readonly)
Optional SMS gateway; not valid for email OTP delivery. Email uses the configured default provider.
Optional in the API payload; omitted values default to nil. Wire name: preferred_gateway.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#purpose ⇒ Inttegro::OTP::Purpose (readonly)
Customer action protected by the OTP. Controls safe, purpose-specific default email copy.
Unknown values are rejected; use unspecified explicitly for a general verification
request.
Required in the API payload. Wire name: purpose.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#recipient ⇒ String (readonly)
Phone number in international format (E.164) or bare email address. Transport is inferred from the address unless specified.
Required in the API payload. Wire name: recipient.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#sender ⇒ String? (readonly)
Optional SMS sender identifier (3-12 characters). Email OTP always uses {service_name} <noreply@inttegro.com>; omit this field for email or supply exactly the bare
noreply@inttegro.com address.
Optional in the API payload; omitted values default to nil. Wire name: sender.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#service_name ⇒ String (readonly)
Service name substituted for {service} (2-20 characters).
Required in the API payload. Wire name: service_name.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#token_alphabet ⇒ String? (readonly)
Custom alphabet for token generation (mutually exclusive with token_alphabet_type)
Optional in the API payload; omitted values default to nil. Wire name: token_alphabet.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#token_alphabet_type ⇒ Inttegro::OTP::AlphabetType? (readonly)
Predefined alphabet type (mutually exclusive with token_alphabet)
Optional in the API payload; omitted values default to nil. Wire name: token_alphabet_type.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#token_size ⇒ Integer (readonly)
Length of generated token (5-10 characters)
Required in the API payload. Wire name: token_size.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#transport ⇒ Inttegro::Chime::Transport? (readonly)
Optional delivery transport. When omitted, an email address selects email and a phone number selects SMS.
Optional in the API payload; omitted values default to nil. Wire name: transport.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |
#validity_duration_in_minutes ⇒ Integer? (readonly)
How long the token remains valid (3-10080 minutes)
Optional in the API payload; omitted values default to nil. Wire name: validity_duration_in_minutes.
103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
# File 'lib/inttegro/otp/initiate_request.rb', line 103 class InitiateRequest < T::Struct const :async_delivery, T.nilable(T::Boolean), default: nil const :message_template, T.nilable(String), default: nil const :preferred_gateway, T.nilable(String), default: nil const :purpose, Inttegro::OTP::Purpose const :recipient, String const :sender, T.nilable(String), default: nil const :service_name, String const :token_alphabet, T.nilable(String), default: nil const :token_alphabet_type, T.nilable(Inttegro::OTP::AlphabetType), default: nil const :token_size, Integer const :transport, T.nilable(Inttegro::Chime::Transport), default: nil const :validity_duration_in_minutes, T.nilable(Integer), default: nil end |