Class: VoiceML::PricingResource

Inherits:
Object
  • Object
show all
Defined in:
lib/voiceml/resources/pricing.rb

Overview

client.pricing — Twilio Pricing v1/v2 (pricing.twilio.com) surface.

Read-only. Served on the default host (VoiceML has no pricing subdomain). Layout:

client.pricing.v1.voice.countries.list / fetch
client.pricing.v1.voice.numbers.fetch
client.pricing.v1.messaging.countries.list / fetch
client.pricing.v1.phone_numbers.countries.list / fetch
client.pricing.v2.voice.countries.list / fetch
client.pricing.v2.voice.numbers.fetch
client.pricing.v2.trunking.countries.list / fetch
client.pricing.v2.trunking.numbers.fetch

Every countries.list returns the shared PricingCountriesList envelope; fetch returns the product-specific country/number body. Number path segments are URL-encoded (E.164 + -> %2B).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(transport) ⇒ PricingResource

Returns a new instance of PricingResource.



27
28
29
30
# File 'lib/voiceml/resources/pricing.rb', line 27

def initialize(transport)
  @v1 = PricingV1Resource.new(transport)
  @v2 = PricingV2Resource.new(transport)
end

Instance Attribute Details

#v1Object (readonly)

Returns the value of attribute v1.



25
26
27
# File 'lib/voiceml/resources/pricing.rb', line 25

def v1
  @v1
end

#v2Object (readonly)

Returns the value of attribute v2.



25
26
27
# File 'lib/voiceml/resources/pricing.rb', line 25

def v2
  @v2
end