Class: Twilio::REST::Insights::V1::ConferenceInstance

Inherits:
Twilio::REST::InstanceResource show all
Defined in:
lib/twilio-ruby/rest/insights/v1/conference.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload, conference_sid: nil) ⇒ ConferenceInstance

Initialize the ConferenceInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio

  • conference_sid (String) (defaults to: nil)

    The unique SID identifier of the Conference.


297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 297

def initialize(version, payload, conference_sid: nil)
  super(version)

  # Marshaled Properties
  @properties = {
      'conference_sid' => payload['conference_sid'],
      'account_sid' => payload['account_sid'],
      'friendly_name' => payload['friendly_name'],
      'create_time' => Twilio.deserialize_iso8601_datetime(payload['create_time']),
      'start_time' => Twilio.deserialize_iso8601_datetime(payload['start_time']),
      'end_time' => Twilio.deserialize_iso8601_datetime(payload['end_time']),
      'duration_seconds' => payload['duration_seconds'] == nil ? payload['duration_seconds'] : payload['duration_seconds'].to_i,
      'connect_duration_seconds' => payload['connect_duration_seconds'] == nil ? payload['connect_duration_seconds'] : payload['connect_duration_seconds'].to_i,
      'status' => payload['status'],
      'max_participants' => payload['max_participants'] == nil ? payload['max_participants'] : payload['max_participants'].to_i,
      'max_concurrent_participants' => payload['max_concurrent_participants'] == nil ? payload['max_concurrent_participants'] : payload['max_concurrent_participants'].to_i,
      'unique_participants' => payload['unique_participants'] == nil ? payload['unique_participants'] : payload['unique_participants'].to_i,
      'end_reason' => payload['end_reason'],
      'ended_by' => payload['ended_by'],
      'mixer_region' => payload['mixer_region'],
      'mixer_region_requested' => payload['mixer_region_requested'],
      'recording_enabled' => payload['recording_enabled'],
      'detected_issues' => payload['detected_issues'],
      'tags' => payload['tags'],
      'tag_info' => payload['tag_info'],
      'processing_state' => payload['processing_state'],
      'url' => payload['url'],
      'links' => payload['links'],
  }

  # Context
  @instance_context = nil
  @params = {'conference_sid' => conference_sid || @properties['conference_sid'], }
end

Instance Method Details

#account_sidString

Returns Account SID.

Returns:

  • (String)

    Account SID.


351
352
353
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 351

def 
  @properties['account_sid']
end

#conference_participantsconference_participants

Access the conference_participants

Returns:


491
492
493
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 491

def conference_participants
  context.conference_participants
end

#conference_sidString

Returns Conference SID.

Returns:

  • (String)

    Conference SID.


345
346
347
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 345

def conference_sid
  @properties['conference_sid']
end

#connect_duration_secondsString

Returns Duration of the conference in seconds.

Returns:

  • (String)

    Duration of the conference in seconds.


387
388
389
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 387

def connect_duration_seconds
  @properties['connect_duration_seconds']
end

#contextConferenceContext

Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context

Returns:


336
337
338
339
340
341
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 336

def context
  unless @instance_context
    @instance_context = ConferenceContext.new(@version, @params['conference_sid'], )
  end
  @instance_context
end

#create_timeTime

Returns Conference creation date/time.

Returns:

  • (Time)

    Conference creation date/time.


363
364
365
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 363

def create_time
  @properties['create_time']
end

#detected_issuesHash

Returns Potential issues detected during the conference.

Returns:

  • (Hash)

    Potential issues detected during the conference.


447
448
449
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 447

def detected_issues
  @properties['detected_issues']
end

#duration_secondsString

Returns Conference duration in seconds.

Returns:

  • (String)

    Conference duration in seconds.


381
382
383
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 381

def duration_seconds
  @properties['duration_seconds']
end

#end_reasonconference.ConferenceEndReason

Returns Conference end reason.

Returns:

  • (conference.ConferenceEndReason)

    Conference end reason.


417
418
419
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 417

def end_reason
  @properties['end_reason']
end

#end_timeTime

Returns Conference end date/time.

Returns:

  • (Time)

    Conference end date/time.


375
376
377
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 375

def end_time
  @properties['end_time']
end

#ended_byString

Returns Call SID that ended the conference.

Returns:

  • (String)

    Call SID that ended the conference.


423
424
425
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 423

def ended_by
  @properties['ended_by']
end

#fetchConferenceInstance

Fetch the ConferenceInstance

Returns:


484
485
486
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 484

def fetch
  context.fetch
end

#friendly_nameString

Returns Custom label for the conference.

Returns:

  • (String)

    Custom label for the conference.


357
358
359
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 357

def friendly_name
  @properties['friendly_name']
end

#inspectObject

Provide a detailed, user friendly representation


504
505
506
507
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 504

def inspect
  values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ")
  "<Twilio.Insights.V1.ConferenceInstance #{values}>"
end

Returns Nested resource URLs.

Returns:

  • (String)

    Nested resource URLs.


477
478
479
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 477

def links
  @properties['links']
end

#max_concurrent_participantsString

Returns Actual maximum concurrent participants.

Returns:

  • (String)

    Actual maximum concurrent participants.


405
406
407
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 405

def max_concurrent_participants
  @properties['max_concurrent_participants']
end

#max_participantsString

Returns Max participants specified in config.

Returns:

  • (String)

    Max participants specified in config.


399
400
401
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 399

def max_participants
  @properties['max_participants']
end

#mixer_regionconference.Region

Returns Region where the conference was mixed.

Returns:

  • (conference.Region)

    Region where the conference was mixed.


429
430
431
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 429

def mixer_region
  @properties['mixer_region']
end

#mixer_region_requestedconference.Region

Returns Configuration-requested conference mixer region.

Returns:

  • (conference.Region)

    Configuration-requested conference mixer region.


435
436
437
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 435

def mixer_region_requested
  @properties['mixer_region_requested']
end

#processing_stateconference.ProcessingState

Returns Processing state for the Conference Summary resource.

Returns:

  • (conference.ProcessingState)

    Processing state for the Conference Summary resource.


465
466
467
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 465

def processing_state
  @properties['processing_state']
end

#recording_enabledBoolean

Returns Boolean. Indicates whether recording was enabled.

Returns:

  • (Boolean)

    Boolean. Indicates whether recording was enabled.


441
442
443
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 441

def recording_enabled
  @properties['recording_enabled']
end

#start_timeTime

Returns Timestamp in ISO 8601 format when the conference started.

Returns:

  • (Time)

    Timestamp in ISO 8601 format when the conference started.


369
370
371
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 369

def start_time
  @properties['start_time']
end

#statusconference.ConferenceStatus

Returns Status of conference.

Returns:

  • (conference.ConferenceStatus)

    Status of conference


393
394
395
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 393

def status
  @properties['status']
end

#tag_infoHash

Returns Object. Contains details about conference tags.

Returns:

  • (Hash)

    Object. Contains details about conference tags.


459
460
461
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 459

def tag_info
  @properties['tag_info']
end

#tagsArray[conference.Tag]

Returns Tags for detected conference conditions and participant behaviors.

Returns:

  • (Array[conference.Tag])

    Tags for detected conference conditions and participant behaviors.


453
454
455
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 453

def tags
  @properties['tags']
end

#to_sObject

Provide a user friendly representation


497
498
499
500
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 497

def to_s
  values = @params.map{|k, v| "#{k}: #{v}"}.join(" ")
  "<Twilio.Insights.V1.ConferenceInstance #{values}>"
end

#unique_participantsString

Returns Unique conference participants.

Returns:

  • (String)

    Unique conference participants.


411
412
413
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 411

def unique_participants
  @properties['unique_participants']
end

#urlString

Returns The URL of this resource.

Returns:

  • (String)

    The URL of this resource.


471
472
473
# File 'lib/twilio-ruby/rest/insights/v1/conference.rb', line 471

def url
  @properties['url']
end