Class: Twilio::REST::Numbers::V2::BulkHostedNumberOrderList

Inherits:
ListResource
  • Object
show all
Defined in:
lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb

Instance Method Summary collapse

Constructor Details

#initialize(version) ⇒ BulkHostedNumberOrderList

Initialize the BulkHostedNumberOrderList

Parameters:

  • version (Version)

    Version that contains the resource



26
27
28
29
30
31
32
# File 'lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb', line 26

def initialize(version)
    super(version)
    # Path Solution
    @solution = {  }
    @uri = "/HostedNumber/Orders/Bulk"
    
end

Instance Method Details

#create(body: :unset) ⇒ BulkHostedNumberOrderInstance

Create the BulkHostedNumberOrderInstance

Parameters:

  • body (Object) (defaults to: :unset)

Returns:



37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# File 'lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb', line 37

def create(body: :unset
)

    headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', })
    headers['Content-Type'] = 'application/json'
    
    
    
    
    payload = @version.create('POST', @uri, headers: headers, data: body.to_json)
    BulkHostedNumberOrderInstance.new(
        @version,
        payload,
    )
end

#to_sObject

Provide a user friendly representation



57
58
59
# File 'lib/twilio-ruby/rest/numbers/v2/bulk_hosted_number_order.rb', line 57

def to_s
    '#<Twilio.Numbers.V2.BulkHostedNumberOrderList>'
end