Class: Twilio::REST::Conversations::V1::ParticipantConversationInstance

Inherits:
InstanceResource
  • Object
show all
Defined in:
lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ ParticipantConversationInstance

Initialize the ParticipantConversationInstance

Parameters:

  • version (Version) —

    Version that contains the resource

  • payload (Hash) —

    payload that contains response from Twilio



177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 177

def initialize(version, payload)
  super(version)

  # Marshaled Properties
  @properties = {
      'account_sid' => payload['account_sid'],
      'chat_service_sid' => payload['chat_service_sid'],
      'participant_sid' => payload['participant_sid'],
      'participant_user_sid' => payload['participant_user_sid'],
      'participant_identity' => payload['participant_identity'],
      'participant_messaging_binding' => payload['participant_messaging_binding'],
      'conversation_sid' => payload['conversation_sid'],
      'conversation_unique_name' => payload['conversation_unique_name'],
      'conversation_friendly_name' => payload['conversation_friendly_name'],
      'conversation_attributes' => payload['conversation_attributes'],
      'conversation_date_created' => Twilio.deserialize_iso8601_datetime(payload['conversation_date_created']),
      'conversation_date_updated' => Twilio.deserialize_iso8601_datetime(payload['conversation_date_updated']),
      'conversation_created_by' => payload['conversation_created_by'],
      'conversation_state' => payload['conversation_state'],
      'conversation_timers' => payload['conversation_timers'],
      'links' => payload['links'],
  }
end

Instance Method Details

#account_sid ⇒ String

Returns The unique ID of the Account responsible for this conversation.

Returns:

  • (String) —

    The unique ID of the Account responsible for this conversation.



203
204
205
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 203

def 
  @properties['account_sid']
end

#chat_service_sid ⇒ String

Returns The unique ID of the Conversation Service this conversation belongs to.

Returns:

  • (String) —

    The unique ID of the Conversation Service this conversation belongs to.



209
210
211
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 209

def chat_service_sid
  @properties['chat_service_sid']
end

#conversation_attributes ⇒ String

Returns An optional string metadata field you can use to store any data you wish.

Returns:

  • (String) —

    An optional string metadata field you can use to store any data you wish.



257
258
259
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 257

def conversation_attributes
  @properties['conversation_attributes']
end

#conversation_created_by ⇒ String

Returns Creator of this conversation.

Returns:

  • (String) —

    Creator of this conversation.



275
276
277
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 275

def conversation_created_by
  @properties['conversation_created_by']
end

#conversation_date_created ⇒ Time

Returns The date that this conversation was created.

Returns:

  • (Time) —

    The date that this conversation was created.



263
264
265
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 263

def conversation_date_created
  @properties['conversation_date_created']
end

#conversation_date_updated ⇒ Time

Returns The date that this conversation was last updated.

Returns:

  • (Time) —

    The date that this conversation was last updated.



269
270
271
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 269

def conversation_date_updated
  @properties['conversation_date_updated']
end

#conversation_friendly_name ⇒ String

Returns The human-readable name of this conversation.

Returns:

  • (String) —

    The human-readable name of this conversation.



251
252
253
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 251

def conversation_friendly_name
  @properties['conversation_friendly_name']
end

#conversation_sid ⇒ String

Returns The unique ID of the Conversation this Participant belongs to.

Returns:

  • (String) —

    The unique ID of the Conversation this Participant belongs to.



239
240
241
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 239

def conversation_sid
  @properties['conversation_sid']
end

#conversation_state ⇒ participant_conversation.State

Returns The current state of this User Conversation.

Returns:

  • (participant_conversation.State) —

    The current state of this User Conversation



281
282
283
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 281

def conversation_state
  @properties['conversation_state']
end

#conversation_timers ⇒ Hash

Returns Timer date values for this conversation.

Returns:

  • (Hash) —

    Timer date values for this conversation.



287
288
289
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 287

def conversation_timers
  @properties['conversation_timers']
end

#conversation_unique_name ⇒ String

Returns An application-defined string that uniquely identifies the Conversation resource.

Returns:

  • (String) —

    An application-defined string that uniquely identifies the Conversation resource



245
246
247
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 245

def conversation_unique_name
  @properties['conversation_unique_name']
end

#inspect ⇒ Object

Provide a detailed, user friendly representation



305
306
307
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 305

def inspect
  "<Twilio.Conversations.V1.ParticipantConversationInstance>"
end

Returns Absolute URLs to access the participant and conversation of this Participant Conversation.

Returns:

  • (String) —

    Absolute URLs to access the participant and conversation of this Participant Conversation.



293
294
295
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 293

def links
  @properties['links']
end

#participant_identity ⇒ String

Returns A unique string identifier for the conversation participant as Conversation User.

Returns:

  • (String) —

    A unique string identifier for the conversation participant as Conversation User.



227
228
229
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 227

def participant_identity
  @properties['participant_identity']
end

#participant_messaging_binding ⇒ Hash

Returns Information about how this participant exchanges messages with the conversation.

Returns:

  • (Hash) —

    Information about how this participant exchanges messages with the conversation.



233
234
235
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 233

def participant_messaging_binding
  @properties['participant_messaging_binding']
end

#participant_sid ⇒ String

Returns The unique ID of the Participant.

Returns:

  • (String) —

    The unique ID of the Participant.



215
216
217
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 215

def participant_sid
  @properties['participant_sid']
end

#participant_user_sid ⇒ String

Returns The unique ID for the conversation participant as Conversation User.

Returns:

  • (String) —

    The unique ID for the conversation participant as Conversation User.



221
222
223
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 221

def participant_user_sid
  @properties['participant_user_sid']
end

#to_s ⇒ Object

Provide a user friendly representation



299
300
301
# File 'lib/twilio-ruby/rest/conversations/v1/participant_conversation.rb', line 299

def to_s
  "<Twilio.Conversations.V1.ParticipantConversationInstance>"
end