Class: Twilio::REST::Messaging::V1::UsecaseInstance

Inherits:
InstanceResource show all
Defined in:
lib/twilio-ruby/rest/messaging/v1/usecase.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ UsecaseInstance

Initialize the UsecaseInstance

Parameters:

  • version (Version) —

    Version that contains the resource

  • payload (Hash) —

    payload that contains response from Twilio

  • account_sid (String) —

    The SID of the Account that created this Usecase resource.

  • sid (String) —

    The SID of the Call resource to fetch.



125
126
127
128
129
130
131
132
133
# File 'lib/twilio-ruby/rest/messaging/v1/usecase.rb', line 125

def initialize(version, payload )
    super(version)
    
    
    # Marshaled Properties
    @properties = { 
        'usecases' => payload['usecases'],
    }
end

Instance Method Details

#inspect ⇒ Object

Provide a detailed, user friendly representation



150
151
152
# File 'lib/twilio-ruby/rest/messaging/v1/usecase.rb', line 150

def inspect
    "<Twilio.Messaging.V1.UsecaseInstance>"
end

#to_s ⇒ Object

Provide a user friendly representation



144
145
146
# File 'lib/twilio-ruby/rest/messaging/v1/usecase.rb', line 144

def to_s
    "<Twilio.Messaging.V1.UsecaseInstance>"
end

#usecases ⇒ Array<Hash>

Returns Human readable use case details (usecase, description and purpose) of Messaging Service Use Cases.

Returns:

  • (Array<Hash>) —

    Human readable use case details (usecase, description and purpose) of Messaging Service Use Cases.



138
139
140
# File 'lib/twilio-ruby/rest/messaging/v1/usecase.rb', line 138

def usecases
    @properties['usecases']
end