Class: PreludeSDK::Resources::VerificationManagement
- Inherits:
-
Object
- Object
- PreludeSDK::Resources::VerificationManagement
- Defined in:
- lib/prelude_sdk/resources/verification_management.rb,
lib/prelude_sdk/resources/verification_management/sandbox.rb,
sig/prelude_sdk/resources/verification_management.rbs,
sig/prelude_sdk/resources/verification_management/sandbox.rbs
Overview
Verify phone numbers.
Defined Under Namespace
Classes: Sandbox
Instance Attribute Summary collapse
-
#sandbox ⇒ PreludeSDK::Resources::VerificationManagement::Sandbox
readonly
Verify phone numbers.
Instance Method Summary collapse
-
#delete_phone_number(action, phone_number:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementDeletePhoneNumberResponse
Remove a phone number from the allow or block list.
-
#initialize(client:) ⇒ VerificationManagement
constructor
private
A new instance of VerificationManagement.
-
#list_phone_numbers(action, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementListPhoneNumbersResponse
Retrieve the list of phone numbers in the allow or block list.
-
#list_sender_ids(request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementListSenderIDsResponse
Retrieve sender IDs list.
-
#set_phone_number(action, phone_number:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementSetPhoneNumberResponse
Add a phone number to the allow or block list.
-
#submit_sender_id(sender_id:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementSubmitSenderIDResponse
This endpoint allows you to submit a new sender ID for verification purposes.
Constructor Details
#initialize(client:) ⇒ VerificationManagement
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 VerificationManagement.
140 141 142 143 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 140 def initialize(client:) @client = client @sandbox = PreludeSDK::Resources::VerificationManagement::Sandbox.new(client: client) end |
Instance Attribute Details
#sandbox ⇒ PreludeSDK::Resources::VerificationManagement::Sandbox (readonly)
Verify phone numbers.
9 10 11 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 9 def sandbox @sandbox end |
Instance Method Details
#delete_phone_number(action, phone_number:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementDeletePhoneNumberResponse
Remove a phone number from the allow or block list.
This operation is idempotent - re-deleting the same phone number will not result in errors. If the phone number does not exist in the specified list, the operation will succeed without making any changes.
In order to get access to this endpoint, contact our support team.
30 31 32 33 34 35 36 37 38 39 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 30 def delete_phone_number(action, params) parsed, = PreludeSDK::VerificationManagementDeletePhoneNumberParams.dump_request(params) @client.request( method: :delete, path: ["v2/verification/management/phone-numbers/%1$s", action], body: parsed, model: PreludeSDK::Models::VerificationManagementDeletePhoneNumberResponse, options: ) end |
#list_phone_numbers(action, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementListPhoneNumbersResponse
Retrieve the list of phone numbers in the allow or block list.
In order to get access to this endpoint, contact our support team.
54 55 56 57 58 59 60 61 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 54 def list_phone_numbers(action, params = {}) @client.request( method: :get, path: ["v2/verification/management/phone-numbers/%1$s", action], model: PreludeSDK::Models::VerificationManagementListPhoneNumbersResponse, options: params[:request_options] ) end |
#list_sender_ids(request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementListSenderIDsResponse
Retrieve sender IDs list.
In order to get access to this endpoint, contact our support team.
74 75 76 77 78 79 80 81 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 74 def list_sender_ids(params = {}) @client.request( method: :get, path: "v2/verification/management/sender-id", model: PreludeSDK::Models::VerificationManagementListSenderIDsResponse, options: params[:request_options] ) end |
#set_phone_number(action, phone_number:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementSetPhoneNumberResponse
Add a phone number to the allow or block list.
This operation is idempotent - re-adding the same phone number will not result in duplicate entries or errors. If the phone number already exists in the specified list, the operation will succeed without making any changes.
In order to get access to this endpoint, contact our support team.
102 103 104 105 106 107 108 109 110 111 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 102 def set_phone_number(action, params) parsed, = PreludeSDK::VerificationManagementSetPhoneNumberParams.dump_request(params) @client.request( method: :post, path: ["v2/verification/management/phone-numbers/%1$s", action], body: parsed, model: PreludeSDK::Models::VerificationManagementSetPhoneNumberResponse, options: ) end |
#submit_sender_id(sender_id:, request_options: {}) ⇒ PreludeSDK::Models::VerificationManagementSubmitSenderIDResponse
This endpoint allows you to submit a new sender ID for verification purposes.
In order to get access to this endpoint, contact our support team.
126 127 128 129 130 131 132 133 134 135 |
# File 'lib/prelude_sdk/resources/verification_management.rb', line 126 def submit_sender_id(params) parsed, = PreludeSDK::VerificationManagementSubmitSenderIDParams.dump_request(params) @client.request( method: :post, path: "v2/verification/management/sender-id", body: parsed, model: PreludeSDK::Models::VerificationManagementSubmitSenderIDResponse, options: ) end |