Class: Telnyx::Resources::Porting::Events
- Inherits:
-
Object
- Object
- Telnyx::Resources::Porting::Events
- Defined in:
- lib/telnyx/resources/porting/events.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ Events
constructor
private
A new instance of Events.
-
#list(filter: nil, page_number: nil, page_size: nil, request_options: {}) ⇒ Telnyx::Internal::DefaultFlatPagination<Telnyx::Models::Porting::EventListResponse::PortingEventDeletedPayload, Telnyx::Models::Porting::EventListResponse::PortingEventMessagingChangedPayload, Telnyx::Models::Porting::EventListResponse::PortingEventStatusChangedEvent, Telnyx::Models::Porting::EventListResponse::PortingEventNewCommentEvent, Telnyx::Models::Porting::EventListResponse::PortingEventSplitEvent, Telnyx::Models::Porting::EventListResponse::PortingEventWithoutWebhook>
Some parameter documentations has been truncated, see Models::Porting::EventListParams for more details.
-
#republish(id, request_options: {}) ⇒ nil
Republish a specific porting event.
-
#retrieve(id, request_options: {}) ⇒ Telnyx::Models::Porting::EventRetrieveResponse
Show a specific porting event.
Constructor Details
#initialize(client:) ⇒ Events
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 Events.
80 81 82 |
# File 'lib/telnyx/resources/porting/events.rb', line 80 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::Porting::EventListResponse::PortingEventDeletedPayload, Telnyx::Models::Porting::EventListResponse::PortingEventMessagingChangedPayload, Telnyx::Models::Porting::EventListResponse::PortingEventStatusChangedEvent, Telnyx::Models::Porting::EventListResponse::PortingEventNewCommentEvent, Telnyx::Models::Porting::EventListResponse::PortingEventSplitEvent, Telnyx::Models::Porting::EventListResponse::PortingEventWithoutWebhook>
Some parameter documentations has been truncated, see Models::Porting::EventListParams for more details.
Returns a list of all porting events.
45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/telnyx/resources/porting/events.rb', line 45 def list(params = {}) parsed, = Telnyx::Porting::EventListParams.dump_request(params) @client.request( method: :get, path: "porting/events", query: parsed.transform_keys(page_number: "page[number]", page_size: "page[size]"), page: Telnyx::Internal::DefaultFlatPagination, model: Telnyx::Models::Porting::EventListResponse, options: ) end |
#republish(id, request_options: {}) ⇒ nil
Republish a specific porting event.
68 69 70 71 72 73 74 75 |
# File 'lib/telnyx/resources/porting/events.rb', line 68 def republish(id, params = {}) @client.request( method: :post, path: ["porting/events/%1$s/republish", id], model: NilClass, options: params[:request_options] ) end |
#retrieve(id, request_options: {}) ⇒ Telnyx::Models::Porting::EventRetrieveResponse
Show a specific porting event.
18 19 20 21 22 23 24 25 |
# File 'lib/telnyx/resources/porting/events.rb', line 18 def retrieve(id, params = {}) @client.request( method: :get, path: ["porting/events/%1$s", id], model: Telnyx::Models::Porting::EventRetrieveResponse, options: params[:request_options] ) end |