From 6fdb60cbdf6ba835734496de2870b3231fcd6ed5 Mon Sep 17 00:00:00 2001 From: DX-Bandwidth Date: Tue, 9 Dec 2025 14:06:31 +0000 Subject: [PATCH 1/3] Generate SDK with OpenAPI Generator Version --- .openapi-generator/FILES | 4 ++ README.md | 12 +++++ bandwidth.yml | 40 +++++++++++++++++ bandwidth/__init__.py | 4 ++ bandwidth/api/calls_api.py | 15 ++++--- bandwidth/api/conferences_api.py | 27 +++++++---- bandwidth/api/media_api.py | 12 +++-- bandwidth/api/messages_api.py | 6 ++- bandwidth/api/mfa_api.py | 9 ++-- bandwidth/api/multi_channel_api.py | 3 +- bandwidth/api/phone_number_lookup_api.py | 9 ++-- bandwidth/api/recordings_api.py | 30 ++++++++----- bandwidth/api/statistics_api.py | 3 +- bandwidth/api/toll_free_verification_api.py | 27 +++++++---- bandwidth/api/transcriptions_api.py | 9 ++-- bandwidth/configuration.py | 8 ++++ bandwidth/models/__init__.py | 2 + bandwidth/models/rbm_action_open_url.py | 12 +++-- bandwidth/models/rbm_open_url_enum.py | 38 ++++++++++++++++ bandwidth/models/rbm_veb_view_enum.py | 39 ++++++++++++++++ docs/CallsApi.md | 25 ++++++++--- docs/ConferencesApi.md | 45 +++++++++++++++---- docs/MFAApi.md | 15 +++++-- docs/MediaApi.md | 20 +++++++-- docs/MessagesApi.md | 10 ++++- docs/MultiChannelAction.md | 2 + docs/MultiChannelApi.md | 5 ++- docs/PhoneNumberLookupApi.md | 15 +++++-- docs/RbmActionOpenUrl.md | 2 + docs/RbmOpenUrlEnum.md | 13 ++++++ docs/RbmVebViewEnum.md | 15 +++++++ docs/RecordingsApi.md | 50 ++++++++++++++++----- docs/StatisticsApi.md | 5 ++- docs/TollFreeVerificationApi.md | 45 +++++++++++++++---- docs/TranscriptionsApi.md | 15 +++++-- 35 files changed, 488 insertions(+), 103 deletions(-) create mode 100644 bandwidth/models/rbm_open_url_enum.py create mode 100644 bandwidth/models/rbm_veb_view_enum.py create mode 100644 docs/RbmOpenUrlEnum.md create mode 100644 docs/RbmVebViewEnum.md diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index acb0f106..1fa2389b 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -145,8 +145,10 @@ bandwidth/models/rbm_message_content_file.py bandwidth/models/rbm_message_content_rich_card.py bandwidth/models/rbm_message_content_text.py bandwidth/models/rbm_message_media.py +bandwidth/models/rbm_open_url_enum.py bandwidth/models/rbm_standalone_card.py bandwidth/models/rbm_suggestion_response.py +bandwidth/models/rbm_veb_view_enum.py bandwidth/models/recording_available_callback.py bandwidth/models/recording_complete_callback.py bandwidth/models/recording_state_enum.py @@ -328,8 +330,10 @@ docs/RbmMessageContentFile.md docs/RbmMessageContentRichCard.md docs/RbmMessageContentText.md docs/RbmMessageMedia.md +docs/RbmOpenUrlEnum.md docs/RbmStandaloneCard.md docs/RbmSuggestionResponse.md +docs/RbmVebViewEnum.md docs/RecordingAvailableCallback.md docs/RecordingCompleteCallback.md docs/RecordingStateEnum.md diff --git a/README.md b/README.md index 13a914a2..296637ba 100644 --- a/README.md +++ b/README.md @@ -73,6 +73,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: @@ -277,8 +279,10 @@ Class | Method | HTTP request | Description - [RbmMessageContentRichCard](docs/RbmMessageContentRichCard.md) - [RbmMessageContentText](docs/RbmMessageContentText.md) - [RbmMessageMedia](docs/RbmMessageMedia.md) + - [RbmOpenUrlEnum](docs/RbmOpenUrlEnum.md) - [RbmStandaloneCard](docs/RbmStandaloneCard.md) - [RbmSuggestionResponse](docs/RbmSuggestionResponse.md) + - [RbmVebViewEnum](docs/RbmVebViewEnum.md) - [RecordingAvailableCallback](docs/RecordingAvailableCallback.md) - [RecordingCompleteCallback](docs/RecordingCompleteCallback.md) - [RecordingStateEnum](docs/RecordingStateEnum.md) @@ -337,6 +341,14 @@ Authentication schemes defined for the API: - **Type**: HTTP basic authentication + +### OAuth2 + +- **Type**: OAuth +- **Flow**: application +- **Authorization URL**: +- **Scopes**: N/A + ## Author diff --git a/bandwidth.yml b/bandwidth.yml index 6ee15ae1..db625ad7 100644 --- a/bandwidth.yml +++ b/bandwidth.yml @@ -9,6 +9,7 @@ info: version: 1.0.0 security: - Basic: [] + - OAuth2: [] tags: - name: Messages - name: Media @@ -2377,6 +2378,35 @@ components: - OPEN_URL - REQUEST_LOCATION example: REPLY + rbmOpenUrlEnum: + type: string + description: >- + Specifies how the URL should be opened on a mobile device. + + - `BROWSER` Opens the URL in the device's default browser. If + application is not set or the device doesn’t support WebView, this + option is used by default. + + - `WEBVIEW` Opens the URL in an in-app WebView. + enum: + - BROWSER + - WEBVIEW + example: WEBVIEW + rbmVebViewEnum: + type: string + description: >- + Defines the layout of the WebView on a mobile device. It must be defined + when application is set to `WEBVIEW` + + - `FULL` WebView takes the full screen. + + - `HALF` WebView takes half of the screen. + + - `TALL` WebView takes three-quarters of the screen. + enum: + - FULL + - HALF + - TALL rbmActionText: title: Text type: string @@ -2481,6 +2511,10 @@ components: description: The URL to open in browser. example: https://dev.bandwidth.com maxLength: 2048 + application: + $ref: '#/components/schemas/rbmOpenUrlEnum' + webviewViewMode: + $ref: '#/components/schemas/rbmVebViewEnum' required: - url multiChannelFullActions: @@ -8427,6 +8461,12 @@ components: - Example: `Authorization: Basic ZGVtbZpwQDU1dzByZA==` + OAuth2: + type: oauth2 + flows: + clientCredentials: + tokenUrl: https://api.bandwidth.com/api/v1/oauth2/token + scopes: {} callbacks: inboundCallback: '{inboundCallbackUrl}': diff --git a/bandwidth/__init__.py b/bandwidth/__init__.py index 553e14dd..fd80976c 100644 --- a/bandwidth/__init__.py +++ b/bandwidth/__init__.py @@ -165,8 +165,10 @@ "RbmMessageContentRichCard", "RbmMessageContentText", "RbmMessageMedia", + "RbmOpenUrlEnum", "RbmStandaloneCard", "RbmSuggestionResponse", + "RbmVebViewEnum", "RecordingAvailableCallback", "RecordingCompleteCallback", "RecordingStateEnum", @@ -366,8 +368,10 @@ from bandwidth.models.rbm_message_content_rich_card import RbmMessageContentRichCard as RbmMessageContentRichCard from bandwidth.models.rbm_message_content_text import RbmMessageContentText as RbmMessageContentText from bandwidth.models.rbm_message_media import RbmMessageMedia as RbmMessageMedia +from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum as RbmOpenUrlEnum from bandwidth.models.rbm_standalone_card import RbmStandaloneCard as RbmStandaloneCard from bandwidth.models.rbm_suggestion_response import RbmSuggestionResponse as RbmSuggestionResponse +from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum as RbmVebViewEnum from bandwidth.models.recording_available_callback import RecordingAvailableCallback as RecordingAvailableCallback from bandwidth.models.recording_complete_callback import RecordingCompleteCallback as RecordingCompleteCallback from bandwidth.models.recording_state_enum import RecordingStateEnum as RecordingStateEnum diff --git a/bandwidth/api/calls_api.py b/bandwidth/api/calls_api.py index f9d754dd..1fe7b9e6 100644 --- a/bandwidth/api/calls_api.py +++ b/bandwidth/api/calls_api.py @@ -338,7 +338,8 @@ def _create_call_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -641,7 +642,8 @@ def _get_call_state_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1048,7 +1050,8 @@ def _list_calls_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1382,7 +1385,8 @@ def _update_call_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1716,7 +1720,8 @@ def _update_call_bxml_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/conferences_api.py b/bandwidth/api/conferences_api.py index a3817228..3fde1cbb 100644 --- a/bandwidth/api/conferences_api.py +++ b/bandwidth/api/conferences_api.py @@ -343,7 +343,8 @@ def _download_conference_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -646,7 +647,8 @@ def _get_conference_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -964,7 +966,8 @@ def _get_conference_member_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1282,7 +1285,8 @@ def _get_conference_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1585,7 +1589,8 @@ def _list_conference_recordings_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1958,7 +1963,8 @@ def _list_conferences_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2289,7 +2295,8 @@ def _update_conference_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2620,7 +2627,8 @@ def _update_conference_bxml_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2966,7 +2974,8 @@ def _update_conference_member_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/media_api.py b/bandwidth/api/media_api.py index 571a3c8a..525e51fa 100644 --- a/bandwidth/api/media_api.py +++ b/bandwidth/api/media_api.py @@ -322,7 +322,8 @@ def _delete_media_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -626,7 +627,8 @@ def _get_media_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -929,7 +931,8 @@ def _list_media_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1345,7 +1348,8 @@ def _upload_media_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/messages_api.py b/bandwidth/api/messages_api.py index 1b89537b..a19d5ae9 100644 --- a/bandwidth/api/messages_api.py +++ b/bandwidth/api/messages_api.py @@ -344,7 +344,8 @@ def _create_message_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1088,7 +1089,8 @@ def _list_messages_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/mfa_api.py b/bandwidth/api/mfa_api.py index 5b10228b..92698d4e 100644 --- a/bandwidth/api/mfa_api.py +++ b/bandwidth/api/mfa_api.py @@ -326,7 +326,8 @@ def _generate_messaging_code_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -630,7 +631,8 @@ def _generate_voice_code_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -937,7 +939,8 @@ def _verify_code_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/multi_channel_api.py b/bandwidth/api/multi_channel_api.py index 703d1a2e..7f929796 100644 --- a/bandwidth/api/multi_channel_api.py +++ b/bandwidth/api/multi_channel_api.py @@ -338,7 +338,8 @@ def _create_multi_channel_message_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/phone_number_lookup_api.py b/bandwidth/api/phone_number_lookup_api.py index 7a18ca86..07f3e6fd 100644 --- a/bandwidth/api/phone_number_lookup_api.py +++ b/bandwidth/api/phone_number_lookup_api.py @@ -315,7 +315,8 @@ def _create_async_bulk_lookup_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -607,7 +608,8 @@ def _create_sync_lookup_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -886,7 +888,8 @@ def _get_async_bulk_lookup_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/recordings_api.py b/bandwidth/api/recordings_api.py index dfdde315..3702ffdf 100644 --- a/bandwidth/api/recordings_api.py +++ b/bandwidth/api/recordings_api.py @@ -340,7 +340,8 @@ def _delete_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -658,7 +659,8 @@ def _delete_recording_media_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -976,7 +978,8 @@ def _delete_recording_transcription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1296,7 +1299,8 @@ def _download_call_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1614,7 +1618,8 @@ def _get_call_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1932,7 +1937,8 @@ def _get_recording_transcription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2288,7 +2294,8 @@ def _list_account_call_recordings_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2591,7 +2598,8 @@ def _list_call_recordings_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2937,7 +2945,8 @@ def _transcribe_call_recording_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -3268,7 +3277,8 @@ def _update_call_recording_state_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/statistics_api.py b/bandwidth/api/statistics_api.py index 4abbbc77..de65a491 100644 --- a/bandwidth/api/statistics_api.py +++ b/bandwidth/api/statistics_api.py @@ -306,7 +306,8 @@ def _get_statistics_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/toll_free_verification_api.py b/bandwidth/api/toll_free_verification_api.py index bdde9268..5c70fa94 100644 --- a/bandwidth/api/toll_free_verification_api.py +++ b/bandwidth/api/toll_free_verification_api.py @@ -340,7 +340,8 @@ def _create_webhook_subscription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -643,7 +644,8 @@ def _delete_verification_request_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -946,7 +948,8 @@ def _delete_webhook_subscription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1249,7 +1252,8 @@ def _get_toll_free_verification_status_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1522,7 +1526,8 @@ def _list_toll_free_use_cases_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -1807,7 +1812,8 @@ def _list_webhook_subscriptions_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2120,7 +2126,8 @@ def _request_toll_free_verification_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2448,7 +2455,8 @@ def _update_toll_free_verification_request_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -2779,7 +2787,8 @@ def _update_webhook_subscription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/api/transcriptions_api.py b/bandwidth/api/transcriptions_api.py index 74f41c32..f90440b3 100644 --- a/bandwidth/api/transcriptions_api.py +++ b/bandwidth/api/transcriptions_api.py @@ -338,7 +338,8 @@ def _delete_real_time_transcription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -656,7 +657,8 @@ def _get_real_time_transcription_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( @@ -959,7 +961,8 @@ def _list_real_time_transcriptions_serialize( # authentication setting _auth_settings: List[str] = [ - 'Basic' + 'Basic', + 'OAuth2' ] return self.api_client.param_serialize( diff --git a/bandwidth/configuration.py b/bandwidth/configuration.py index a7fd607d..5b9f391a 100644 --- a/bandwidth/configuration.py +++ b/bandwidth/configuration.py @@ -115,6 +115,7 @@ "AuthSettings", { "Basic": BasicAuthSetting, + "OAuth2": OAuth2AuthSetting, }, total=False, ) @@ -520,6 +521,13 @@ def auth_settings(self)-> AuthSettings: 'key': 'Authorization', 'value': self.get_basic_auth_token() } + if self.access_token is not None: + auth['OAuth2'] = { + 'type': 'oauth2', + 'in': 'header', + 'key': 'Authorization', + 'value': 'Bearer ' + self.access_token + } return auth def to_debug_report(self) -> str: diff --git a/bandwidth/models/__init__.py b/bandwidth/models/__init__.py index 44352f8c..ced5ba2f 100644 --- a/bandwidth/models/__init__.py +++ b/bandwidth/models/__init__.py @@ -140,8 +140,10 @@ from bandwidth.models.rbm_message_content_rich_card import RbmMessageContentRichCard from bandwidth.models.rbm_message_content_text import RbmMessageContentText from bandwidth.models.rbm_message_media import RbmMessageMedia +from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum from bandwidth.models.rbm_standalone_card import RbmStandaloneCard from bandwidth.models.rbm_suggestion_response import RbmSuggestionResponse +from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum from bandwidth.models.recording_available_callback import RecordingAvailableCallback from bandwidth.models.recording_complete_callback import RecordingCompleteCallback from bandwidth.models.recording_state_enum import RecordingStateEnum diff --git a/bandwidth/models/rbm_action_open_url.py b/bandwidth/models/rbm_action_open_url.py index 8ea946e6..d7a5f06b 100644 --- a/bandwidth/models/rbm_action_open_url.py +++ b/bandwidth/models/rbm_action_open_url.py @@ -19,9 +19,11 @@ import json from pydantic import BaseModel, ConfigDict, Field -from typing import Any, ClassVar, Dict, List, Union +from typing import Any, ClassVar, Dict, List, Optional, Union from typing_extensions import Annotated from bandwidth.models.rbm_action_type_enum import RbmActionTypeEnum +from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum +from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum from typing import Optional, Set from typing_extensions import Self @@ -33,8 +35,10 @@ class RbmActionOpenUrl(BaseModel): text: Annotated[str, Field(strict=True, max_length=25)] = Field(description="Displayed text for user to click") postback_data: Union[Annotated[bytes, Field(strict=True, max_length=2048)], Annotated[str, Field(strict=True, max_length=2048)]] = Field(description="Base64 payload the customer receives when the reply is clicked.", alias="postbackData") url: Annotated[str, Field(strict=True, max_length=2048)] = Field(description="The URL to open in browser.") + application: Optional[RbmOpenUrlEnum] = None + webview_view_mode: Optional[RbmVebViewEnum] = Field(default=None, alias="webviewViewMode") additional_properties: Dict[str, Any] = {} - __properties: ClassVar[List[str]] = ["type", "text", "postbackData", "url"] + __properties: ClassVar[List[str]] = ["type", "text", "postbackData", "url", "application", "webviewViewMode"] model_config = ConfigDict( populate_by_name=True, @@ -97,7 +101,9 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "type": obj.get("type"), "text": obj.get("text"), "postbackData": obj.get("postbackData"), - "url": obj.get("url") + "url": obj.get("url"), + "application": obj.get("application"), + "webviewViewMode": obj.get("webviewViewMode") }) # store additional fields in additional_properties for _key in obj.keys(): diff --git a/bandwidth/models/rbm_open_url_enum.py b/bandwidth/models/rbm_open_url_enum.py new file mode 100644 index 00000000..6ccce730 --- /dev/null +++ b/bandwidth/models/rbm_open_url_enum.py @@ -0,0 +1,38 @@ +# 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 RbmOpenUrlEnum(str, Enum): + """ + Specifies how the URL should be opened on a mobile device. - `BROWSER` Opens the URL in the device's default browser. If application is not set or the device doesn’t support WebView, this option is used by default. - `WEBVIEW` Opens the URL in an in-app WebView. + """ + + """ + allowed enum values + """ + BROWSER = 'BROWSER' + WEBVIEW = 'WEBVIEW' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of RbmOpenUrlEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/bandwidth/models/rbm_veb_view_enum.py b/bandwidth/models/rbm_veb_view_enum.py new file mode 100644 index 00000000..88f30073 --- /dev/null +++ b/bandwidth/models/rbm_veb_view_enum.py @@ -0,0 +1,39 @@ +# 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 RbmVebViewEnum(str, Enum): + """ + Defines the layout of the WebView on a mobile device. It must be defined when application is set to `WEBVIEW` - `FULL` WebView takes the full screen. - `HALF` WebView takes half of the screen. - `TALL` WebView takes three-quarters of the screen. + """ + + """ + allowed enum values + """ + FULL = 'FULL' + HALF = 'HALF' + TALL = 'TALL' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of RbmVebViewEnum from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/docs/CallsApi.md b/docs/CallsApi.md index 03ab8819..3d6557eb 100644 --- a/docs/CallsApi.md +++ b/docs/CallsApi.md @@ -25,6 +25,7 @@ All calls are initially queued. Your outbound calls will initiated at a specific ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -50,6 +51,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -82,7 +85,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -117,6 +120,7 @@ Retrieve the current state of a specific call. This information is near-realtime ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -141,6 +145,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -173,7 +179,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -209,6 +215,7 @@ Also, call information is kept for 7 days after the calls are hung up. If you at ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -233,6 +240,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -277,7 +286,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -310,6 +319,7 @@ Interrupts and redirects a call to a different URL that should return a BXML doc ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -334,6 +344,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -366,7 +378,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -400,6 +412,7 @@ Interrupts and replaces an active call's BXML document. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -423,6 +436,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -458,7 +473,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/ConferencesApi.md b/docs/ConferencesApi.md index 2564eedf..080f700e 100644 --- a/docs/ConferencesApi.md +++ b/docs/ConferencesApi.md @@ -25,6 +25,7 @@ Downloads the specified recording file. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -48,6 +49,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -82,7 +85,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -115,6 +118,7 @@ Returns information about the specified conference. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -139,6 +143,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -171,7 +177,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -204,6 +210,7 @@ Returns information about the specified conference member. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -228,6 +235,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -262,7 +271,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -295,6 +304,7 @@ Returns metadata for the specified recording. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -319,6 +329,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -353,7 +365,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -386,6 +398,7 @@ Returns a (potentially empty) list of metadata for the recordings that took plac ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -410,6 +423,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -442,7 +457,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -477,6 +492,7 @@ Returns a max of 1000 conferences, sorted by `createdTime` from oldest to newest ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -501,6 +517,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -541,7 +559,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -574,6 +592,7 @@ Update the conference state. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -598,6 +617,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -630,7 +651,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -663,6 +684,7 @@ Update the conference BXML document. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -686,6 +708,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -721,7 +745,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -754,6 +778,7 @@ Updates settings for a particular conference member. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -778,6 +803,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -812,7 +839,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/MFAApi.md b/docs/MFAApi.md index 3a981154..5f98b05c 100644 --- a/docs/MFAApi.md +++ b/docs/MFAApi.md @@ -19,6 +19,7 @@ Send an MFA code via text message (SMS). ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -44,6 +45,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -76,7 +79,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -105,6 +108,7 @@ Send an MFA Code via a phone call. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -130,6 +134,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -162,7 +168,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -191,6 +197,7 @@ Verify a previously sent MFA code. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -216,6 +223,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -248,7 +257,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/MediaApi.md b/docs/MediaApi.md index bd3a8bd6..48af4d9d 100644 --- a/docs/MediaApi.md +++ b/docs/MediaApi.md @@ -24,6 +24,7 @@ file with the same name. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -47,6 +48,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -77,7 +80,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -110,6 +113,7 @@ Downloads a media file you previously uploaded. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -133,6 +137,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -165,7 +171,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -198,6 +204,7 @@ Gets a list of your media files. No query parameters are supported. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -222,6 +229,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -254,7 +263,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -291,6 +300,7 @@ A list of supported media types can be found [here](https://support.bandwidth.co ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -314,6 +324,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -350,7 +362,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/MessagesApi.md b/docs/MessagesApi.md index cab2fc2e..3dfbd316 100644 --- a/docs/MessagesApi.md +++ b/docs/MessagesApi.md @@ -18,6 +18,7 @@ Endpoint for sending text messages and picture messages using V2 messaging. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -43,6 +44,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -75,7 +78,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -109,6 +112,7 @@ Returns a list of messages based on query parameters. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -137,6 +141,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -221,7 +227,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/MultiChannelAction.md b/docs/MultiChannelAction.md index 580c7470..fe5a493b 100644 --- a/docs/MultiChannelAction.md +++ b/docs/MultiChannelAction.md @@ -17,6 +17,8 @@ Name | Type | Description | Notes **end_time** | **datetime** | The end time of the event. | **description** | **str** | The description of the event. | [optional] **url** | **str** | The URL to open in browser. | +**application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] +**webview_view_mode** | [**RbmVebViewEnum**](RbmVebViewEnum.md) | | [optional] ## Example diff --git a/docs/MultiChannelApi.md b/docs/MultiChannelApi.md index 0d7713b1..de220ceb 100644 --- a/docs/MultiChannelApi.md +++ b/docs/MultiChannelApi.md @@ -17,6 +17,7 @@ Endpoint for sending Multi-Channel messages. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -42,6 +43,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -74,7 +77,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/PhoneNumberLookupApi.md b/docs/PhoneNumberLookupApi.md index da1fe651..aa366aa5 100644 --- a/docs/PhoneNumberLookupApi.md +++ b/docs/PhoneNumberLookupApi.md @@ -19,6 +19,7 @@ Creates an asynchronous bulk phone number lookup request. Maximum of 15,000 tele ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -44,6 +45,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -76,7 +79,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -102,6 +105,7 @@ Creates a synchronous phone number lookup request. Maximum of 100 telephone numb ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -127,6 +131,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -159,7 +165,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -185,6 +191,7 @@ Get an existing [Asynchronous Bulk Number Lookup](#tag/Phone-Number-Lookup/opera ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -209,6 +216,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -241,7 +250,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/RbmActionOpenUrl.md b/docs/RbmActionOpenUrl.md index 8f864050..7001cc68 100644 --- a/docs/RbmActionOpenUrl.md +++ b/docs/RbmActionOpenUrl.md @@ -9,6 +9,8 @@ Name | Type | Description | Notes **text** | **str** | Displayed text for user to click | **postback_data** | **bytearray** | Base64 payload the customer receives when the reply is clicked. | **url** | **str** | The URL to open in browser. | +**application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] +**webview_view_mode** | [**RbmVebViewEnum**](RbmVebViewEnum.md) | | [optional] ## Example diff --git a/docs/RbmOpenUrlEnum.md b/docs/RbmOpenUrlEnum.md new file mode 100644 index 00000000..19bac259 --- /dev/null +++ b/docs/RbmOpenUrlEnum.md @@ -0,0 +1,13 @@ +# RbmOpenUrlEnum + +Specifies how the URL should be opened on a mobile device. - `BROWSER` Opens the URL in the device's default browser. If application is not set or the device doesn’t support WebView, this option is used by default. - `WEBVIEW` Opens the URL in an in-app WebView. + +## Enum + +* `BROWSER` (value: `'BROWSER'`) + +* `WEBVIEW` (value: `'WEBVIEW'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RbmVebViewEnum.md b/docs/RbmVebViewEnum.md new file mode 100644 index 00000000..49503ff4 --- /dev/null +++ b/docs/RbmVebViewEnum.md @@ -0,0 +1,15 @@ +# RbmVebViewEnum + +Defines the layout of the WebView on a mobile device. It must be defined when application is set to `WEBVIEW` - `FULL` WebView takes the full screen. - `HALF` WebView takes half of the screen. - `TALL` WebView takes three-quarters of the screen. + +## Enum + +* `FULL` (value: `'FULL'`) + +* `HALF` (value: `'HALF'`) + +* `TALL` (value: `'TALL'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/RecordingsApi.md b/docs/RecordingsApi.md index e461ef87..48511eba 100644 --- a/docs/RecordingsApi.md +++ b/docs/RecordingsApi.md @@ -28,6 +28,7 @@ Note: After the deletion is requested and a `204` is returned, neither the recor ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -51,6 +52,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -83,7 +86,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -116,6 +119,7 @@ Deletes the specified recording's media. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -139,6 +143,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -171,7 +177,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -206,6 +212,7 @@ Note: After the deletion is requested and a `204` is returned, the transcription ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -229,6 +236,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -261,7 +270,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -294,6 +303,7 @@ Downloads the specified recording. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -317,6 +327,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -351,7 +363,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -384,6 +396,7 @@ Returns metadata for the specified recording. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -408,6 +421,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -442,7 +457,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -478,6 +493,7 @@ During a [``](/docs/voice/bxml/transfer) the A-leg transcript will be ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -502,6 +518,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -536,7 +554,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -572,6 +590,7 @@ empty if no recordings match the specified criteria. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -596,6 +615,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -634,7 +655,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -668,6 +689,7 @@ that took place during the specified call. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -692,6 +714,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -724,7 +748,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -759,6 +783,7 @@ less than 4 hours. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -783,6 +808,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -817,7 +844,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -850,6 +877,7 @@ Pause or resume a recording on an active phone call. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -874,6 +902,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -906,7 +936,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/StatisticsApi.md b/docs/StatisticsApi.md index 3df9571f..3b4d9fe2 100644 --- a/docs/StatisticsApi.md +++ b/docs/StatisticsApi.md @@ -17,6 +17,7 @@ Returns details about the current state of the account. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -41,6 +42,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -71,7 +74,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/TollFreeVerificationApi.md b/docs/TollFreeVerificationApi.md index d5995ce1..c5ea2e03 100644 --- a/docs/TollFreeVerificationApi.md +++ b/docs/TollFreeVerificationApi.md @@ -27,6 +27,7 @@ The returned subscription object will contain an ID that can be used to modify o ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -52,6 +53,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -84,7 +87,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -117,6 +120,7 @@ Delete a toll-free verification submission for a toll-free number. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -140,6 +144,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -170,7 +176,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -203,6 +209,7 @@ Delete a webhook subscription by ID. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -226,6 +233,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -256,7 +265,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -290,6 +299,7 @@ Submission information will be appended to the response if it is available. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -314,6 +324,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -346,7 +358,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -379,6 +391,7 @@ Lists valid toll-free use cases. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -402,6 +415,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -428,7 +443,7 @@ This endpoint does not need any parameter. ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -462,6 +477,7 @@ If `basicAuthentication` is defined, the `password` property of that object will ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -486,6 +502,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -516,7 +534,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -548,6 +566,7 @@ Submit a request for verification of a toll-free phone number. ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -572,6 +591,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -602,7 +623,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -635,6 +656,7 @@ Submissions are only eligible for resubmission for 7 days within being processed ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -659,6 +681,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -691,7 +715,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -723,6 +747,7 @@ Update an existing webhook subscription (`callbackUrl` and `basicAuthentication` ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -748,6 +773,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -782,7 +809,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers diff --git a/docs/TranscriptionsApi.md b/docs/TranscriptionsApi.md index 2a8b05f2..a0d445ac 100644 --- a/docs/TranscriptionsApi.md +++ b/docs/TranscriptionsApi.md @@ -21,6 +21,7 @@ Note: After the deletion is requested and a `200` is returned, the transcription ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -44,6 +45,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -76,7 +79,7 @@ void (empty response body) ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -109,6 +112,7 @@ Retrieve the specified transcription that was created on this call via [startTra ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -133,6 +137,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -167,7 +173,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers @@ -200,6 +206,7 @@ List the transcriptions created on this call via [startTranscription](/docs/voic ### Example * Basic Authentication (Basic): +* OAuth Authentication (OAuth2): ```python import bandwidth @@ -224,6 +231,8 @@ configuration = bandwidth.Configuration( password = os.environ["PASSWORD"] ) +configuration.access_token = os.environ["ACCESS_TOKEN"] + # Enter a context with an instance of the API client with bandwidth.ApiClient(configuration) as api_client: # Create an instance of the API class @@ -256,7 +265,7 @@ Name | Type | Description | Notes ### Authorization -[Basic](../README.md#Basic) +[Basic](../README.md#Basic), [OAuth2](../README.md#OAuth2) ### HTTP request headers From 23ec039d8bd5e24e896736b52d8c2257f9dd80b4 Mon Sep 17 00:00:00 2001 From: ckoegel Date: Tue, 9 Dec 2025 17:26:58 -0500 Subject: [PATCH 2/3] unit tests --- test/unit/models/test_rbm_action_open_url.py | 11 ++++-- test/unit/models/test_rbm_open_url_enum.py | 35 +++++++++++++++++++ test/unit/models/test_rbm_veb_view_enum.py | 36 ++++++++++++++++++++ 3 files changed, 80 insertions(+), 2 deletions(-) create mode 100644 test/unit/models/test_rbm_open_url_enum.py create mode 100644 test/unit/models/test_rbm_veb_view_enum.py diff --git a/test/unit/models/test_rbm_action_open_url.py b/test/unit/models/test_rbm_action_open_url.py index 9e27c51f..349931a9 100644 --- a/test/unit/models/test_rbm_action_open_url.py +++ b/test/unit/models/test_rbm_action_open_url.py @@ -16,6 +16,9 @@ import unittest from bandwidth.models.rbm_action_open_url import RbmActionOpenUrl +from bandwidth.models.rbm_action_type_enum import RbmActionTypeEnum +from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum +from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum class TestRbmActionOpenUrl(unittest.TestCase): """RbmActionOpenUrl unit test stubs""" @@ -33,10 +36,12 @@ def make_instance(self, include_optional) -> RbmActionOpenUrl: optional params are included """ if include_optional: return RbmActionOpenUrl( - type = 'REPLY', + type = RbmActionTypeEnum.REPLY, text = 'Hello world', postback_data = 'U0dWc2JHOGdkMjl5YkdRPQ==', - url = 'https://dev.bandwidth.com' + url = 'https://dev.bandwidth.com', + application=RbmOpenUrlEnum.BROWSER, + webview_view_mode=RbmVebViewEnum.FULL, ) else: return RbmActionOpenUrl( @@ -55,6 +60,8 @@ def testRbmActionOpenUrl(self): assert instance.text == 'Hello world' assert instance.postback_data == 'U0dWc2JHOGdkMjl5YkdRPQ==' assert instance.url == 'https://dev.bandwidth.com' + assert instance.application == 'BROWSER' + assert instance.webview_view_mode == 'FULL' if __name__ == '__main__': unittest.main() diff --git a/test/unit/models/test_rbm_open_url_enum.py b/test/unit/models/test_rbm_open_url_enum.py new file mode 100644 index 00000000..4a5d8188 --- /dev/null +++ b/test/unit/models/test_rbm_open_url_enum.py @@ -0,0 +1,35 @@ +# 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 + + +import unittest + +from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum + +class TestRbmOpenUrlEnum(unittest.TestCase): + """RbmOpenUrlEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRbmOpenUrlEnum(self): + """Test RbmOpenUrlEnum""" + assert RbmOpenUrlEnum('BROWSER') == 'BROWSER' + assert RbmOpenUrlEnum('WEBVIEW') == 'WEBVIEW' + +if __name__ == '__main__': + unittest.main() diff --git a/test/unit/models/test_rbm_veb_view_enum.py b/test/unit/models/test_rbm_veb_view_enum.py new file mode 100644 index 00000000..e8fbc542 --- /dev/null +++ b/test/unit/models/test_rbm_veb_view_enum.py @@ -0,0 +1,36 @@ +# 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 + + +import unittest + +from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum + +class TestRbmVebViewEnum(unittest.TestCase): + """RbmVebViewEnum unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testRbmVebViewEnum(self): + """Test RbmVebViewEnum""" + assert RbmVebViewEnum('FULL') == 'FULL' + assert RbmVebViewEnum('HALF') == 'HALF' + assert RbmVebViewEnum('TALL') == 'TALL' + +if __name__ == '__main__': + unittest.main() From 4543fc14228697ffd6d5035af54e37fc141d60af Mon Sep 17 00:00:00 2001 From: ckoegel Date: Tue, 9 Dec 2025 17:46:55 -0500 Subject: [PATCH 3/3] rename for typo --- .openapi-generator/FILES | 4 ++-- README.md | 2 +- bandwidth.yml | 5 ++--- bandwidth/__init__.py | 4 ++-- bandwidth/models/__init__.py | 2 +- bandwidth/models/rbm_action_open_url.py | 4 ++-- ...rbm_veb_view_enum.py => rbm_web_view_enum.py} | 4 ++-- custom_templates/configuration.mustache | 1 - docs/MultiChannelAction.md | 2 +- docs/RbmActionOpenUrl.md | 2 +- docs/{RbmVebViewEnum.md => RbmWebViewEnum.md} | 2 +- test/unit/models/test_rbm_action_open_url.py | 4 ++-- ...eb_view_enum.py => test_rbm_web_view_enum.py} | 16 ++++++++-------- 13 files changed, 25 insertions(+), 27 deletions(-) rename bandwidth/models/{rbm_veb_view_enum.py => rbm_web_view_enum.py} (89%) rename docs/{RbmVebViewEnum.md => RbmWebViewEnum.md} (96%) rename test/unit/models/{test_rbm_veb_view_enum.py => test_rbm_web_view_enum.py} (53%) diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 1fa2389b..1380f48c 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -148,7 +148,7 @@ bandwidth/models/rbm_message_media.py bandwidth/models/rbm_open_url_enum.py bandwidth/models/rbm_standalone_card.py bandwidth/models/rbm_suggestion_response.py -bandwidth/models/rbm_veb_view_enum.py +bandwidth/models/rbm_web_view_enum.py bandwidth/models/recording_available_callback.py bandwidth/models/recording_complete_callback.py bandwidth/models/recording_state_enum.py @@ -333,7 +333,7 @@ docs/RbmMessageMedia.md docs/RbmOpenUrlEnum.md docs/RbmStandaloneCard.md docs/RbmSuggestionResponse.md -docs/RbmVebViewEnum.md +docs/RbmWebViewEnum.md docs/RecordingAvailableCallback.md docs/RecordingCompleteCallback.md docs/RecordingStateEnum.md diff --git a/README.md b/README.md index aa958864..1a9d687d 100644 --- a/README.md +++ b/README.md @@ -286,7 +286,7 @@ Class | Method | HTTP request | Description - [RbmOpenUrlEnum](docs/RbmOpenUrlEnum.md) - [RbmStandaloneCard](docs/RbmStandaloneCard.md) - [RbmSuggestionResponse](docs/RbmSuggestionResponse.md) - - [RbmVebViewEnum](docs/RbmVebViewEnum.md) + - [RbmWebViewEnum](docs/RbmWebViewEnum.md) - [RecordingAvailableCallback](docs/RecordingAvailableCallback.md) - [RecordingCompleteCallback](docs/RecordingCompleteCallback.md) - [RecordingStateEnum](docs/RecordingStateEnum.md) diff --git a/bandwidth.yml b/bandwidth.yml index 4683e066..d7c32953 100644 --- a/bandwidth.yml +++ b/bandwidth.yml @@ -8,7 +8,6 @@ info: email: letstalk@bandwidth.com version: 1.0.0 security: - - OAuth2: [] - Basic: [] - OAuth2: [] tags: @@ -2393,7 +2392,7 @@ components: - BROWSER - WEBVIEW example: WEBVIEW - rbmVebViewEnum: + rbmWebViewEnum: type: string description: >- Defines the layout of the WebView on a mobile device. It must be defined @@ -2515,7 +2514,7 @@ components: application: $ref: '#/components/schemas/rbmOpenUrlEnum' webviewViewMode: - $ref: '#/components/schemas/rbmVebViewEnum' + $ref: '#/components/schemas/rbmWebViewEnum' required: - url multiChannelFullActions: diff --git a/bandwidth/__init__.py b/bandwidth/__init__.py index fd80976c..5d5b6304 100644 --- a/bandwidth/__init__.py +++ b/bandwidth/__init__.py @@ -168,7 +168,7 @@ "RbmOpenUrlEnum", "RbmStandaloneCard", "RbmSuggestionResponse", - "RbmVebViewEnum", + "RbmWebViewEnum", "RecordingAvailableCallback", "RecordingCompleteCallback", "RecordingStateEnum", @@ -371,7 +371,7 @@ from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum as RbmOpenUrlEnum from bandwidth.models.rbm_standalone_card import RbmStandaloneCard as RbmStandaloneCard from bandwidth.models.rbm_suggestion_response import RbmSuggestionResponse as RbmSuggestionResponse -from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum as RbmVebViewEnum +from bandwidth.models.rbm_web_view_enum import RbmWebViewEnum as RbmWebViewEnum from bandwidth.models.recording_available_callback import RecordingAvailableCallback as RecordingAvailableCallback from bandwidth.models.recording_complete_callback import RecordingCompleteCallback as RecordingCompleteCallback from bandwidth.models.recording_state_enum import RecordingStateEnum as RecordingStateEnum diff --git a/bandwidth/models/__init__.py b/bandwidth/models/__init__.py index ced5ba2f..58a7cc68 100644 --- a/bandwidth/models/__init__.py +++ b/bandwidth/models/__init__.py @@ -143,7 +143,7 @@ from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum from bandwidth.models.rbm_standalone_card import RbmStandaloneCard from bandwidth.models.rbm_suggestion_response import RbmSuggestionResponse -from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum +from bandwidth.models.rbm_web_view_enum import RbmWebViewEnum from bandwidth.models.recording_available_callback import RecordingAvailableCallback from bandwidth.models.recording_complete_callback import RecordingCompleteCallback from bandwidth.models.recording_state_enum import RecordingStateEnum diff --git a/bandwidth/models/rbm_action_open_url.py b/bandwidth/models/rbm_action_open_url.py index d7a5f06b..ec6dca2a 100644 --- a/bandwidth/models/rbm_action_open_url.py +++ b/bandwidth/models/rbm_action_open_url.py @@ -23,7 +23,7 @@ from typing_extensions import Annotated from bandwidth.models.rbm_action_type_enum import RbmActionTypeEnum from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum -from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum +from bandwidth.models.rbm_web_view_enum import RbmWebViewEnum from typing import Optional, Set from typing_extensions import Self @@ -36,7 +36,7 @@ class RbmActionOpenUrl(BaseModel): postback_data: Union[Annotated[bytes, Field(strict=True, max_length=2048)], Annotated[str, Field(strict=True, max_length=2048)]] = Field(description="Base64 payload the customer receives when the reply is clicked.", alias="postbackData") url: Annotated[str, Field(strict=True, max_length=2048)] = Field(description="The URL to open in browser.") application: Optional[RbmOpenUrlEnum] = None - webview_view_mode: Optional[RbmVebViewEnum] = Field(default=None, alias="webviewViewMode") + webview_view_mode: Optional[RbmWebViewEnum] = Field(default=None, alias="webviewViewMode") additional_properties: Dict[str, Any] = {} __properties: ClassVar[List[str]] = ["type", "text", "postbackData", "url", "application", "webviewViewMode"] diff --git a/bandwidth/models/rbm_veb_view_enum.py b/bandwidth/models/rbm_web_view_enum.py similarity index 89% rename from bandwidth/models/rbm_veb_view_enum.py rename to bandwidth/models/rbm_web_view_enum.py index 88f30073..1ebbd851 100644 --- a/bandwidth/models/rbm_veb_view_enum.py +++ b/bandwidth/models/rbm_web_view_enum.py @@ -19,7 +19,7 @@ from typing_extensions import Self -class RbmVebViewEnum(str, Enum): +class RbmWebViewEnum(str, Enum): """ Defines the layout of the WebView on a mobile device. It must be defined when application is set to `WEBVIEW` - `FULL` WebView takes the full screen. - `HALF` WebView takes half of the screen. - `TALL` WebView takes three-quarters of the screen. """ @@ -33,7 +33,7 @@ class RbmVebViewEnum(str, Enum): @classmethod def from_json(cls, json_str: str) -> Self: - """Create an instance of RbmVebViewEnum from a JSON string""" + """Create an instance of RbmWebViewEnum from a JSON string""" return cls(json.loads(json_str)) diff --git a/custom_templates/configuration.mustache b/custom_templates/configuration.mustache index 137adb93..dd059307 100644 --- a/custom_templates/configuration.mustache +++ b/custom_templates/configuration.mustache @@ -646,7 +646,6 @@ conf = {{{packageName}}}.Configuration( if self.temp_access_token and self.temp_access_token_expiration > now + 60: return self.temp_access_token else: - print("Fetching new access token") _bytes = f"{self.client_id}:{self.client_secret}".encode('utf-8') _encoded_string = base64.b64encode(_bytes).decode('utf-8') auth_header = f"Basic {_encoded_string}" diff --git a/docs/MultiChannelAction.md b/docs/MultiChannelAction.md index fe5a493b..1f08cadf 100644 --- a/docs/MultiChannelAction.md +++ b/docs/MultiChannelAction.md @@ -18,7 +18,7 @@ Name | Type | Description | Notes **description** | **str** | The description of the event. | [optional] **url** | **str** | The URL to open in browser. | **application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] -**webview_view_mode** | [**RbmVebViewEnum**](RbmVebViewEnum.md) | | [optional] +**webview_view_mode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] ## Example diff --git a/docs/RbmActionOpenUrl.md b/docs/RbmActionOpenUrl.md index 7001cc68..d42aa2b3 100644 --- a/docs/RbmActionOpenUrl.md +++ b/docs/RbmActionOpenUrl.md @@ -10,7 +10,7 @@ Name | Type | Description | Notes **postback_data** | **bytearray** | Base64 payload the customer receives when the reply is clicked. | **url** | **str** | The URL to open in browser. | **application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] -**webview_view_mode** | [**RbmVebViewEnum**](RbmVebViewEnum.md) | | [optional] +**webview_view_mode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] ## Example diff --git a/docs/RbmVebViewEnum.md b/docs/RbmWebViewEnum.md similarity index 96% rename from docs/RbmVebViewEnum.md rename to docs/RbmWebViewEnum.md index 49503ff4..a7753830 100644 --- a/docs/RbmVebViewEnum.md +++ b/docs/RbmWebViewEnum.md @@ -1,4 +1,4 @@ -# RbmVebViewEnum +# RbmWebViewEnum Defines the layout of the WebView on a mobile device. It must be defined when application is set to `WEBVIEW` - `FULL` WebView takes the full screen. - `HALF` WebView takes half of the screen. - `TALL` WebView takes three-quarters of the screen. diff --git a/test/unit/models/test_rbm_action_open_url.py b/test/unit/models/test_rbm_action_open_url.py index 349931a9..c9350838 100644 --- a/test/unit/models/test_rbm_action_open_url.py +++ b/test/unit/models/test_rbm_action_open_url.py @@ -18,7 +18,7 @@ from bandwidth.models.rbm_action_open_url import RbmActionOpenUrl from bandwidth.models.rbm_action_type_enum import RbmActionTypeEnum from bandwidth.models.rbm_open_url_enum import RbmOpenUrlEnum -from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum +from bandwidth.models.rbm_web_view_enum import RbmWebViewEnum class TestRbmActionOpenUrl(unittest.TestCase): """RbmActionOpenUrl unit test stubs""" @@ -41,7 +41,7 @@ def make_instance(self, include_optional) -> RbmActionOpenUrl: postback_data = 'U0dWc2JHOGdkMjl5YkdRPQ==', url = 'https://dev.bandwidth.com', application=RbmOpenUrlEnum.BROWSER, - webview_view_mode=RbmVebViewEnum.FULL, + webview_view_mode=RbmWebViewEnum.FULL, ) else: return RbmActionOpenUrl( diff --git a/test/unit/models/test_rbm_veb_view_enum.py b/test/unit/models/test_rbm_web_view_enum.py similarity index 53% rename from test/unit/models/test_rbm_veb_view_enum.py rename to test/unit/models/test_rbm_web_view_enum.py index e8fbc542..1a900429 100644 --- a/test/unit/models/test_rbm_veb_view_enum.py +++ b/test/unit/models/test_rbm_web_view_enum.py @@ -15,10 +15,10 @@ import unittest -from bandwidth.models.rbm_veb_view_enum import RbmVebViewEnum +from bandwidth.models.rbm_web_view_enum import RbmWebViewEnum -class TestRbmVebViewEnum(unittest.TestCase): - """RbmVebViewEnum unit test stubs""" +class TestRbmWebViewEnum(unittest.TestCase): + """RbmWebViewEnum unit test stubs""" def setUp(self): pass @@ -26,11 +26,11 @@ def setUp(self): def tearDown(self): pass - def testRbmVebViewEnum(self): - """Test RbmVebViewEnum""" - assert RbmVebViewEnum('FULL') == 'FULL' - assert RbmVebViewEnum('HALF') == 'HALF' - assert RbmVebViewEnum('TALL') == 'TALL' + def testRbmWebViewEnum(self): + """Test RbmWebViewEnum""" + assert RbmWebViewEnum('FULL') == 'FULL' + assert RbmWebViewEnum('HALF') == 'HALF' + assert RbmWebViewEnum('TALL') == 'TALL' if __name__ == '__main__': unittest.main()