class Vonage::Conversations::Events
Public Instance Methods
create(conversation_id, params)
click to toggle source
Create an event.
@option params [required, String] :type
Event type.
@option params [String] :to
Member ID.
@option params [required, String] :from
Member ID.
@option params [Hash] :body
Event Body.
@param [String] conversation_id @param [Hash] params
@return [Response]
@see developer.nexmo.com/api/conversation#createEvent
# File lib/vonage/conversations/events.rb, line 31 def create(conversation_id, params) request('/beta/conversations/' + conversation_id + '/events', params: params, type: Post) end
delete(conversation_id, event_id)
click to toggle source
Delete an event.
@param [String] conversation_id @param [String] event_id
@return [Response]
@see developer.nexmo.com/api/conversation#deleteEvent
# File lib/vonage/conversations/events.rb, line 73 def delete(conversation_id, event_id) request('/beta/conversations/' + conversation_id + '/events/' + event_id.to_s, type: Delete) end
get(conversation_id, event_id)
click to toggle source
Retrieve an event.
@param [String] conversation_id @param [String] event_id
@return [Response]
@see developer.nexmo.com/api/conversation#getEvent
# File lib/vonage/conversations/events.rb, line 60 def get(conversation_id, event_id) request('/beta/conversations/' + conversation_id + '/events/' + event_id.to_s) end
list(conversation_id, params = nil, auto_advance = true)
click to toggle source
List events.
@param [String] conversation_id
@option params [Boolean] :auto_advance
Set this to `false` to not auto-advance through all the pages in the record and collect all the data. The default is `true`.
@return [Response]
@see developer.nexmo.com/api/conversation#getEvents
# File lib/vonage/conversations/events.rb, line 47 def list(conversation_id, params = nil, auto_advance = true) request('/beta/conversations/' + conversation_id + '/events', params: params) end