Class: Twilio::REST::Pricing::V1::MessagingInstance

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

Instance Method Summary collapse

Constructor Details

#initialize(version, payload) ⇒ MessagingInstance

Initialize the MessagingInstance

Parameters:

  • version (Version)

    Version that contains the resource

  • payload (Hash)

    payload that contains response from Twilio



85
86
87
88
89
90
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 85

def initialize(version, payload)
  super(version)

  # Marshaled Properties
  @properties = {'name' => payload['name'], 'url' => payload['url'], 'links' => payload['links'], }
end

Instance Method Details

#inspectObject

Provide a detailed, user friendly representation



118
119
120
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 118

def inspect
  "<Twilio.Pricing.V1.MessagingInstance>"
end

Returns The links.

Returns:

  • (String)

    The links



106
107
108
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 106

def links
  @properties['links']
end

#nameString

Returns The name.

Returns:

  • (String)

    The name



94
95
96
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 94

def name
  @properties['name']
end

#to_sObject

Provide a user friendly representation



112
113
114
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 112

def to_s
  "<Twilio.Pricing.V1.MessagingInstance>"
end

#urlString

Returns The url.

Returns:

  • (String)

    The url



100
101
102
# File 'lib/twilio-ruby/rest/pricing/v1/messaging.rb', line 100

def url
  @properties['url']
end