Class: ConferenceCallService::ConferenceCallService
- Inherits:
-
AuthenticatedService
- Object
- Handsoap::Service
- BasicService
- AuthenticatedService
- ConferenceCallService::ConferenceCallService
- Defined in:
- lib/conference_call_service/conference_call_service.rb
Overview
Client to access the developer garden conference call service.
See also:
Constant Summary collapse
- @@CONFERENCE_CALL_SCHEMA =
'http://ccs.developer.telekom.com/schema/'- @@CONFERENCE_CALL_SCHEMA_SERVICE_ENDPOINT =
{ :uri => "https://gateway.developer.telekom.com/p3gw-mod-odg-ccs/services/ccsPort", :version => 1 }
Class Method Summary collapse
-
.CONFERENCE_CALL_SCHEMA ⇒ Object
Static Methods.
-
.xpath_query(doc, query_string, global_search = true) ⇒ Object
Performs a xpath query in the ip location namespace for the given document and query string.
Instance Method Summary collapse
-
#add_conference_template_participant(template_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Give the list of the templates of the given conference owner ===Parameters
template_id - conference in which will be added the participant
participant - participant who will be added to the conference
environment -
Service environment as defined in ServiceLevel.
- participant who will be added to the conference
- conference in which will be added the participant
- Give the list of the templates of the given conference owner ===Parameters
-
#commit_conference(conference_id, environment = ServiceEnvironment.MOCK) ⇒ Object
Stores the created conference to the conference call server.
-
#create_conference(owner_id, detail, schedule = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Creates a new conference.
-
#create_conference_template(owner_id, detail, participants = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Creates a conference template.
-
#get_conference_list(owner_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves spatial information about the given ip address.
-
#get_conference_status(conference_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves that status of the given conference.
-
#get_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Returns the confernece template with the given id.
-
#get_conference_template_list(owner_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Give the list of the templates of the given conference owner ===Parameters
owner_id - id of the owner of the requested conference
environment -
Service environment as defined in ServiceLevel.
- id of the owner of the requested conference
- Give the list of the templates of the given conference owner ===Parameters
-
#get_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Give the list of the templates of the given conference owner ===Parameters
template_id - id of the template in which we call the participant
participant_id - id of the called participant
environment -
Service environment as defined in ServiceLevel.
- id of the called participant
- id of the template in which we call the participant
- Give the list of the templates of the given conference owner ===Parameters
-
#get_participant_status(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves the status of the given participant in the specified conference.
-
#get_running_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Tell whether a conference is running ===Parameters
conference_id - id of the maybe running conference
environment -
Service environment as defined in ServiceLevel.
- id of the maybe running conference
- Tell whether a conference is running ===Parameters
-
#new_participant(conference_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Adds the given participant to the specified conference.
-
#on_create_document(doc) ⇒ Object
Add namespaces to the handsoap XmlMason document.
-
#remove_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Removes the given conference.
-
#remove_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Parameters
template_id:: template of the removed conferenceenvironment:: Service environment as defined in ServiceLevel. -
#remove_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Give the list of the templates of the given conference owner ===Parameters
template_id - id of the template in which we call the participant
participant_id - id of the called participant
environment -
Service environment as defined in ServiceLevel.
- id of the called participant
- id of the template in which we call the participant
- Give the list of the templates of the given conference owner ===Parameters
-
#remove_participant(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves that status of the given conference.
-
#update_conference(conference_id, conference_details = nil, schedule = nil, initiator_id = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates an existing conference.
-
#update_conference_template(template_id, initiator_id, detail, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates the specified conference with the given parameters.
-
#update_conference_template_participant(template_id, participant_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
- Update the details of a given participant ===Parameters
template_id - id of the template in which we call the participant
participant_id - id of the changed participant
participant - details of the changed participant
environment -
Service environment as defined in ServiceLevel.
- details of the changed participant
- id of the changed participant
- id of the template in which we call the participant
- Update the details of a given participant ===Parameters
-
#update_participant(conference_id, participant_id, participant_detail = nil, action = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates the settings for the given participant of the given conference call.
Methods inherited from AuthenticatedService
#initialize, #invoke_authenticated
Methods inherited from BasicService
#initialize, #on_response_document
Constructor Details
This class inherits a constructor from AuthenticatedService
Class Method Details
.CONFERENCE_CALL_SCHEMA ⇒ Object
Static Methods
468 469 470 |
# File 'lib/conference_call_service/conference_call_service.rb', line 468 def self.CONFERENCE_CALL_SCHEMA return @@CONFERENCE_CALL_SCHEMA end |
.xpath_query(doc, query_string, global_search = true) ⇒ Object
Performs a xpath query in the ip location namespace for the given document and query string.
Parameters
doc-
XmlQueryFront document.
query_string-
Element to look for
global_search-
Searches within all levels using “//” if
global_search = true.
477 478 479 |
# File 'lib/conference_call_service/conference_call_service.rb', line 477 def self.xpath_query(doc, query_string, global_search = true) self.xpath_query_for_schema(@@CONFERENCE_CALL_SCHEMA, doc, query_string, global_search) end |
Instance Method Details
#add_conference_template_participant(template_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Give the list of the templates of the given conference owner
Parameters
template_id-
conference in which will be added the participant
participant-
participant who will be added to the conference
environment-
Service environment as defined in ServiceLevel.
450 451 452 453 454 455 456 457 458 459 460 461 462 463 |
# File 'lib/conference_call_service/conference_call_service.rb', line 450 def add_conference_template_participant(template_id, participant, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:addConferenceTemplateParticipant") do |request, doc| request.add('addConferenceTemplateParticipantRequest') do |add_conference_template_participant_request| add_conference_template_participant_request.add('environment', environment) add_conference_template_participant_request.add('templateId', template_id.to_s) add_conference_template_participant_request.add('participant') do |participant_request| participant.add_to_handsoap_xml(participant_request) end add_conference_template_participant_request.add('account', account) if (account && !account.empty?) end end response = AddConferenceTemplateParticipantResponse.new(response_xml) end |
#commit_conference(conference_id, environment = ServiceEnvironment.MOCK) ⇒ Object
Stores the created conference to the conference call server.
Parameters
conference_id-
id of the interest conference
environment-
Service environment as defined in ServiceEnvironment.
62 63 64 65 66 67 68 69 70 71 |
# File 'lib/conference_call_service/conference_call_service.rb', line 62 def commit_conference(conference_id, environment = ServiceEnvironment.MOCK) response_xml = invoke_authenticated("cc:commitConference") do |request, doc| request.add('commitConferenceRequest') do |commit_request, doc| commit_request.add('conferenceId', conference_id) commit_request.add('environment', environment) end end response = CommitConferenceResponse.new(response_xml) end |
#create_conference(owner_id, detail, schedule = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Creates a new conference.
Parameters
owner_id-
Return only items owned by the given user such as “max.mustermann”.
detail-
Specifies the conference details like max duration, name and description.
schedule-
Specifies when the conference will take place and if its going to be repeated on a regular basis.
environment-
Service environment as defined in ServiceLevel.
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 |
# File 'lib/conference_call_service/conference_call_service.rb', line 79 def create_conference(owner_id, detail, schedule = nil, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:createConference") do |request, doc| request.add('createConferenceRequest') do |create_request| create_request.add('environment', environment) create_request.add('ownerId', owner_id.to_s) create_request.add('detail') do |detail_request| detail.add_to_handsoap_xml(detail_request) end # schedule if schedule then create_request.add('schedule') do |schedule_request| schedule.add_to_handsoap_xml(schedule_request) end end create_request.add('account', account) if (account && !account.empty?) end end response = CreateConferenceResponse.new(response_xml) end |
#create_conference_template(owner_id, detail, participants = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Creates a conference template.
Parameters
owner_id-
id of the owner of the conference template
detail-
details of the conference template. ConferenceDetails Type
participants-
optional parameter of the type ParticipantDetail
environment-
Service environment as defined in ServiceLevel.
295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 |
# File 'lib/conference_call_service/conference_call_service.rb', line 295 def create_conference_template(owner_id, detail, participants = nil, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:createConferenceTemplate") do |request, doc| request.add('createConferenceTemplateRequest') do |create_conference_template_request| create_conference_template_request.add('environment', environment) create_conference_template_request.add('account', account) if (account && !account.empty?) create_conference_template_request.add('ownerId', owner_id.to_s) create_conference_template_request.add('detail') do |detail_request| detail.add_to_handsoap_xml(detail_request) end if participants then participants.each do |participant| create_conference_template_request.add('participants') do |participant_request| participant.add_to_handsoap_xml(participant_request) end end end end end response = CreateConferenceTemplateResponse.new(response_xml) end |
#get_conference_list(owner_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves spatial information about the given ip address.
Parameters
owner_id-
Return only items owned by the given user such as “max.mustermann”.
what-
Constraints of the list to be retrieved.
environment-
Service environment as defined in ServiceLevel.
account-
IP address for which to perform an ip location.
109 110 111 112 113 114 115 116 117 118 119 120 121 122 |
# File 'lib/conference_call_service/conference_call_service.rb', line 109 def get_conference_list(owner_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getConferenceList") do |request, doc| request.add('getConferenceListRequest') do |list_request| list_request.add('environment', environment) list_request.add('what', what.to_s) list_request.add('ownerId', owner_id.to_s) list_request.add('account', account) if (account && !account.empty?) end end response = GetConferenceListResponse.new(response_xml) return response end |
#get_conference_status(conference_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves that status of the given conference.
Parameters
conference_id-
Id of the conference of interest.
what-
Contraints of the list to be retrieved.
environment-
Service environment as defined in ServiceLevel.
129 130 131 132 133 134 135 136 137 138 139 140 141 |
# File 'lib/conference_call_service/conference_call_service.rb', line 129 def get_conference_status(conference_id, what = ConferenceConstants.CONFERENCE_LIST_ALL, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getConferenceStatus") do |request, doc| request.add('getConferenceStatusRequest') do |status_request| status_request.add('environment', environment) status_request.add('what', what.to_s) status_request.add('conferenceId', conference_id.to_s) status_request.add('account', account) if (account && !account.empty?) end end response = GetConferenceStatusResponse.new(response_xml) return response end |
#get_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Returns the confernece template with the given id.
Parameters
template_id-
Id of the template of interest.
environment-
Service environment as defined in ServiceLevel.
322 323 324 325 326 327 328 329 330 331 332 |
# File 'lib/conference_call_service/conference_call_service.rb', line 322 def get_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getConferenceTemplate") do |request, doc| request.add('getConferenceTemplateRequest') do |get_conference_template_request| get_conference_template_request.add('environment', environment) get_conference_template_request.add('templateId', template_id.to_s) get_conference_template_request.add('account', account) if (account && !account.empty?) end end response = GetConferenceTemplateResponse.new(response_xml) end |
#get_conference_template_list(owner_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Give the list of the templates of the given conference owner
Parameters
owner_id-
id of the owner of the requested conference
environment-
Service environment as defined in ServiceLevel.
375 376 377 378 379 380 381 382 383 384 385 |
# File 'lib/conference_call_service/conference_call_service.rb', line 375 def get_conference_template_list(owner_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getConferenceTemplateList") do |request, doc| request.add('getConferenceTemplateListRequest') do |get_conference_template_list_request| get_conference_template_list_request.add('environment', environment) get_conference_template_list_request.add('ownerId', owner_id.to_s) get_conference_template_list_request.add('account', account) if (account && !account.empty?) end end response = GetConferenceTemplateListResponse.new(response_xml) end |
#get_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Give the list of the templates of the given conference owner
Parameters
template_id-
id of the template in which we call the participant
participant_id-
id of the called participant
environment-
Service environment as defined in ServiceLevel.
392 393 394 395 396 397 398 399 400 401 402 403 |
# File 'lib/conference_call_service/conference_call_service.rb', line 392 def get_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getConferenceTemplateParticipant") do |request, doc| request.add('getConferenceTemplateParticipantRequest') do |get_conference_template_participant_request| get_conference_template_participant_request.add('environment', environment) get_conference_template_participant_request.add('templateId', template_id.to_s) get_conference_template_participant_request.add('participantId', participant_id.to_s) get_conference_template_participant_request.add('account', account) if (account && !account.empty?) end end response = GetConferenceTemplateParticipantResponse.new(response_xml) end |
#get_participant_status(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves the status of the given participant in the specified conference.
Parameters
conference_id-
Id of the intended conference.
participant_id-
Id of the desired participant.
environment-
Service environment as defined in ServiceLevel.
148 149 150 151 152 153 154 155 156 157 158 159 |
# File 'lib/conference_call_service/conference_call_service.rb', line 148 def get_participant_status(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getParticipantStatus") do |request, doc| request.add('getParticipantStatusRequest') do |new_participant_request| new_participant_request.add('environment', environment) new_participant_request.add('account', account) if (account && !account.empty?) new_participant_request.add('conferenceId', conference_id.to_s) new_participant_request.add('participantId', participant_id) end end response = GetParticipantStatusResponse.new(response_xml) end |
#get_running_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Tell whether a conference is running
Parameters
conference_id-
id of the maybe running conference
environment-
Service environment as defined in ServiceLevel.
277 278 279 280 281 282 283 284 285 286 287 |
# File 'lib/conference_call_service/conference_call_service.rb', line 277 def get_running_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:getRunningConference") do |request, doc| request.add('getRunningConferenceRequest') do |get_running_conference_request| get_running_conference_request.add('environment', environment) get_running_conference_request.add('conferenceId', conference_id.to_s) get_running_conference_request.add('account', account) if (account && !account.empty?) end end response = GetRunningConferenceResponse.new(response_xml) end |
#new_participant(conference_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Adds the given participant to the specified conference.
Parameters ra
conference_id-
Id of the intended conference.
participant-
Details of the participant to be added.
environment-
Service environment as defined in ServiceLevel.
166 167 168 169 170 171 172 173 174 175 176 177 178 179 |
# File 'lib/conference_call_service/conference_call_service.rb', line 166 def new_participant(conference_id, participant, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:newParticipant") do |request, doc| request.add('newParticipantRequest') do |new_participant_request| new_participant_request.add('environment', environment) new_participant_request.add('account', account) if (account && !account.empty?) new_participant_request.add('conferenceId', conference_id.to_s) new_participant_request.add('participant') do |participant_request| participant.add_to_handsoap_xml(participant_request) end end end response = NewParticipantResponse.new(response_xml) end |
#on_create_document(doc) ⇒ Object
Add namespaces to the handsoap XmlMason document.
53 54 55 56 |
# File 'lib/conference_call_service/conference_call_service.rb', line 53 def on_create_document(doc) super(doc) doc.alias 'cc', @@CONFERENCE_CALL_SCHEMA end |
#remove_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Removes the given conference.
Parameters
conference_id-
id of the removed conference
environment-
Service environment as defined in ServiceLevel.
213 214 215 216 217 218 219 220 221 222 223 |
# File 'lib/conference_call_service/conference_call_service.rb', line 213 def remove_conference(conference_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:removeConference") do |request, doc| request.add('removeConferenceRequest') do |remove_conference_request| remove_conference_request.add('environment', environment) remove_conference_request.add('conferenceId', conference_id.to_s) remove_conference_request.add('account', account) if (account && !account.empty?) end end response = RemoveConferenceResponse.new(response_xml) end |
#remove_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Parameters
template_id-
template of the removed conference
environment-
Service environment as defined in ServiceLevel.
359 360 361 362 363 364 365 366 367 368 369 |
# File 'lib/conference_call_service/conference_call_service.rb', line 359 def remove_conference_template(template_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:removeConferenceTemplate") do |request, doc| request.add('getConferenceTemplateRequest') do |remove_conference_template_request| remove_conference_template_request.add('environment', environment) remove_conference_template_request.add('templateId', template_id.to_s) remove_conference_template_request.add('account', account) if (account && !account.empty?) end end response = RemoveConferenceTemplateResponse.new(response_xml) end |
#remove_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Give the list of the templates of the given conference owner
Parameters
template_id-
id of the template in which we call the participant
participant_id-
id of the called participant
environment-
Service environment as defined in ServiceLevel.
432 433 434 435 436 437 438 439 440 441 442 443 |
# File 'lib/conference_call_service/conference_call_service.rb', line 432 def remove_conference_template_participant(template_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:removeConferenceTemplateParticipant") do |request, doc| request.add('removeConferenceTemplateParticipantRequest') do |remove_conference_template_participant_request| remove_conference_template_participant_request.add('environment', environment) remove_conference_template_participant_request.add('templateId', template_id.to_s) remove_conference_template_participant_request.add('participantId', participant_id.to_s) remove_conference_template_participant_request.add('account', account) if (account && !account.empty?) end end response = RemoveConferenceTemplateParticipantResponse.new(response_xml) end |
#remove_participant(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Retrieves that status of the given conference.
Parameters
conference_idwhat-
Constraints of the list to be retrieved.
environment-
Service environment as defined in ServiceLevel.
230 231 232 233 234 235 236 237 238 239 240 241 |
# File 'lib/conference_call_service/conference_call_service.rb', line 230 def remove_participant(conference_id, participant_id, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:removeParticipant") do |request, doc| request.add('removeParticipantRequest') do |remove_request| remove_request.add('environment', environment) remove_request.add('account', account) if (account && !account.empty?) remove_request.add('conferenceId', conference_id.to_s) remove_request.add('participantId', participant_id.to_s) end end response = RemoveParticipantResponse.new(response_xml) end |
#update_conference(conference_id, conference_details = nil, schedule = nil, initiator_id = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates an existing conference.
Parameters
conference_id-
Id of the conference
conference_details-
Id of the conference
environment-
Service environment as defined in ServiceLevel.
248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 |
# File 'lib/conference_call_service/conference_call_service.rb', line 248 def update_conference(conference_id, conference_details = nil, schedule = nil, initiator_id = nil, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:updateConference") do |request, doc| request.add('updateConferenceRequest') do |remove_request| remove_request.add('environment', environment) remove_request.add('account', account) if (account && !account.empty?) remove_request.add('conferenceId', conference_id.to_s) remove_request.add('initiatorId', initiator_id.to_s) if conference_details then remove_request.add('detail') do |detail_request| conference_details.add_to_handsoap_xml(detail_request) end end if schedule then remove_request.add('schedule') do |schedule_request| schedule.add_to_handsoap_xml(schedule_request) end end end end response = UpdateConferenceResponse.new(response_xml) end |
#update_conference_template(template_id, initiator_id, detail, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates the specified conference with the given parameters.
Parameters
template_id-
id of the updated template
initiator_id-
id of the initiator of the conference
details-
details of the conference template
environment-
Service environment as defined in ServiceLevel.
340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 |
# File 'lib/conference_call_service/conference_call_service.rb', line 340 def update_conference_template(template_id, initiator_id, detail, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:updateConferenceTemplate") do |request, doc| request.add('updateConferenceTemplateRequest') do |update_conference_template_request| update_conference_template_request.add('environment', environment) update_conference_template_request.add('templateId', template_id.to_s) update_conference_template_request.add('initiatorId', initiator_id.to_s) update_conference_template_request.add('detail') do |detail_request| detail.add_to_handsoap_xml(detail_request) end update_conference_template_request.add('account', account) if (account && !account.empty?) end end response = UpdateConferenceTemplateResponse.new(response_xml) end |
#update_conference_template_participant(template_id, participant_id, participant, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Update the details of a given participant
Parameters
template_id-
id of the template in which we call the participant
participant_id-
id of the changed participant
participant-
details of the changed participant
environment-
Service environment as defined in ServiceLevel.
411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 |
# File 'lib/conference_call_service/conference_call_service.rb', line 411 def update_conference_template_participant(template_id, participant_id, participant, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:updateConferenceTemplateParticipant") do |request, doc| request.add('updateConferenceTemplateParticipantRequest') do |update_conference_template_participant_request| update_conference_template_participant_request.add('environment', environment) update_conference_template_participant_request.add('templateId', template_id.to_s) update_conference_template_participant_request.add('participantId', participant_id.to_s) update_conference_template_participant_request.add('participant') do |participant_request| participant.add_to_handsoap_xml(participant_request) end update_conference_template_participant_request.add('account', account) if (account && !account.empty?) end end response = UpdateConferenceTemplateParticipantResponse.new(response_xml) end |
#update_participant(conference_id, participant_id, participant_detail = nil, action = nil, environment = ServiceEnvironment.MOCK, account = nil) ⇒ Object
Updates the settings for the given participant of the given conference call.
Parameters
conference_id-
id of the interest conference
participant_id-
id of the coming participant
participant_detail-
Details of the coming participant
action-
Action to performed for the given participant. Actions are mute, umute and redial. See ConferenceConstants for the corresponding constants.
environment-
Service environment as defined in ServiceLevel.
189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 |
# File 'lib/conference_call_service/conference_call_service.rb', line 189 def update_participant(conference_id, participant_id, participant_detail = nil, action = nil, environment = ServiceEnvironment.MOCK, account = nil) response_xml = invoke_authenticated("cc:updateParticipant") do |request, doc| request.add('updateParticipantRequest') do |update_participant_request| update_participant_request.add('environment', environment) update_participant_request.add('account', account) if (account && !account.empty?) update_participant_request.add('conferenceId', conference_id.to_s) update_participant_request.add('participantId', participant_id.to_s) update_participant_request.add('action', action.to_s) if action if participant_detail then update_participant_request.add('participant') do |participant_request| participant_detail.add_to_handsoap_xml(participant_request) end end end end response = UpdateParticipantResponse.new(response_xml) end |