Class: Telnyx::Resources::Verifications::ByPhoneNumber::Actions
- Inherits:
-
Object
- Object
- Telnyx::Resources::Verifications::ByPhoneNumber::Actions
- Defined in:
- lib/telnyx/resources/verifications/by_phone_number/actions.rb
Overview
Two factor authentication API
Instance Method Summary collapse
-
#initialize(client:) ⇒ Actions
constructor
private
A new instance of Actions.
-
#verify(phone_number, code:, verify_profile_id:, request_options: {}) ⇒ Telnyx::Models::Verifications::ByPhoneNumber::VerifyVerificationCodeResponse
Verify verification code by phone number.
Constructor Details
#initialize(client:) ⇒ Actions
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Actions.
38 39 40 |
# File 'lib/telnyx/resources/verifications/by_phone_number/actions.rb', line 38 def initialize(client:) @client = client end |
Instance Method Details
#verify(phone_number, code:, verify_profile_id:, request_options: {}) ⇒ Telnyx::Models::Verifications::ByPhoneNumber::VerifyVerificationCodeResponse
Verify verification code by phone number
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/telnyx/resources/verifications/by_phone_number/actions.rb', line 24 def verify(phone_number, params) parsed, = Telnyx::Verifications::ByPhoneNumber::ActionVerifyParams.dump_request(params) @client.request( method: :post, path: ["verifications/by_phone_number/%1$s/actions/verify", phone_number], body: parsed, model: Telnyx::Verifications::ByPhoneNumber::VerifyVerificationCodeResponse, options: ) end |