Class: Telnyx::Resources::PortingPhoneNumbers
- Inherits:
-
Object
- Object
- Telnyx::Resources::PortingPhoneNumbers
- Defined in:
- lib/telnyx/resources/porting_phone_numbers.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ PortingPhoneNumbers
constructor
private
A new instance of PortingPhoneNumbers.
-
#list(filter: nil, page_number: nil, page_size: nil, request_options: {}) ⇒ Telnyx::Internal::DefaultFlatPagination<Telnyx::Models::PortingPhoneNumberListResponse>
Some parameter documentations has been truncated, see Models::PortingPhoneNumberListParams for more details.
Constructor Details
#initialize(client:) ⇒ PortingPhoneNumbers
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of PortingPhoneNumbers.
39 40 41 |
# File 'lib/telnyx/resources/porting_phone_numbers.rb', line 39 def initialize(client:) @client = client end |
Instance Method Details
#list(filter: nil, page_number: nil, page_size: nil, request_options: {}) ⇒ Telnyx::Internal::DefaultFlatPagination<Telnyx::Models::PortingPhoneNumberListResponse>
Some parameter documentations has been truncated, see Models::PortingPhoneNumberListParams for more details.
Returns a list of your porting phone numbers.
24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/telnyx/resources/porting_phone_numbers.rb', line 24 def list(params = {}) parsed, = Telnyx::PortingPhoneNumberListParams.dump_request(params) @client.request( method: :get, path: "porting_phone_numbers", query: parsed.transform_keys(page_number: "page[number]", page_size: "page[size]"), page: Telnyx::Internal::DefaultFlatPagination, model: Telnyx::Models::PortingPhoneNumberListResponse, options: ) end |