Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ bandwidth/models/blocked_webhook.py
bandwidth/models/bridge_complete_callback.py
bandwidth/models/bridge_target_complete_callback.py
bandwidth/models/business_entity_type_enum.py
bandwidth/models/business_registration_issuing_country_enum.py
bandwidth/models/business_registration_type_enum.py
bandwidth/models/call_direction_enum.py
bandwidth/models/call_recording_metadata.py
Expand Down Expand Up @@ -206,6 +207,7 @@ docs/BlockedWebhook.md
docs/BridgeCompleteCallback.md
docs/BridgeTargetCompleteCallback.md
docs/BusinessEntityTypeEnum.md
docs/BusinessRegistrationIssuingCountryEnum.md
docs/BusinessRegistrationTypeEnum.md
docs/CallDirectionEnum.md
docs/CallRecordingMetadata.md
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ Class | Method | HTTP request | Description
- [BridgeCompleteCallback](docs/BridgeCompleteCallback.md)
- [BridgeTargetCompleteCallback](docs/BridgeTargetCompleteCallback.md)
- [BusinessEntityTypeEnum](docs/BusinessEntityTypeEnum.md)
- [BusinessRegistrationIssuingCountryEnum](docs/BusinessRegistrationIssuingCountryEnum.md)
- [BusinessRegistrationTypeEnum](docs/BusinessRegistrationTypeEnum.md)
- [CallDirectionEnum](docs/CallDirectionEnum.md)
- [CallRecordingMetadata](docs/CallRecordingMetadata.md)
Expand Down
111 changes: 88 additions & 23 deletions bandwidth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5828,38 +5828,106 @@ components:
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.
description: Government-issued business identifying number.
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.
description: The type of business registration number.
enum:
- EIN
- CBN
- NEQ
- PROVINCIAL_NUMBER
- CRN
- VAT
- ACN
- ABN
- BRN
- SIREN
- SIRET
- NZBN
- UST_IDNR
- CIF
- NIF
- CNPJ
- UID
- OTHER
nullable: true
businessRegistrationIssuingCountryEnum:
type: string
description: >-
The country issuing the business registration in ISO-3166-1 alpha-3
format.


| Registration Type | Supported Countries |

|----------------------|------------------------------------|

| EIN | USA |

| CBN | CAN |

| NEQ | CAN |

| PROVINCIAL_NUMBER | CAN |

| CRN | GBR, HKG |

| VAT | GBR, IRL, BRA, NLD |

| ACN | AUS |

| ABN | AUS |

| BRN | HKG |

| SIREN | FRA |

| SIRET | FRA |

| NZBN | NZL |

| UST_IDNR | DEU |

| CIF | ESP |

| NIF | ESP |

| CNPJ | BRA |

| UID | CHE |

| OTHER | Must Provide Country Code |
enum:
- USA
- CAN
- HKG
- GBR
- IRL
- BRA
- NLD
- AUS
- FRA
- NZL
- DEU
- ESP
- CHE
nullable: false
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.
provide "SOLE_PROPRIETOR" as a value.
enum:
- SOLE_PROPRIETOR
- PRIVATE_PROFIT
- PUBLIC_PROFIT
- NON_PROFIT
- GOVERNMENT
nullable: true
nullable: false
helpMessageResponse:
type: string
description: A message that gets sent to users requesting help.
Expand Down Expand Up @@ -5914,6 +5982,7 @@ components:
- useCaseSummary
- productionMessageContent
- optInWorkflow
- businessEntityType
properties:
businessAddress:
$ref: '#/components/schemas/address'
Expand Down Expand Up @@ -5958,6 +6027,8 @@ components:
$ref: '#/components/schemas/businessRegistrationNumber'
businessRegistrationType:
$ref: '#/components/schemas/businessRegistrationTypeEnum'
businessRegistrationIssuingCountry:
$ref: '#/components/schemas/businessRegistrationIssuingCountryEnum'
businessEntityType:
$ref: '#/components/schemas/businessEntityTypeEnum'
helpMessageResponse:
Expand Down Expand Up @@ -6011,6 +6082,8 @@ components:
$ref: '#/components/schemas/businessRegistrationTypeEnum'
businessEntityType:
$ref: '#/components/schemas/businessEntityTypeEnum'
businessRegistrationIssuingCountry:
$ref: '#/components/schemas/businessRegistrationIssuingCountryEnum'
helpMessageResponse:
$ref: '#/components/schemas/helpMessageResponse'
ageGatedContent:
Expand Down Expand Up @@ -6503,20 +6576,12 @@ components:
$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.
businessRegistrationIssuingCountry:
$ref: '#/components/schemas/businessRegistrationIssuingCountryEnum'
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:
Expand Down
2 changes: 2 additions & 0 deletions bandwidth/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
"BridgeCompleteCallback",
"BridgeTargetCompleteCallback",
"BusinessEntityTypeEnum",
"BusinessRegistrationIssuingCountryEnum",
"BusinessRegistrationTypeEnum",
"CallDirectionEnum",
"CallRecordingMetadata",
Expand Down Expand Up @@ -251,6 +252,7 @@
from bandwidth.models.bridge_complete_callback import BridgeCompleteCallback as BridgeCompleteCallback
from bandwidth.models.bridge_target_complete_callback import BridgeTargetCompleteCallback as BridgeTargetCompleteCallback
from bandwidth.models.business_entity_type_enum import BusinessEntityTypeEnum as BusinessEntityTypeEnum
from bandwidth.models.business_registration_issuing_country_enum import BusinessRegistrationIssuingCountryEnum as BusinessRegistrationIssuingCountryEnum
from bandwidth.models.business_registration_type_enum import BusinessRegistrationTypeEnum as BusinessRegistrationTypeEnum
from bandwidth.models.call_direction_enum import CallDirectionEnum as CallDirectionEnum
from bandwidth.models.call_recording_metadata import CallRecordingMetadata as CallRecordingMetadata
Expand Down
1 change: 1 addition & 0 deletions bandwidth/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
from bandwidth.models.bridge_complete_callback import BridgeCompleteCallback
from bandwidth.models.bridge_target_complete_callback import BridgeTargetCompleteCallback
from bandwidth.models.business_entity_type_enum import BusinessEntityTypeEnum
from bandwidth.models.business_registration_issuing_country_enum import BusinessRegistrationIssuingCountryEnum
from bandwidth.models.business_registration_type_enum import BusinessRegistrationTypeEnum
from bandwidth.models.call_direction_enum import CallDirectionEnum
from bandwidth.models.call_recording_metadata import CallRecordingMetadata
Expand Down
2 changes: 1 addition & 1 deletion bandwidth/models/business_entity_type_enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

class BusinessEntityTypeEnum(str, Enum):
"""
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.
The type of registered business. If no option is applicable, please provide \"SOLE_PROPRIETOR\" as a value.
"""

"""
Expand Down
49 changes: 49 additions & 0 deletions bandwidth/models/business_registration_issuing_country_enum.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# coding: utf-8

"""
Bandwidth

Bandwidth's Communication APIs

The version of the OpenAPI document: 1.0.0
Contact: letstalk@bandwidth.com
Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.
""" # noqa: E501


from __future__ import annotations
import json
from enum import Enum
from typing_extensions import Self


class BusinessRegistrationIssuingCountryEnum(str, Enum):
"""
The country issuing the business registration in ISO-3166-1 alpha-3 format. | Registration Type | Supported Countries | |----------------------|------------------------------------| | EIN | USA | | CBN | CAN | | NEQ | CAN | | PROVINCIAL_NUMBER | CAN | | CRN | GBR, HKG | | VAT | GBR, IRL, BRA, NLD | | ACN | AUS | | ABN | AUS | | BRN | HKG | | SIREN | FRA | | SIRET | FRA | | NZBN | NZL | | UST_IDNR | DEU | | CIF | ESP | | NIF | ESP | | CNPJ | BRA | | UID | CHE | | OTHER | Must Provide Country Code |
"""

"""
allowed enum values
"""
USA = 'USA'
CAN = 'CAN'
HKG = 'HKG'
GBR = 'GBR'
IRL = 'IRL'
BRA = 'BRA'
NLD = 'NLD'
AUS = 'AUS'
FRA = 'FRA'
NZL = 'NZL'
DEU = 'DEU'
ESP = 'ESP'
CHE = 'CHE'

@classmethod
def from_json(cls, json_str: str) -> Self:
"""Create an instance of BusinessRegistrationIssuingCountryEnum from a JSON string"""
return cls(json.loads(json_str))


18 changes: 17 additions & 1 deletion bandwidth/models/business_registration_type_enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,30 @@

class BusinessRegistrationTypeEnum(str, Enum):
"""
The type of business registration number. Optional until early 2026; required if `businessRegistrationNumber` is provided. Available starting October 1st, 2025.
The type of business registration number.
"""

"""
allowed enum values
"""
EIN = 'EIN'
CBN = 'CBN'
NEQ = 'NEQ'
PROVINCIAL_NUMBER = 'PROVINCIAL_NUMBER'
CRN = 'CRN'
VAT = 'VAT'
ACN = 'ACN'
ABN = 'ABN'
BRN = 'BRN'
SIREN = 'SIREN'
SIRET = 'SIRET'
NZBN = 'NZBN'
UST_IDNR = 'UST_IDNR'
CIF = 'CIF'
NIF = 'NIF'
CNPJ = 'CNPJ'
UID = 'UID'
OTHER = 'OTHER'

@classmethod
def from_json(cls, json_str: str) -> Self:
Expand Down
12 changes: 5 additions & 7 deletions bandwidth/models/tfv_submission_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
from typing_extensions import Annotated
from bandwidth.models.address import Address
from bandwidth.models.business_entity_type_enum import BusinessEntityTypeEnum
from bandwidth.models.business_registration_issuing_country_enum import BusinessRegistrationIssuingCountryEnum
from bandwidth.models.business_registration_type_enum import BusinessRegistrationTypeEnum
from bandwidth.models.contact import Contact
from bandwidth.models.opt_in_workflow import OptInWorkflow
Expand All @@ -45,11 +46,12 @@ class TfvSubmissionInfo(BaseModel):
privacy_policy_url: Optional[StrictStr] = Field(default=None, description="The Toll-Free Verification request privacy policy URL.", alias="privacyPolicyUrl")
terms_and_conditions_url: Optional[StrictStr] = Field(default=None, description="The Toll-Free Verification request terms and conditions policy URL.", alias="termsAndConditionsUrl")
business_dba: Optional[StrictStr] = Field(default=None, description="The company 'Doing Business As'.", alias="businessDba")
business_registration_number: Optional[Annotated[str, Field(strict=True, max_length=500)]] = Field(default=None, 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.", alias="businessRegistrationNumber")
business_registration_number: Optional[Annotated[str, Field(strict=True, max_length=500)]] = Field(default=None, description="Government-issued business identifying number.", alias="businessRegistrationNumber")
business_registration_type: Optional[BusinessRegistrationTypeEnum] = Field(default=None, alias="businessRegistrationType")
business_registration_issuing_country: Optional[BusinessRegistrationIssuingCountryEnum] = Field(default=None, alias="businessRegistrationIssuingCountry")
business_entity_type: Optional[BusinessEntityTypeEnum] = Field(default=None, alias="businessEntityType")
additional_properties: Dict[str, Any] = {}
__properties: ClassVar[List[str]] = ["businessAddress", "businessContact", "messageVolume", "useCase", "useCaseSummary", "productionMessageContent", "optInWorkflow", "additionalInformation", "isvReseller", "privacyPolicyUrl", "termsAndConditionsUrl", "businessDba", "businessRegistrationNumber", "businessRegistrationType", "businessEntityType"]
__properties: ClassVar[List[str]] = ["businessAddress", "businessContact", "messageVolume", "useCase", "useCaseSummary", "productionMessageContent", "optInWorkflow", "additionalInformation", "isvReseller", "privacyPolicyUrl", "termsAndConditionsUrl", "businessDba", "businessRegistrationNumber", "businessRegistrationType", "businessRegistrationIssuingCountry", "businessEntityType"]

model_config = ConfigDict(
populate_by_name=True,
Expand Down Expand Up @@ -126,11 +128,6 @@ def to_dict(self) -> Dict[str, Any]:
if self.business_registration_type is None and "business_registration_type" in self.model_fields_set:
_dict['businessRegistrationType'] = None

# set to None if business_entity_type (nullable) is None
# and model_fields_set contains the field
if self.business_entity_type is None and "business_entity_type" in self.model_fields_set:
_dict['businessEntityType'] = None

return _dict

@classmethod
Expand All @@ -157,6 +154,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"businessDba": obj.get("businessDba"),
"businessRegistrationNumber": obj.get("businessRegistrationNumber"),
"businessRegistrationType": obj.get("businessRegistrationType"),
"businessRegistrationIssuingCountry": obj.get("businessRegistrationIssuingCountry"),
"businessEntityType": obj.get("businessEntityType")
})
# store additional fields in additional_properties
Expand Down
Loading