Skip to content

Commit

Permalink
Merge pull request #16 from Bandwidth/release/2021-03-08-21-34-11
Browse files Browse the repository at this point in the history
WebRtc permissions new field
  • Loading branch information
jmulford-bw authored Mar 23, 2021
2 parents f087019 + 1e70a8b commit e972ba8
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitkeep
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
README.md
lib/bandwidth/voice_lib/bxml/*
lib/bandwidth/web_rtc_lib/utils/*
test/integration/*
2 changes: 1 addition & 1 deletion bandwidth.gemspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'bandwidth-sdk'
s.version = '6.0.0'
s.version = '6.1.0'
s.summary = 'bandwidth'
s.description = 'Bandwidth\'s set of APIs'
s.authors = ['APIMatic SDK Generator']
Expand Down
1 change: 1 addition & 0 deletions lib/bandwidth/web_rtc_lib/web_rtc.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
require_relative 'web_rtc/models/subscriptions.rb'
require_relative 'web_rtc/models/participant_subscription.rb'
require_relative 'web_rtc/models/accounts_participants_response.rb'
require_relative 'web_rtc/models/device_api_version_enum.rb'
require_relative 'web_rtc/models/publish_permission_enum.rb'

# Exceptions
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# bandwidth
#
# This file was automatically generated by APIMATIC v2.0
# ( https://apimatic.io ).

module Bandwidth
# Optional field to define the device api version of this participant
class DeviceApiVersionEnum
DEVICE_API_VERSION_ENUM = [
# TODO: Write general description for V3
V3 = 'v3'.freeze,

# TODO: Write general description for V2
V2 = 'v2'.freeze
].freeze
end
end
13 changes: 11 additions & 2 deletions lib/bandwidth/web_rtc_lib/web_rtc/models/participant.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ class Participant < BaseModel
# @return [String]
attr_accessor :tag

# Optional field to define the device api version of this participant
# @return [DeviceApiVersionEnum]
attr_accessor :device_api_version

# A mapping from model property names to API property names.
def self.names
@_hash = {} if @_hash.nil?
Expand All @@ -41,6 +45,7 @@ def self.names
@_hash['sessions'] = 'sessions'
@_hash['subscriptions'] = 'subscriptions'
@_hash['tag'] = 'tag'
@_hash['device_api_version'] = 'deviceApiVersion'
@_hash
end

Expand All @@ -49,13 +54,15 @@ def initialize(id = nil,
publish_permissions = nil,
sessions = nil,
subscriptions = nil,
tag = nil)
tag = nil,
device_api_version = DeviceApiVersionEnum::V2)
@id = id
@callback_url = callback_url
@publish_permissions = publish_permissions
@sessions = sessions
@subscriptions = subscriptions
@tag = tag
@device_api_version = device_api_version
end

# Creates an instance of the object from a hash.
Expand All @@ -70,14 +77,16 @@ def self.from_hash(hash)
subscriptions = Subscriptions.from_hash(hash['subscriptions']) if
hash['subscriptions']
tag = hash['tag']
device_api_version = hash['deviceApiVersion'] ||= DeviceApiVersionEnum::V2

# Create object from extracted values.
Participant.new(id,
callback_url,
publish_permissions,
sessions,
subscriptions,
tag)
tag,
device_api_version)
end
end
end

0 comments on commit e972ba8

Please sign in to comment.