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
4 changes: 4 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,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
Expand Down Expand Up @@ -332,8 +334,10 @@ lib/bandwidth-sdk/models/rbm_message_content_file.rb
lib/bandwidth-sdk/models/rbm_message_content_rich_card.rb
lib/bandwidth-sdk/models/rbm_message_content_text.rb
lib/bandwidth-sdk/models/rbm_message_media.rb
lib/bandwidth-sdk/models/rbm_open_url_enum.rb
lib/bandwidth-sdk/models/rbm_standalone_card.rb
lib/bandwidth-sdk/models/rbm_suggestion_response.rb
lib/bandwidth-sdk/models/rbm_web_view_enum.rb
lib/bandwidth-sdk/models/recording_available_callback.rb
lib/bandwidth-sdk/models/recording_complete_callback.rb
lib/bandwidth-sdk/models/recording_state_enum.rb
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,10 @@ Class | Method | HTTP request | Description
- [Bandwidth::RbmMessageContentRichCard](docs/RbmMessageContentRichCard.md)
- [Bandwidth::RbmMessageContentText](docs/RbmMessageContentText.md)
- [Bandwidth::RbmMessageMedia](docs/RbmMessageMedia.md)
- [Bandwidth::RbmOpenUrlEnum](docs/RbmOpenUrlEnum.md)
- [Bandwidth::RbmStandaloneCard](docs/RbmStandaloneCard.md)
- [Bandwidth::RbmSuggestionResponse](docs/RbmSuggestionResponse.md)
- [Bandwidth::RbmWebViewEnum](docs/RbmWebViewEnum.md)
- [Bandwidth::RecordingAvailableCallback](docs/RecordingAvailableCallback.md)
- [Bandwidth::RecordingCompleteCallback](docs/RecordingCompleteCallback.md)
- [Bandwidth::RecordingStateEnum](docs/RecordingStateEnum.md)
Expand Down
33 changes: 33 additions & 0 deletions bandwidth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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:
Expand Down
6 changes: 5 additions & 1 deletion docs/MultiChannelAction.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
| **end_time** | **Time** | The end time of the event. | |
| **description** | **String** | The description of the event. | [optional] |
| **url** | **String** | The URL to open in browser. | |
| **application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] |
| **webview_view_mode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] |

## Example

Expand All @@ -34,7 +36,9 @@ instance = Bandwidth::MultiChannelAction.new(
start_time: 2022-09-14T18:20:16Z,
end_time: 2022-09-14T18:20:16Z,
description: Discuss the new project,
url: https://dev.bandwidth.com
url: https://dev.bandwidth.com,
application: null,
webview_view_mode: null
)
```

2 changes: 1 addition & 1 deletion docs/RbmActionBase.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ require 'bandwidth-sdk'
instance = Bandwidth::RbmActionBase.new(
type: null,
text: Hello world,
postback_data: [B@7d5d77a6
postback_data: [B@13866865
)
```

6 changes: 5 additions & 1 deletion docs/RbmActionOpenUrl.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
| **text** | **String** | Displayed text for user to click | |
| **postback_data** | **String** | Base64 payload the customer receives when the reply is clicked. | |
| **url** | **String** | The URL to open in browser. | |
| **application** | [**RbmOpenUrlEnum**](RbmOpenUrlEnum.md) | | [optional] |
| **webview_view_mode** | [**RbmWebViewEnum**](RbmWebViewEnum.md) | | [optional] |

## Example

Expand All @@ -18,7 +20,9 @@ instance = Bandwidth::RbmActionOpenUrl.new(
type: null,
text: Hello world,
postback_data: U0dWc2JHOGdkMjl5YkdRPQ==,
url: https://dev.bandwidth.com
url: https://dev.bandwidth.com,
application: null,
webview_view_mode: null
)
```

15 changes: 15 additions & 0 deletions docs/RbmOpenUrlEnum.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Bandwidth::RbmOpenUrlEnum

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |

## Example

```ruby
require 'bandwidth-sdk'

instance = Bandwidth::RbmOpenUrlEnum.new()
```

2 changes: 1 addition & 1 deletion docs/RbmSuggestionResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ require 'bandwidth-sdk'

instance = Bandwidth::RbmSuggestionResponse.new(
text: Yes, I would like to proceed,
postback_data: [B@7d5d77a6
postback_data: [B@13866865
)
```

15 changes: 15 additions & 0 deletions docs/RbmWebViewEnum.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Bandwidth::RbmWebViewEnum

## Properties

| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |

## Example

```ruby
require 'bandwidth-sdk'

instance = Bandwidth::RbmWebViewEnum.new()
```

2 changes: 2 additions & 0 deletions lib/bandwidth-sdk.rb
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,10 @@
require 'bandwidth-sdk/models/rbm_message_content_rich_card'
require 'bandwidth-sdk/models/rbm_message_content_text'
require 'bandwidth-sdk/models/rbm_message_media'
require 'bandwidth-sdk/models/rbm_open_url_enum'
require 'bandwidth-sdk/models/rbm_standalone_card'
require 'bandwidth-sdk/models/rbm_suggestion_response'
require 'bandwidth-sdk/models/rbm_web_view_enum'
require 'bandwidth-sdk/models/recording_available_callback'
require 'bandwidth-sdk/models/recording_complete_callback'
require 'bandwidth-sdk/models/recording_state_enum'
Expand Down
26 changes: 22 additions & 4 deletions lib/bandwidth-sdk/models/rbm_action_open_url.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ class RbmActionOpenUrl < ApiModelBase
# The URL to open in browser.
attr_accessor :url

attr_accessor :application

attr_accessor :webview_view_mode

class EnumAttributeValidator
attr_reader :datatype
attr_reader :allowable_values
Expand Down Expand Up @@ -54,7 +58,9 @@ def self.attribute_map
:'type' => :'type',
:'text' => :'text',
:'postback_data' => :'postbackData',
:'url' => :'url'
:'url' => :'url',
:'application' => :'application',
:'webview_view_mode' => :'webviewViewMode'
}
end

Expand All @@ -74,7 +80,9 @@ def self.openapi_types
:'type' => :'RbmActionTypeEnum',
:'text' => :'String',
:'postback_data' => :'String',
:'url' => :'String'
:'url' => :'String',
:'application' => :'RbmOpenUrlEnum',
:'webview_view_mode' => :'RbmWebViewEnum'
}
end

Expand Down Expand Up @@ -130,6 +138,14 @@ def initialize(attributes = {})
else
self.url = nil
end

if attributes.key?(:'application')
self.application = attributes[:'application']
end

if attributes.key?(:'webview_view_mode')
self.webview_view_mode = attributes[:'webview_view_mode']
end
end

# Show invalid properties with the reasons. Usually used together with valid?
Expand Down Expand Up @@ -242,7 +258,9 @@ def ==(o)
type == o.type &&
text == o.text &&
postback_data == o.postback_data &&
url == o.url
url == o.url &&
application == o.application &&
webview_view_mode == o.webview_view_mode
end

# @see the `==` method
Expand All @@ -254,7 +272,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[type, text, postback_data, url].hash
[type, text, postback_data, url, application, webview_view_mode].hash
end

# Builds the object from hash
Expand Down
40 changes: 40 additions & 0 deletions lib/bandwidth-sdk/models/rbm_open_url_enum.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
=begin
#Bandwidth

#Bandwidth's Communication APIs

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

=end

require 'date'
require 'time'

module Bandwidth
class RbmOpenUrlEnum
BROWSER = 'BROWSER'.freeze
WEBVIEW = 'WEBVIEW'.freeze

def self.all_vars
@all_vars ||= [BROWSER, WEBVIEW].freeze
end

# Builds the enum from string
# @param [String] The enum value in the form of the string
# @return [String] The enum value
def self.build_from_hash(value)
new.build_from_hash(value)
end

# Builds the enum from string
# @param [String] The enum value in the form of the string
# @return [String] The enum value
def build_from_hash(value)
return value if RbmOpenUrlEnum.all_vars.include?(value)
raise "Invalid ENUM value #{value} for class #RbmOpenUrlEnum"
end
end
end
41 changes: 41 additions & 0 deletions lib/bandwidth-sdk/models/rbm_web_view_enum.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
=begin
#Bandwidth

#Bandwidth's Communication APIs

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

=end

require 'date'
require 'time'

module Bandwidth
class RbmWebViewEnum
FULL = 'FULL'.freeze
HALF = 'HALF'.freeze
TALL = 'TALL'.freeze

def self.all_vars
@all_vars ||= [FULL, HALF, TALL].freeze
end

# Builds the enum from string
# @param [String] The enum value in the form of the string
# @return [String] The enum value
def self.build_from_hash(value)
new.build_from_hash(value)
end

# Builds the enum from string
# @param [String] The enum value in the form of the string
# @return [String] The enum value
def build_from_hash(value)
return value if RbmWebViewEnum.all_vars.include?(value)
raise "Invalid ENUM value #{value} for class #RbmWebViewEnum"
end
end
end