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: 2 additions & 2 deletions bandwidth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8237,8 +8237,8 @@ components:
in: path
name: mediaId
required: true
description: Media ID to retrieve.
example: 14762070468292kw2fuqty55yp2b2/0/bw.png
description: The ID of the media file.
example: bw.png
schema:
type: string
contentType:
Expand Down
1 change: 1 addition & 0 deletions custom_templates/gem.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ require 'bandwidth-sdk/models/bxml/verbs/phone_number'
require 'bandwidth-sdk/models/bxml/verbs/play_audio'
require 'bandwidth-sdk/models/bxml/verbs/record'
require 'bandwidth-sdk/models/bxml/verbs/redirect'
require 'bandwidth-sdk/models/bxml/verbs/refer'
require 'bandwidth-sdk/models/bxml/verbs/resume_recording'
require 'bandwidth-sdk/models/bxml/verbs/ring'
require 'bandwidth-sdk/models/bxml/verbs/send_dtmf'
Expand Down
12 changes: 6 additions & 6 deletions docs/MediaApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ end

api_instance = Bandwidth::MediaApi.new
account_id = '9900000' # String | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
media_id = '14762070468292kw2fuqty55yp2b2/0/bw.png' # String | Media ID to retrieve.
media_id = 'bw.png' # String | The ID of the media file.

begin
# Delete Media
Expand Down Expand Up @@ -68,7 +68,7 @@ end
| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **account_id** | **String** | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.** | |
| **media_id** | **String** | Media ID to retrieve. | |
| **media_id** | **String** | The ID of the media file. | |

### Return type

Expand Down Expand Up @@ -109,7 +109,7 @@ end

api_instance = Bandwidth::MediaApi.new
account_id = '9900000' # String | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
media_id = '14762070468292kw2fuqty55yp2b2/0/bw.png' # String | Media ID to retrieve.
media_id = 'bw.png' # String | The ID of the media file.

begin
# Get Media
Expand Down Expand Up @@ -143,7 +143,7 @@ end
| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **account_id** | **String** | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.** | |
| **media_id** | **String** | Media ID to retrieve. | |
| **media_id** | **String** | The ID of the media file. | |

### Return type

Expand Down Expand Up @@ -261,7 +261,7 @@ end

api_instance = Bandwidth::MediaApi.new
account_id = '9900000' # String | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
media_id = '14762070468292kw2fuqty55yp2b2/0/bw.png' # String | Media ID to retrieve.
media_id = 'bw.png' # String | The ID of the media file.
body = File.new('/path/to/some/file') # File |
opts = {
content_type: 'audio/wav', # String | The media type of the entity-body.
Expand Down Expand Up @@ -299,7 +299,7 @@ end
| Name | Type | Description | Notes |
| ---- | ---- | ----------- | ----- |
| **account_id** | **String** | This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.** | |
| **media_id** | **String** | Media ID to retrieve. | |
| **media_id** | **String** | The ID of the media file. | |
| **body** | **File** | | |
| **content_type** | **String** | The media type of the entity-body. | [optional] |
| **cache_control** | **String** | General-header field is used to specify directives that MUST be obeyed by all caching mechanisms along the request/response chain. | [optional] |
Expand Down
12 changes: 6 additions & 6 deletions lib/bandwidth-sdk/api/media_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def initialize(api_client = ApiClient.default)
# Delete Media
# Deletes a media file from Bandwidth API server. Make sure you don't have any application scripts still using the media before you delete. If you accidentally delete a media file you can immediately upload a new file with the same name.
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param [Hash] opts the optional parameters
# @return [nil]
def delete_media(account_id, media_id, opts = {})
Expand All @@ -33,7 +33,7 @@ def delete_media(account_id, media_id, opts = {})
# Delete Media
# Deletes a media file from Bandwidth API server. Make sure you don't have any application scripts still using the media before you delete. If you accidentally delete a media file you can immediately upload a new file with the same name.
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (`u-be8dvafwrs63rwpm7pfil4b`) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param [Hash] opts the optional parameters
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
def delete_media_with_http_info(account_id, media_id, opts = {})
Expand Down Expand Up @@ -91,7 +91,7 @@ def delete_media_with_http_info(account_id, media_id, opts = {})
# Get Media
# Downloads a media file you previously uploaded.
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (&#x60;u-be8dvafwrs63rwpm7pfil4b&#x60;) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param [Hash] opts the optional parameters
# @return [File]
def get_media(account_id, media_id, opts = {})
Expand All @@ -102,7 +102,7 @@ def get_media(account_id, media_id, opts = {})
# Get Media
# Downloads a media file you previously uploaded.
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (&#x60;u-be8dvafwrs63rwpm7pfil4b&#x60;) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param [Hash] opts the optional parameters
# @return [Array<(File, Integer, Hash)>] File data, response status code and response headers
def get_media_with_http_info(account_id, media_id, opts = {})
Expand Down Expand Up @@ -226,7 +226,7 @@ def list_media_with_http_info(account_id, opts = {})
# Upload Media
# Upload a file. You may add headers to the request in order to provide some control to your media file. If a file is uploaded with the same name as a file that already exists under this account, the previous file will be overwritten. A list of supported media types can be found at [Bandwidth Support](https://www.bandwidth.com/support/en/articles/12823220-what-mms-file-types-are-supported).
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (&#x60;u-be8dvafwrs63rwpm7pfil4b&#x60;) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param body [File]
# @param [Hash] opts the optional parameters
# @option opts [String] :content_type The media type of the entity-body.
Expand All @@ -240,7 +240,7 @@ def upload_media(account_id, media_id, body, opts = {})
# Upload Media
# Upload a file. You may add headers to the request in order to provide some control to your media file. If a file is uploaded with the same name as a file that already exists under this account, the previous file will be overwritten. A list of supported media types can be found at [Bandwidth Support](https://www.bandwidth.com/support/en/articles/12823220-what-mms-file-types-are-supported).
# @param account_id [String] This is your 7-digit Bandwidth Account ID, as shown in the Bandwidth App. The older ID format (&#x60;u-be8dvafwrs63rwpm7pfil4b&#x60;) is deprecated. **When migrating to OAuth authentication, you must use the 7-digit Account ID.**
# @param media_id [String] Media ID to retrieve.
# @param media_id [String] The ID of the media file.
# @param body [File]
# @param [Hash] opts the optional parameters
# @option opts [String] :content_type The media type of the entity-body.
Expand Down
4 changes: 2 additions & 2 deletions spec/smoke/media_api_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
before(:all) do
config = Bandwidth::Configuration.new
config.configure do |config|
config.username = BW_USERNAME
config.password = BW_PASSWORD
config.client_id = BW_CLIENT_ID
config.client_secret = BW_CLIENT_SECRET
config.return_binary_data = true
end
client = Bandwidth::ApiClient.new(config)
Expand Down
4 changes: 2 additions & 2 deletions spec/smoke/messages_api_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
before(:all) do
config = Bandwidth::Configuration.new
config.configure do |config|
config.username = BW_USERNAME
config.password = BW_PASSWORD
config.client_id = BW_CLIENT_ID
config.client_secret = BW_CLIENT_SECRET
end
client = Bandwidth::ApiClient.new(config)
@messaging_api_instance = Bandwidth::MessagesApi.new(client)
Expand Down