diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 301d629..665ecea 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -148,8 +148,10 @@ docs/RbmMessageContentFile.md docs/RbmMessageContentRichCard.md docs/RbmMessageContentText.md docs/RbmMessageMedia.md +docs/RbmOpenUrlEnum.md docs/RbmStandaloneCard.md docs/RbmSuggestionResponse.md +docs/RbmWebViewEnum.md docs/RecordingAvailableCallback.md docs/RecordingCompleteCallback.md docs/RecordingStateEnum.md @@ -329,8 +331,10 @@ models/rbm-message-content-file.ts models/rbm-message-content-rich-card.ts models/rbm-message-content-text.ts models/rbm-message-media.ts +models/rbm-open-url-enum.ts models/rbm-standalone-card.ts models/rbm-suggestion-response.ts +models/rbm-web-view-enum.ts models/recording-available-callback.ts models/recording-complete-callback.ts models/recording-state-enum.ts diff --git a/README.md b/README.md index 578938a..1f44d1e 100644 --- a/README.md +++ b/README.md @@ -286,8 +286,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) + - [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 9ab77fd..d7c3295 100644 --- a/bandwidth.yml +++ b/bandwidth.yml @@ -2378,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 + rbmWebViewEnum: + 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 @@ -2482,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/rbmWebViewEnum' required: - url multiChannelFullActions: diff --git a/docs/MultiChannelAction.md b/docs/MultiChannelAction.md index 605d4a7..2c7e5ad 100644 --- a/docs/MultiChannelAction.md +++ b/docs/MultiChannelAction.md @@ -17,6 +17,8 @@ Name | Type | Description | Notes **endTime** | **string** | The end time of the event. | [default to undefined] **description** | **string** | The description of the event. | [optional] [default to undefined] **url** | **string** | The URL to open in browser. | [default to undefined] +**application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] [default to undefined] +**webviewViewMode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] [default to undefined] ## Example @@ -36,6 +38,8 @@ const instance: MultiChannelAction = { endTime, description, url, + application, + webviewViewMode, }; ``` diff --git a/docs/RbmActionOpenUrl.md b/docs/RbmActionOpenUrl.md index cfa71d9..0e36fcd 100644 --- a/docs/RbmActionOpenUrl.md +++ b/docs/RbmActionOpenUrl.md @@ -9,6 +9,8 @@ Name | Type | Description | Notes **text** | **string** | Displayed text for user to click | [default to undefined] **postbackData** | **string** | Base64 payload the customer receives when the reply is clicked. | [default to undefined] **url** | **string** | The URL to open in browser. | [default to undefined] +**application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] [default to undefined] +**webviewViewMode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] [default to undefined] ## Example @@ -20,6 +22,8 @@ const instance: RbmActionOpenUrl = { text, postbackData, url, + application, + webviewViewMode, }; ``` diff --git a/docs/RbmOpenUrlEnum.md b/docs/RbmOpenUrlEnum.md new file mode 100644 index 0000000..0ceb3e0 --- /dev/null +++ b/docs/RbmOpenUrlEnum.md @@ -0,0 +1,11 @@ +# 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/RbmWebViewEnum.md b/docs/RbmWebViewEnum.md new file mode 100644 index 0000000..c713add --- /dev/null +++ b/docs/RbmWebViewEnum.md @@ -0,0 +1,13 @@ +# 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. + +## 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/models/index.ts b/models/index.ts index 8c78bf5..7900f52 100644 --- a/models/index.ts +++ b/models/index.ts @@ -124,8 +124,10 @@ export * from './rbm-message-content-file'; export * from './rbm-message-content-rich-card'; export * from './rbm-message-content-text'; export * from './rbm-message-media'; +export * from './rbm-open-url-enum'; export * from './rbm-standalone-card'; export * from './rbm-suggestion-response'; +export * from './rbm-web-view-enum'; export * from './recording-available-callback'; export * from './recording-complete-callback'; export * from './recording-state-enum'; diff --git a/models/multi-channel-action.ts b/models/multi-channel-action.ts index 8d26e51..62c5045 100644 --- a/models/multi-channel-action.ts +++ b/models/multi-channel-action.ts @@ -31,6 +31,12 @@ import type { RbmActionTypeEnum } from './rbm-action-type-enum'; // May contain unused imports in some cases // @ts-ignore import type { RbmActionViewLocation } from './rbm-action-view-location'; +// May contain unused imports in some cases +// @ts-ignore +import type { RbmOpenUrlEnum } from './rbm-open-url-enum'; +// May contain unused imports in some cases +// @ts-ignore +import type { RbmWebViewEnum } from './rbm-web-view-enum'; export interface MultiChannelAction { 'type': RbmActionTypeEnum; @@ -78,6 +84,8 @@ export interface MultiChannelAction { * The URL to open in browser. */ 'url': string; + 'application'?: RbmOpenUrlEnum; + 'webviewViewMode'?: RbmWebViewEnum; } diff --git a/models/rbm-action-open-url.ts b/models/rbm-action-open-url.ts index 627df50..26eb979 100644 --- a/models/rbm-action-open-url.ts +++ b/models/rbm-action-open-url.ts @@ -19,6 +19,12 @@ import type { RbmActionBase } from './rbm-action-base'; // May contain unused imports in some cases // @ts-ignore import type { RbmActionTypeEnum } from './rbm-action-type-enum'; +// May contain unused imports in some cases +// @ts-ignore +import type { RbmOpenUrlEnum } from './rbm-open-url-enum'; +// May contain unused imports in some cases +// @ts-ignore +import type { RbmWebViewEnum } from './rbm-web-view-enum'; /** * @type RbmActionOpenUrl diff --git a/models/rbm-open-url-enum.ts b/models/rbm-open-url-enum.ts new file mode 100644 index 0000000..f45ae64 --- /dev/null +++ b/models/rbm-open-url-enum.ts @@ -0,0 +1,29 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Bandwidth + * Bandwidth\'s Communication APIs + * + * The version of the OpenAPI document: 1.0.0 + * Contact: letstalk@bandwidth.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * 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. + */ + +export const RbmOpenUrlEnum = { + Browser: 'BROWSER', + Webview: 'WEBVIEW' +} as const; + +export type RbmOpenUrlEnum = typeof RbmOpenUrlEnum[keyof typeof RbmOpenUrlEnum]; + + + diff --git a/models/rbm-web-view-enum.ts b/models/rbm-web-view-enum.ts new file mode 100644 index 0000000..3d7e67a --- /dev/null +++ b/models/rbm-web-view-enum.ts @@ -0,0 +1,30 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Bandwidth + * Bandwidth\'s Communication APIs + * + * The version of the OpenAPI document: 1.0.0 + * Contact: letstalk@bandwidth.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + + +/** + * 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. + */ + +export const RbmWebViewEnum = { + Full: 'FULL', + Half: 'HALF', + Tall: 'TALL' +} as const; + +export type RbmWebViewEnum = typeof RbmWebViewEnum[keyof typeof RbmWebViewEnum]; + + + diff --git a/tests/unit/models/rbm-open-url-enum.test.ts b/tests/unit/models/rbm-open-url-enum.test.ts new file mode 100644 index 0000000..2ba1209 --- /dev/null +++ b/tests/unit/models/rbm-open-url-enum.test.ts @@ -0,0 +1,8 @@ +import { RbmOpenUrlEnum } from '../../../models/rbm-open-url-enum'; + +describe('RbmOpenUrlEnum', () => { + test('should define the expected values', () => { + expect(RbmOpenUrlEnum.Browser).toBe('BROWSER'); + expect(RbmOpenUrlEnum.Webview).toBe('WEBVIEW'); + }); +}); diff --git a/tests/unit/models/rbm-veb-view-enum.test.ts b/tests/unit/models/rbm-veb-view-enum.test.ts new file mode 100644 index 0000000..a4019b6 --- /dev/null +++ b/tests/unit/models/rbm-veb-view-enum.test.ts @@ -0,0 +1,9 @@ +import { RbmWebViewEnum } from '../../../models/rbm-web-view-enum'; + +describe('RbmWebViewEnum', () => { + test('should define the expected values', () => { + expect(RbmWebViewEnum.Full).toBe('FULL'); + expect(RbmWebViewEnum.Half).toBe('HALF'); + expect(RbmWebViewEnum.Tall).toBe('TALL'); + }); +});