diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index be4cf51e..3acca0e7 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -11,6 +11,8 @@ docs/AnswerCallback.md docs/BlockedWebhook.md docs/BridgeCompleteCallback.md docs/BridgeTargetCompleteCallback.md +docs/BusinessEntityTypeEnum.md +docs/BusinessRegistrationTypeEnum.md docs/CallDirectionEnum.md docs/CallRecordingMetadata.md docs/CallState.md @@ -190,6 +192,8 @@ lib/bandwidth-sdk/models/answer_callback.rb lib/bandwidth-sdk/models/blocked_webhook.rb lib/bandwidth-sdk/models/bridge_complete_callback.rb lib/bandwidth-sdk/models/bridge_target_complete_callback.rb +lib/bandwidth-sdk/models/business_entity_type_enum.rb +lib/bandwidth-sdk/models/business_registration_type_enum.rb lib/bandwidth-sdk/models/call_direction_enum.rb lib/bandwidth-sdk/models/call_recording_metadata.rb lib/bandwidth-sdk/models/call_state.rb diff --git a/README.md b/README.md index afed6c62..2f137c2a 100644 --- a/README.md +++ b/README.md @@ -167,6 +167,8 @@ Class | Method | HTTP request | Description - [Bandwidth::BlockedWebhook](docs/BlockedWebhook.md) - [Bandwidth::BridgeCompleteCallback](docs/BridgeCompleteCallback.md) - [Bandwidth::BridgeTargetCompleteCallback](docs/BridgeTargetCompleteCallback.md) + - [Bandwidth::BusinessEntityTypeEnum](docs/BusinessEntityTypeEnum.md) + - [Bandwidth::BusinessRegistrationTypeEnum](docs/BusinessRegistrationTypeEnum.md) - [Bandwidth::CallDirectionEnum](docs/CallDirectionEnum.md) - [Bandwidth::CallRecordingMetadata](docs/CallRecordingMetadata.md) - [Bandwidth::CallState](docs/CallState.md) diff --git a/bandwidth.yml b/bandwidth.yml index 65afd419..004fb91b 100644 --- a/bandwidth.yml +++ b/bandwidth.yml @@ -183,6 +183,8 @@ paths: - $ref: '#/components/parameters/bwQueued' - $ref: '#/components/parameters/product' - $ref: '#/components/parameters/location' + - $ref: '#/components/parameters/carrierQueued' + - $ref: '#/components/parameters/fromCarrierLatency' - $ref: '#/components/parameters/callingNumberCountryA3' - $ref: '#/components/parameters/calledNumberCountryA3' - $ref: '#/components/parameters/fromSegmentCount' @@ -1851,6 +1853,14 @@ components: accounts with the Advanced Quality Metrics feature enabled. nullable: true example: 20 + carrierLatency: + type: integer + description: >- + The carrier latency of the message in seconds. Only available for + OUTBOUND messages from accounts with the Advanced Quality Metrics + feature enabled. + nullable: true + example: 20 callingNumberCountryA3: type: string description: The A3 country code of the calling number. @@ -5530,6 +5540,50 @@ components: description: The company 'Doing Business As'. example: Another Company Name Inc. type: string + businessRegistrationNumber: + type: string + description: >- + US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional + until early 2026. If a value is provided for this field, a value must be + provided for `businessRegistrationType` and `businessEntityType`. + Available starting October 1st, 2025. + nullable: true + maxLength: 500 + example: 12-3456789 + businessRegistrationTypeEnum: + type: string + description: >- + The type of business registration number. Optional until early 2026; + required if `businessRegistrationNumber` is provided. Available starting + October 1st, 2025. + enum: + - EIN + - CBN + nullable: true + businessEntityTypeEnum: + type: string + description: >- + The type of registered business. If no option is applicable, please + provide "SOLE_PROPRIETOR" as a value. Optional until early 2026; + required if `businessRegistrationNumber` is provided. Available starting + October 1st, 2025. + enum: + - SOLE_PROPRIETOR + - PRIVATE_PROFIT + - PUBLIC_PROFIT + - NON_PROFIT + - GOVERNMENT + nullable: true + helpMessageResponse: + type: string + description: A message that gets sent to users requesting help. + nullable: true + maxLength: 500 + example: Please contact support for assistance. + ageGatedContent: + type: boolean + description: Indicates whether the content is age-gated. + example: false additionalDenialReason: properties: statusCode: @@ -5616,6 +5670,16 @@ components: $ref: '#/components/schemas/termsAndConditionsUrl' businessDba: $ref: '#/components/schemas/businessDba' + businessRegistrationNumber: + $ref: '#/components/schemas/businessRegistrationNumber' + businessRegistrationType: + $ref: '#/components/schemas/businessRegistrationTypeEnum' + businessEntityType: + $ref: '#/components/schemas/businessEntityTypeEnum' + helpMessageResponse: + $ref: '#/components/schemas/helpMessageResponse' + ageGatedContent: + $ref: '#/components/schemas/ageGatedContent' verificationUpdateRequest: type: object required: @@ -5655,6 +5719,16 @@ components: $ref: '#/components/schemas/termsAndConditionsUrl' businessDba: $ref: '#/components/schemas/businessDba' + businessRegistrationNumber: + $ref: '#/components/schemas/businessRegistrationNumber' + businessRegistrationType: + $ref: '#/components/schemas/businessRegistrationTypeEnum' + businessEntityType: + $ref: '#/components/schemas/businessEntityTypeEnum' + helpMessageResponse: + $ref: '#/components/schemas/helpMessageResponse' + ageGatedContent: + $ref: '#/components/schemas/ageGatedContent' tfvBasicAuthentication: type: object properties: @@ -5858,6 +5932,12 @@ components: example: https://www.example.com/path/to/resource pattern: >- ^$|(https?:\/\/)?(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,253}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#()?&//=]*) + confirmationResponse: + type: string + minLength: 0 + maxLength: 500 + nullable: true + example: Thank you for opting in! isvReseller: type: string description: ISV name. @@ -6131,6 +6211,22 @@ components: $ref: '#/components/schemas/termsAndConditionsUrl' businessDba: $ref: '#/components/schemas/businessDba' + businessRegistrationNumber: + $ref: '#/components/schemas/businessRegistrationNumber' + description: >- + US Federal Tax ID Number (EIN) or Canada Business Number (CBN). + Available starting October 1st, 2025. + businessRegistrationType: + $ref: '#/components/schemas/businessRegistrationTypeEnum' + description: >- + The type of business registration number. Available starting October + 1st, 2025. + businessEntityType: + $ref: '#/components/schemas/businessEntityTypeEnum' + description: >- + The type of registered business. If no option is applicable, please + provide "SOLE_PROPRIETOR" as a value. Available starting October + 1st, 2025. tfvStatusEnum: type: string enum: @@ -7028,6 +7124,28 @@ components: example: 123ABC schema: type: string + carrierQueued: + in: query + name: carrierQueued + required: false + description: >- + A boolean value indicating whether the message is queued in the carrier + network. Only available for OUTBOUND messages from accounts with the + Advanced Quality Metrics feature enabled. + example: true + schema: + type: boolean + fromCarrierLatency: + in: query + name: fromCarrierLatency + required: false + description: >- + The minimum carrier latency of the message in seconds. Only available + for OUTBOUND messages from accounts with the Advanced Quality Metrics + feature enabled. + example: 50 + schema: + type: integer callingNumberCountryA3: in: query name: callingNumberCountryA3 diff --git a/docs/BusinessEntityTypeEnum.md b/docs/BusinessEntityTypeEnum.md new file mode 100644 index 00000000..0ccc4c60 --- /dev/null +++ b/docs/BusinessEntityTypeEnum.md @@ -0,0 +1,15 @@ +# Bandwidth::BusinessEntityTypeEnum + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + +## Example + +```ruby +require 'bandwidth-sdk' + +instance = Bandwidth::BusinessEntityTypeEnum.new() +``` + diff --git a/docs/BusinessRegistrationTypeEnum.md b/docs/BusinessRegistrationTypeEnum.md new file mode 100644 index 00000000..313cd785 --- /dev/null +++ b/docs/BusinessRegistrationTypeEnum.md @@ -0,0 +1,15 @@ +# Bandwidth::BusinessRegistrationTypeEnum + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | + +## Example + +```ruby +require 'bandwidth-sdk' + +instance = Bandwidth::BusinessRegistrationTypeEnum.new() +``` + diff --git a/docs/ListMessageItem.md b/docs/ListMessageItem.md index 63dbfeff..4e0918c8 100644 --- a/docs/ListMessageItem.md +++ b/docs/ListMessageItem.md @@ -22,6 +22,7 @@ | **campaign_class** | **String** | The campaign class of the message if it has one. | [optional] | | **campaign_id** | **String** | The campaign ID of the message if it has one. | [optional] | | **bw_latency** | **Integer** | The Bandwidth latency of the message in seconds. Only available for accounts with the Advanced Quality Metrics feature enabled. | [optional] | +| **carrier_latency** | **Integer** | The carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. | [optional] | | **calling_number_country_a3** | **String** | The A3 country code of the calling number. | [optional] | | **called_number_country_a3** | **String** | The A3 country code of the called number. | [optional] | | **product** | **String** | The messaging product associated with the message. | [optional] | @@ -51,6 +52,7 @@ instance = Bandwidth::ListMessageItem.new( campaign_class: T, campaign_id: CJEUMDK, bw_latency: 20, + carrier_latency: 20, calling_number_country_a3: USA, called_number_country_a3: USA, product: P2P, diff --git a/docs/MessagesApi.md b/docs/MessagesApi.md index dad134da..c0616667 100644 --- a/docs/MessagesApi.md +++ b/docs/MessagesApi.md @@ -118,6 +118,8 @@ opts = { bw_queued: true, # Boolean | A boolean value indicating whether the message is queued in the Bandwidth network. product: Bandwidth::ProductTypeEnum::LOCAL_A2_P, # ProductTypeEnum | Messaging product associated with the message. location: '123ABC', # String | Location Id associated with the message. + carrier_queued: true, # Boolean | A boolean value indicating whether the message is queued in the carrier network. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. + from_carrier_latency: 50, # Integer | The minimum carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. calling_number_country_a3: 'USA', # String | Calling number country in A3 format. called_number_country_a3: 'USA', # String | Called number country in A3 format. from_segment_count: 1, # Integer | Segment count (start range). @@ -177,6 +179,8 @@ end | **bw_queued** | **Boolean** | A boolean value indicating whether the message is queued in the Bandwidth network. | [optional] | | **product** | [**ProductTypeEnum**](.md) | Messaging product associated with the message. | [optional] | | **location** | **String** | Location Id associated with the message. | [optional] | +| **carrier_queued** | **Boolean** | A boolean value indicating whether the message is queued in the carrier network. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. | [optional] | +| **from_carrier_latency** | **Integer** | The minimum carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. | [optional] | | **calling_number_country_a3** | **String** | Calling number country in A3 format. | [optional] | | **called_number_country_a3** | **String** | Called number country in A3 format. | [optional] | | **from_segment_count** | **Integer** | Segment count (start range). | [optional] | diff --git a/docs/OptInWorkflow.md b/docs/OptInWorkflow.md index f23130a5..2fc12205 100644 --- a/docs/OptInWorkflow.md +++ b/docs/OptInWorkflow.md @@ -6,6 +6,7 @@ | ---- | ---- | ----------- | ----- | | **description** | **String** | | | | **image_urls** | **Array<String>** | | | +| **confirmation_response** | **String** | | [optional] | ## Example @@ -14,7 +15,8 @@ require 'bandwidth-sdk' instance = Bandwidth::OptInWorkflow.new( description: Opt In Flow, - image_urls: null + image_urls: null, + confirmation_response: Thank you for opting in! ) ``` diff --git a/docs/RbmActionBase.md b/docs/RbmActionBase.md index 45bdee54..28ea77d5 100644 --- a/docs/RbmActionBase.md +++ b/docs/RbmActionBase.md @@ -16,7 +16,7 @@ require 'bandwidth-sdk' instance = Bandwidth::RbmActionBase.new( type: null, text: Hello world, - postback_data: [B@12ebfb2d + postback_data: [B@a93c798 ) ``` diff --git a/docs/RbmSuggestionResponse.md b/docs/RbmSuggestionResponse.md index fa28ffb2..a00359ca 100644 --- a/docs/RbmSuggestionResponse.md +++ b/docs/RbmSuggestionResponse.md @@ -14,7 +14,7 @@ require 'bandwidth-sdk' instance = Bandwidth::RbmSuggestionResponse.new( text: Yes, I would like to proceed, - postback_data: [B@12ebfb2d + postback_data: [B@a93c798 ) ``` diff --git a/docs/TfvSubmissionInfo.md b/docs/TfvSubmissionInfo.md index 7cf12b4b..414c10da 100644 --- a/docs/TfvSubmissionInfo.md +++ b/docs/TfvSubmissionInfo.md @@ -16,6 +16,9 @@ | **privacy_policy_url** | **String** | The Toll-Free Verification request privacy policy URL. | [optional] | | **terms_and_conditions_url** | **String** | The Toll-Free Verification request terms and conditions policy URL. | [optional] | | **business_dba** | **String** | The company 'Doing Business As'. | [optional] | +| **business_registration_number** | **String** | US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. | [optional] | +| **business_registration_type** | [**BusinessRegistrationTypeEnum**](BusinessRegistrationTypeEnum.md) | | [optional] | +| **business_entity_type** | [**BusinessEntityTypeEnum**](BusinessEntityTypeEnum.md) | | [optional] | ## Example @@ -34,7 +37,10 @@ instance = Bandwidth::TfvSubmissionInfo.new( isv_reseller: Test ISV, privacy_policy_url: http://your-company.com/privacyPolicy, terms_and_conditions_url: http://your-company.com/termsAndConditions, - business_dba: Another Company Name Inc. + business_dba: Another Company Name Inc., + business_registration_number: 12-3456789, + business_registration_type: null, + business_entity_type: null ) ``` diff --git a/docs/VerificationRequest.md b/docs/VerificationRequest.md index a0cf0535..73e09f33 100644 --- a/docs/VerificationRequest.md +++ b/docs/VerificationRequest.md @@ -17,6 +17,11 @@ | **privacy_policy_url** | **String** | The Toll-Free Verification request privacy policy URL. | [optional] | | **terms_and_conditions_url** | **String** | The Toll-Free Verification request terms and conditions policy URL. | [optional] | | **business_dba** | **String** | The company 'Doing Business As'. | [optional] | +| **business_registration_number** | **String** | US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. | [optional] | +| **business_registration_type** | [**BusinessRegistrationTypeEnum**](BusinessRegistrationTypeEnum.md) | | [optional] | +| **business_entity_type** | [**BusinessEntityTypeEnum**](BusinessEntityTypeEnum.md) | | [optional] | +| **help_message_response** | **String** | A message that gets sent to users requesting help. | [optional] | +| **age_gated_content** | **Boolean** | Indicates whether the content is age-gated. | [optional] | ## Example @@ -36,7 +41,12 @@ instance = Bandwidth::VerificationRequest.new( isv_reseller: Test ISV, privacy_policy_url: http://your-company.com/privacyPolicy, terms_and_conditions_url: http://your-company.com/termsAndConditions, - business_dba: Another Company Name Inc. + business_dba: Another Company Name Inc., + business_registration_number: 12-3456789, + business_registration_type: null, + business_entity_type: null, + help_message_response: Please contact support for assistance., + age_gated_content: false ) ``` diff --git a/docs/VerificationUpdateRequest.md b/docs/VerificationUpdateRequest.md index dd8f9b30..f7492d38 100644 --- a/docs/VerificationUpdateRequest.md +++ b/docs/VerificationUpdateRequest.md @@ -16,6 +16,11 @@ | **privacy_policy_url** | **String** | The Toll-Free Verification request privacy policy URL. | [optional] | | **terms_and_conditions_url** | **String** | The Toll-Free Verification request terms and conditions policy URL. | [optional] | | **business_dba** | **String** | The company 'Doing Business As'. | [optional] | +| **business_registration_number** | **String** | US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. | [optional] | +| **business_registration_type** | [**BusinessRegistrationTypeEnum**](BusinessRegistrationTypeEnum.md) | | [optional] | +| **business_entity_type** | [**BusinessEntityTypeEnum**](BusinessEntityTypeEnum.md) | | [optional] | +| **help_message_response** | **String** | A message that gets sent to users requesting help. | [optional] | +| **age_gated_content** | **Boolean** | Indicates whether the content is age-gated. | [optional] | ## Example @@ -34,7 +39,12 @@ instance = Bandwidth::VerificationUpdateRequest.new( isv_reseller: Test ISV, privacy_policy_url: http://your-company.com/privacyPolicy, terms_and_conditions_url: http://your-company.com/termsAndConditions, - business_dba: Another Company Name Inc. + business_dba: Another Company Name Inc., + business_registration_number: 12-3456789, + business_registration_type: null, + business_entity_type: null, + help_message_response: Please contact support for assistance., + age_gated_content: false ) ``` diff --git a/lib/bandwidth-sdk.rb b/lib/bandwidth-sdk.rb index 25d119a9..c865cd01 100644 --- a/lib/bandwidth-sdk.rb +++ b/lib/bandwidth-sdk.rb @@ -24,6 +24,8 @@ require 'bandwidth-sdk/models/blocked_webhook' require 'bandwidth-sdk/models/bridge_complete_callback' require 'bandwidth-sdk/models/bridge_target_complete_callback' +require 'bandwidth-sdk/models/business_entity_type_enum' +require 'bandwidth-sdk/models/business_registration_type_enum' require 'bandwidth-sdk/models/call_direction_enum' require 'bandwidth-sdk/models/call_recording_metadata' require 'bandwidth-sdk/models/call_state' diff --git a/lib/bandwidth-sdk/api/messages_api.rb b/lib/bandwidth-sdk/api/messages_api.rb index 079afbc4..608c19af 100644 --- a/lib/bandwidth-sdk/api/messages_api.rb +++ b/lib/bandwidth-sdk/api/messages_api.rb @@ -112,6 +112,8 @@ def create_message_with_http_info(account_id, message_request, opts = {}) # @option opts [Boolean] :bw_queued A boolean value indicating whether the message is queued in the Bandwidth network. # @option opts [ProductTypeEnum] :product Messaging product associated with the message. # @option opts [String] :location Location Id associated with the message. + # @option opts [Boolean] :carrier_queued A boolean value indicating whether the message is queued in the carrier network. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. + # @option opts [Integer] :from_carrier_latency The minimum carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. # @option opts [String] :calling_number_country_a3 Calling number country in A3 format. # @option opts [String] :called_number_country_a3 Called number country in A3 format. # @option opts [Integer] :from_segment_count Segment count (start range). @@ -147,6 +149,8 @@ def list_messages(account_id, opts = {}) # @option opts [Boolean] :bw_queued A boolean value indicating whether the message is queued in the Bandwidth network. # @option opts [ProductTypeEnum] :product Messaging product associated with the message. # @option opts [String] :location Location Id associated with the message. + # @option opts [Boolean] :carrier_queued A boolean value indicating whether the message is queued in the carrier network. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. + # @option opts [Integer] :from_carrier_latency The minimum carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. # @option opts [String] :calling_number_country_a3 Calling number country in A3 format. # @option opts [String] :called_number_country_a3 Called number country in A3 format. # @option opts [Integer] :from_segment_count Segment count (start range). @@ -186,6 +190,8 @@ def list_messages_with_http_info(account_id, opts = {}) query_params[:'bwQueued'] = opts[:'bw_queued'] if !opts[:'bw_queued'].nil? query_params[:'product'] = opts[:'product'] if !opts[:'product'].nil? query_params[:'location'] = opts[:'location'] if !opts[:'location'].nil? + query_params[:'carrierQueued'] = opts[:'carrier_queued'] if !opts[:'carrier_queued'].nil? + query_params[:'fromCarrierLatency'] = opts[:'from_carrier_latency'] if !opts[:'from_carrier_latency'].nil? query_params[:'callingNumberCountryA3'] = opts[:'calling_number_country_a3'] if !opts[:'calling_number_country_a3'].nil? query_params[:'calledNumberCountryA3'] = opts[:'called_number_country_a3'] if !opts[:'called_number_country_a3'].nil? query_params[:'fromSegmentCount'] = opts[:'from_segment_count'] if !opts[:'from_segment_count'].nil? diff --git a/lib/bandwidth-sdk/models/business_entity_type_enum.rb b/lib/bandwidth-sdk/models/business_entity_type_enum.rb new file mode 100644 index 00000000..0f01f9ec --- /dev/null +++ b/lib/bandwidth-sdk/models/business_entity_type_enum.rb @@ -0,0 +1,43 @@ +=begin +#Bandwidth + +#Bandwidth's Communication APIs + +The version of the OpenAPI document: 1.0.0 +Contact: letstalk@bandwidth.com +Generated by: https://openapi-generator.tech +Generator version: 7.8.0 + +=end + +require 'date' +require 'time' + +module Bandwidth + class BusinessEntityTypeEnum + SOLE_PROPRIETOR = 'SOLE_PROPRIETOR'.freeze + PRIVATE_PROFIT = 'PRIVATE_PROFIT'.freeze + PUBLIC_PROFIT = 'PUBLIC_PROFIT'.freeze + NON_PROFIT = 'NON_PROFIT'.freeze + GOVERNMENT = 'GOVERNMENT'.freeze + + def self.all_vars + @all_vars ||= [SOLE_PROPRIETOR, PRIVATE_PROFIT, PUBLIC_PROFIT, NON_PROFIT, GOVERNMENT].freeze + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def self.build_from_hash(value) + new.build_from_hash(value) + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def build_from_hash(value) + return value if BusinessEntityTypeEnum.all_vars.include?(value) + raise "Invalid ENUM value #{value} for class #BusinessEntityTypeEnum" + end + end +end diff --git a/lib/bandwidth-sdk/models/business_registration_type_enum.rb b/lib/bandwidth-sdk/models/business_registration_type_enum.rb new file mode 100644 index 00000000..6b89e45b --- /dev/null +++ b/lib/bandwidth-sdk/models/business_registration_type_enum.rb @@ -0,0 +1,40 @@ +=begin +#Bandwidth + +#Bandwidth's Communication APIs + +The version of the OpenAPI document: 1.0.0 +Contact: letstalk@bandwidth.com +Generated by: https://openapi-generator.tech +Generator version: 7.8.0 + +=end + +require 'date' +require 'time' + +module Bandwidth + class BusinessRegistrationTypeEnum + EIN = 'EIN'.freeze + CBN = 'CBN'.freeze + + def self.all_vars + @all_vars ||= [EIN, CBN].freeze + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def self.build_from_hash(value) + new.build_from_hash(value) + end + + # Builds the enum from string + # @param [String] The enum value in the form of the string + # @return [String] The enum value + def build_from_hash(value) + return value if BusinessRegistrationTypeEnum.all_vars.include?(value) + raise "Invalid ENUM value #{value} for class #BusinessRegistrationTypeEnum" + end + end +end diff --git a/lib/bandwidth-sdk/models/list_message_item.rb b/lib/bandwidth-sdk/models/list_message_item.rb index 0cb2be76..b121a706 100644 --- a/lib/bandwidth-sdk/models/list_message_item.rb +++ b/lib/bandwidth-sdk/models/list_message_item.rb @@ -66,6 +66,9 @@ class ListMessageItem # The Bandwidth latency of the message in seconds. Only available for accounts with the Advanced Quality Metrics feature enabled. attr_accessor :bw_latency + # The carrier latency of the message in seconds. Only available for OUTBOUND messages from accounts with the Advanced Quality Metrics feature enabled. + attr_accessor :carrier_latency + # The A3 country code of the calling number. attr_accessor :calling_number_country_a3 @@ -121,6 +124,7 @@ def self.attribute_map :'campaign_class' => :'campaignClass', :'campaign_id' => :'campaignId', :'bw_latency' => :'bwLatency', + :'carrier_latency' => :'carrierLatency', :'calling_number_country_a3' => :'callingNumberCountryA3', :'called_number_country_a3' => :'calledNumberCountryA3', :'product' => :'product', @@ -154,6 +158,7 @@ def self.openapi_types :'campaign_class' => :'String', :'campaign_id' => :'String', :'bw_latency' => :'Integer', + :'carrier_latency' => :'Integer', :'calling_number_country_a3' => :'String', :'called_number_country_a3' => :'String', :'product' => :'String', @@ -171,6 +176,7 @@ def self.openapi_nullable :'campaign_class', :'campaign_id', :'bw_latency', + :'carrier_latency', :'calling_number_country_a3', :'called_number_country_a3', :'product', @@ -265,6 +271,10 @@ def initialize(attributes = {}) self.bw_latency = attributes[:'bw_latency'] end + if attributes.key?(:'carrier_latency') + self.carrier_latency = attributes[:'carrier_latency'] + end + if attributes.key?(:'calling_number_country_a3') self.calling_number_country_a3 = attributes[:'calling_number_country_a3'] end @@ -320,6 +330,7 @@ def ==(o) campaign_class == o.campaign_class && campaign_id == o.campaign_id && bw_latency == o.bw_latency && + carrier_latency == o.carrier_latency && calling_number_country_a3 == o.calling_number_country_a3 && called_number_country_a3 == o.called_number_country_a3 && product == o.product && @@ -335,7 +346,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [message_id, account_id, source_tn, destination_tn, message_status, message_direction, message_type, segment_count, error_code, receive_time, carrier_name, message_size, message_length, attachment_count, recipient_count, campaign_class, campaign_id, bw_latency, calling_number_country_a3, called_number_country_a3, product, location].hash + [message_id, account_id, source_tn, destination_tn, message_status, message_direction, message_type, segment_count, error_code, receive_time, carrier_name, message_size, message_length, attachment_count, recipient_count, campaign_class, campaign_id, bw_latency, carrier_latency, calling_number_country_a3, called_number_country_a3, product, location].hash end # Builds the object from hash diff --git a/lib/bandwidth-sdk/models/opt_in_workflow.rb b/lib/bandwidth-sdk/models/opt_in_workflow.rb index e4ea2df4..0bb00c69 100644 --- a/lib/bandwidth-sdk/models/opt_in_workflow.rb +++ b/lib/bandwidth-sdk/models/opt_in_workflow.rb @@ -19,11 +19,14 @@ class OptInWorkflow attr_accessor :image_urls + attr_accessor :confirmation_response + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { :'description' => :'description', - :'image_urls' => :'imageUrls' + :'image_urls' => :'imageUrls', + :'confirmation_response' => :'confirmationResponse' } end @@ -36,13 +39,15 @@ def self.acceptable_attributes def self.openapi_types { :'description' => :'String', - :'image_urls' => :'Array' + :'image_urls' => :'Array', + :'confirmation_response' => :'String' } end # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'confirmation_response' ]) end @@ -74,6 +79,10 @@ def initialize(attributes = {}) else self.image_urls = nil end + + if attributes.key?(:'confirmation_response') + self.confirmation_response = attributes[:'confirmation_response'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -97,6 +106,14 @@ def list_invalid_properties invalid_properties.push('invalid value for "image_urls", image_urls cannot be nil.') end + if !@confirmation_response.nil? && @confirmation_response.to_s.length > 500 + invalid_properties.push('invalid value for "confirmation_response", the character length must be smaller than or equal to 500.') + end + + if !@confirmation_response.nil? && @confirmation_response.to_s.length < 0 + invalid_properties.push('invalid value for "confirmation_response", the character length must be great than or equal to 0.') + end + invalid_properties end @@ -108,6 +125,8 @@ def valid? return false if @description.to_s.length > 500 return false if @description.to_s.length < 1 return false if @image_urls.nil? + return false if !@confirmation_response.nil? && @confirmation_response.to_s.length > 500 + return false if !@confirmation_response.nil? && @confirmation_response.to_s.length < 0 true end @@ -129,13 +148,28 @@ def description=(description) @description = description end + # Custom attribute writer method with validation + # @param [Object] confirmation_response Value to be assigned + def confirmation_response=(confirmation_response) + if !confirmation_response.nil? && confirmation_response.to_s.length > 500 + fail ArgumentError, 'invalid value for "confirmation_response", the character length must be smaller than or equal to 500.' + end + + if !confirmation_response.nil? && confirmation_response.to_s.length < 0 + fail ArgumentError, 'invalid value for "confirmation_response", the character length must be great than or equal to 0.' + end + + @confirmation_response = confirmation_response + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) return true if self.equal?(o) self.class == o.class && description == o.description && - image_urls == o.image_urls + image_urls == o.image_urls && + confirmation_response == o.confirmation_response end # @see the `==` method @@ -147,7 +181,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [description, image_urls].hash + [description, image_urls, confirmation_response].hash end # Builds the object from hash diff --git a/lib/bandwidth-sdk/models/tfv_submission_info.rb b/lib/bandwidth-sdk/models/tfv_submission_info.rb index 39f610b9..e6bf148b 100644 --- a/lib/bandwidth-sdk/models/tfv_submission_info.rb +++ b/lib/bandwidth-sdk/models/tfv_submission_info.rb @@ -48,6 +48,35 @@ class TfvSubmissionInfo # The company 'Doing Business As'. attr_accessor :business_dba + # US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. + attr_accessor :business_registration_number + + attr_accessor :business_registration_type + + attr_accessor :business_entity_type + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -62,7 +91,10 @@ def self.attribute_map :'isv_reseller' => :'isvReseller', :'privacy_policy_url' => :'privacyPolicyUrl', :'terms_and_conditions_url' => :'termsAndConditionsUrl', - :'business_dba' => :'businessDba' + :'business_dba' => :'businessDba', + :'business_registration_number' => :'businessRegistrationNumber', + :'business_registration_type' => :'businessRegistrationType', + :'business_entity_type' => :'businessEntityType' } end @@ -85,7 +117,10 @@ def self.openapi_types :'isv_reseller' => :'String', :'privacy_policy_url' => :'String', :'terms_and_conditions_url' => :'String', - :'business_dba' => :'String' + :'business_dba' => :'String', + :'business_registration_number' => :'String', + :'business_registration_type' => :'BusinessRegistrationTypeEnum', + :'business_entity_type' => :'BusinessEntityTypeEnum' } end @@ -94,6 +129,9 @@ def self.openapi_nullable Set.new([ :'additional_information', :'isv_reseller', + :'business_registration_number', + :'business_registration_type', + :'business_entity_type' ]) end @@ -159,6 +197,18 @@ def initialize(attributes = {}) if attributes.key?(:'business_dba') self.business_dba = attributes[:'business_dba'] end + + if attributes.key?(:'business_registration_number') + self.business_registration_number = attributes[:'business_registration_number'] + end + + if attributes.key?(:'business_registration_type') + self.business_registration_type = attributes[:'business_registration_type'] + end + + if attributes.key?(:'business_entity_type') + self.business_entity_type = attributes[:'business_entity_type'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -214,6 +264,10 @@ def list_invalid_properties invalid_properties.push('invalid value for "isv_reseller", the character length must be great than or equal to 0.') end + if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 + invalid_properties.push('invalid value for "business_registration_number", the character length must be smaller than or equal to 500.') + end + invalid_properties end @@ -233,6 +287,7 @@ def valid? return false if !@additional_information.nil? && @additional_information.to_s.length < 0 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length > 500 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length < 0 + return false if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 true end @@ -336,6 +391,16 @@ def isv_reseller=(isv_reseller) @isv_reseller = isv_reseller end + # Custom attribute writer method with validation + # @param [Object] business_registration_number Value to be assigned + def business_registration_number=(business_registration_number) + if !business_registration_number.nil? && business_registration_number.to_s.length > 500 + fail ArgumentError, 'invalid value for "business_registration_number", the character length must be smaller than or equal to 500.' + end + + @business_registration_number = business_registration_number + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -352,7 +417,10 @@ def ==(o) isv_reseller == o.isv_reseller && privacy_policy_url == o.privacy_policy_url && terms_and_conditions_url == o.terms_and_conditions_url && - business_dba == o.business_dba + business_dba == o.business_dba && + business_registration_number == o.business_registration_number && + business_registration_type == o.business_registration_type && + business_entity_type == o.business_entity_type end # @see the `==` method @@ -364,7 +432,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [business_address, business_contact, message_volume, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba].hash + [business_address, business_contact, message_volume, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba, business_registration_number, business_registration_type, business_entity_type].hash end # Builds the object from hash diff --git a/lib/bandwidth-sdk/models/verification_request.rb b/lib/bandwidth-sdk/models/verification_request.rb index 1dd90c1a..29364ba2 100644 --- a/lib/bandwidth-sdk/models/verification_request.rb +++ b/lib/bandwidth-sdk/models/verification_request.rb @@ -50,6 +50,41 @@ class VerificationRequest # The company 'Doing Business As'. attr_accessor :business_dba + # US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. + attr_accessor :business_registration_number + + attr_accessor :business_registration_type + + attr_accessor :business_entity_type + + # A message that gets sent to users requesting help. + attr_accessor :help_message_response + + # Indicates whether the content is age-gated. + attr_accessor :age_gated_content + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -65,7 +100,12 @@ def self.attribute_map :'isv_reseller' => :'isvReseller', :'privacy_policy_url' => :'privacyPolicyUrl', :'terms_and_conditions_url' => :'termsAndConditionsUrl', - :'business_dba' => :'businessDba' + :'business_dba' => :'businessDba', + :'business_registration_number' => :'businessRegistrationNumber', + :'business_registration_type' => :'businessRegistrationType', + :'business_entity_type' => :'businessEntityType', + :'help_message_response' => :'helpMessageResponse', + :'age_gated_content' => :'ageGatedContent' } end @@ -89,7 +129,12 @@ def self.openapi_types :'isv_reseller' => :'String', :'privacy_policy_url' => :'String', :'terms_and_conditions_url' => :'String', - :'business_dba' => :'String' + :'business_dba' => :'String', + :'business_registration_number' => :'String', + :'business_registration_type' => :'BusinessRegistrationTypeEnum', + :'business_entity_type' => :'BusinessEntityTypeEnum', + :'help_message_response' => :'String', + :'age_gated_content' => :'Boolean' } end @@ -98,6 +143,10 @@ def self.openapi_nullable Set.new([ :'additional_information', :'isv_reseller', + :'business_registration_number', + :'business_registration_type', + :'business_entity_type', + :'help_message_response', ]) end @@ -185,6 +234,26 @@ def initialize(attributes = {}) if attributes.key?(:'business_dba') self.business_dba = attributes[:'business_dba'] end + + if attributes.key?(:'business_registration_number') + self.business_registration_number = attributes[:'business_registration_number'] + end + + if attributes.key?(:'business_registration_type') + self.business_registration_type = attributes[:'business_registration_type'] + end + + if attributes.key?(:'business_entity_type') + self.business_entity_type = attributes[:'business_entity_type'] + end + + if attributes.key?(:'help_message_response') + self.help_message_response = attributes[:'help_message_response'] + end + + if attributes.key?(:'age_gated_content') + self.age_gated_content = attributes[:'age_gated_content'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -280,6 +349,14 @@ def list_invalid_properties invalid_properties.push('invalid value for "isv_reseller", the character length must be great than or equal to 0.') end + if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 + invalid_properties.push('invalid value for "business_registration_number", the character length must be smaller than or equal to 500.') + end + + if !@help_message_response.nil? && @help_message_response.to_s.length > 500 + invalid_properties.push('invalid value for "help_message_response", the character length must be smaller than or equal to 500.') + end + invalid_properties end @@ -309,6 +386,8 @@ def valid? return false if !@additional_information.nil? && @additional_information.to_s.length < 0 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length > 500 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length < 0 + return false if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 + return false if !@help_message_response.nil? && @help_message_response.to_s.length > 500 true end @@ -430,6 +509,26 @@ def isv_reseller=(isv_reseller) @isv_reseller = isv_reseller end + # Custom attribute writer method with validation + # @param [Object] business_registration_number Value to be assigned + def business_registration_number=(business_registration_number) + if !business_registration_number.nil? && business_registration_number.to_s.length > 500 + fail ArgumentError, 'invalid value for "business_registration_number", the character length must be smaller than or equal to 500.' + end + + @business_registration_number = business_registration_number + end + + # Custom attribute writer method with validation + # @param [Object] help_message_response Value to be assigned + def help_message_response=(help_message_response) + if !help_message_response.nil? && help_message_response.to_s.length > 500 + fail ArgumentError, 'invalid value for "help_message_response", the character length must be smaller than or equal to 500.' + end + + @help_message_response = help_message_response + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -447,7 +546,12 @@ def ==(o) isv_reseller == o.isv_reseller && privacy_policy_url == o.privacy_policy_url && terms_and_conditions_url == o.terms_and_conditions_url && - business_dba == o.business_dba + business_dba == o.business_dba && + business_registration_number == o.business_registration_number && + business_registration_type == o.business_registration_type && + business_entity_type == o.business_entity_type && + help_message_response == o.help_message_response && + age_gated_content == o.age_gated_content end # @see the `==` method @@ -459,7 +563,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [business_address, business_contact, message_volume, phone_numbers, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba].hash + [business_address, business_contact, message_volume, phone_numbers, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba, business_registration_number, business_registration_type, business_entity_type, help_message_response, age_gated_content].hash end # Builds the object from hash diff --git a/lib/bandwidth-sdk/models/verification_update_request.rb b/lib/bandwidth-sdk/models/verification_update_request.rb index 92baf20f..f46a45fc 100644 --- a/lib/bandwidth-sdk/models/verification_update_request.rb +++ b/lib/bandwidth-sdk/models/verification_update_request.rb @@ -48,6 +48,41 @@ class VerificationUpdateRequest # The company 'Doing Business As'. attr_accessor :business_dba + # US Federal Tax ID Number (EIN) or Canada Business Number (CBN). Optional until early 2026. If a value is provided for this field, a value must be provided for `businessRegistrationType` and `businessEntityType`. Available starting October 1st, 2025. + attr_accessor :business_registration_number + + attr_accessor :business_registration_type + + attr_accessor :business_entity_type + + # A message that gets sent to users requesting help. + attr_accessor :help_message_response + + # Indicates whether the content is age-gated. + attr_accessor :age_gated_content + + class EnumAttributeValidator + attr_reader :datatype + attr_reader :allowable_values + + def initialize(datatype, allowable_values) + @allowable_values = allowable_values.map do |value| + case datatype.to_s + when /Integer/i + value.to_i + when /Float/i + value.to_f + else + value + end + end + end + + def valid?(value) + !value || allowable_values.include?(value) + end + end + # Attribute mapping from ruby-style variable name to JSON key. def self.attribute_map { @@ -62,7 +97,12 @@ def self.attribute_map :'isv_reseller' => :'isvReseller', :'privacy_policy_url' => :'privacyPolicyUrl', :'terms_and_conditions_url' => :'termsAndConditionsUrl', - :'business_dba' => :'businessDba' + :'business_dba' => :'businessDba', + :'business_registration_number' => :'businessRegistrationNumber', + :'business_registration_type' => :'businessRegistrationType', + :'business_entity_type' => :'businessEntityType', + :'help_message_response' => :'helpMessageResponse', + :'age_gated_content' => :'ageGatedContent' } end @@ -85,7 +125,12 @@ def self.openapi_types :'isv_reseller' => :'String', :'privacy_policy_url' => :'String', :'terms_and_conditions_url' => :'String', - :'business_dba' => :'String' + :'business_dba' => :'String', + :'business_registration_number' => :'String', + :'business_registration_type' => :'BusinessRegistrationTypeEnum', + :'business_entity_type' => :'BusinessEntityTypeEnum', + :'help_message_response' => :'String', + :'age_gated_content' => :'Boolean' } end @@ -94,6 +139,10 @@ def self.openapi_nullable Set.new([ :'additional_information', :'isv_reseller', + :'business_registration_number', + :'business_registration_type', + :'business_entity_type', + :'help_message_response', ]) end @@ -173,6 +222,26 @@ def initialize(attributes = {}) if attributes.key?(:'business_dba') self.business_dba = attributes[:'business_dba'] end + + if attributes.key?(:'business_registration_number') + self.business_registration_number = attributes[:'business_registration_number'] + end + + if attributes.key?(:'business_registration_type') + self.business_registration_type = attributes[:'business_registration_type'] + end + + if attributes.key?(:'business_entity_type') + self.business_entity_type = attributes[:'business_entity_type'] + end + + if attributes.key?(:'help_message_response') + self.help_message_response = attributes[:'help_message_response'] + end + + if attributes.key?(:'age_gated_content') + self.age_gated_content = attributes[:'age_gated_content'] + end end # Show invalid properties with the reasons. Usually used together with valid? @@ -256,6 +325,14 @@ def list_invalid_properties invalid_properties.push('invalid value for "isv_reseller", the character length must be great than or equal to 0.') end + if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 + invalid_properties.push('invalid value for "business_registration_number", the character length must be smaller than or equal to 500.') + end + + if !@help_message_response.nil? && @help_message_response.to_s.length > 500 + invalid_properties.push('invalid value for "help_message_response", the character length must be smaller than or equal to 500.') + end + invalid_properties end @@ -282,6 +359,8 @@ def valid? return false if !@additional_information.nil? && @additional_information.to_s.length < 0 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length > 500 return false if !@isv_reseller.nil? && @isv_reseller.to_s.length < 0 + return false if !@business_registration_number.nil? && @business_registration_number.to_s.length > 500 + return false if !@help_message_response.nil? && @help_message_response.to_s.length > 500 true end @@ -385,6 +464,26 @@ def isv_reseller=(isv_reseller) @isv_reseller = isv_reseller end + # Custom attribute writer method with validation + # @param [Object] business_registration_number Value to be assigned + def business_registration_number=(business_registration_number) + if !business_registration_number.nil? && business_registration_number.to_s.length > 500 + fail ArgumentError, 'invalid value for "business_registration_number", the character length must be smaller than or equal to 500.' + end + + @business_registration_number = business_registration_number + end + + # Custom attribute writer method with validation + # @param [Object] help_message_response Value to be assigned + def help_message_response=(help_message_response) + if !help_message_response.nil? && help_message_response.to_s.length > 500 + fail ArgumentError, 'invalid value for "help_message_response", the character length must be smaller than or equal to 500.' + end + + @help_message_response = help_message_response + end + # Checks equality by comparing each attribute. # @param [Object] Object to be compared def ==(o) @@ -401,7 +500,12 @@ def ==(o) isv_reseller == o.isv_reseller && privacy_policy_url == o.privacy_policy_url && terms_and_conditions_url == o.terms_and_conditions_url && - business_dba == o.business_dba + business_dba == o.business_dba && + business_registration_number == o.business_registration_number && + business_registration_type == o.business_registration_type && + business_entity_type == o.business_entity_type && + help_message_response == o.help_message_response && + age_gated_content == o.age_gated_content end # @see the `==` method @@ -413,7 +517,7 @@ def eql?(o) # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash - [business_address, business_contact, message_volume, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba].hash + [business_address, business_contact, message_volume, use_case, use_case_summary, production_message_content, opt_in_workflow, additional_information, isv_reseller, privacy_policy_url, terms_and_conditions_url, business_dba, business_registration_number, business_registration_type, business_entity_type, help_message_response, age_gated_content].hash end # Builds the object from hash