Class: VoiceTel::Resources::Support
- Inherits:
-
Base
- Object
- Base
- VoiceTel::Resources::Support
show all
- Defined in:
- lib/voicetel/resources/support.rb
Overview
SupportService — support tickets (create, read, update, delete, reply).
On the wire, SupportConversation.number is a ticket sequence integer (1015, 2114, …), NOT a phone number. When the spec uses ‘number` in this context, that’s the ticket id.
Instance Method Summary
collapse
Methods inherited from Base
#compact_query, #initialize
Instance Method Details
#create(body) ⇒ Object
17
18
19
|
# File 'lib/voicetel/resources/support.rb', line 17
def create(body)
@transport.request(:post, "/v2.2/support/tickets", body: body)
end
|
#delete(id) ⇒ Object
Returns nil on 204 No Content.
30
31
32
|
# File 'lib/voicetel/resources/support.rb', line 30
def delete(id)
@transport.request(:delete, "/v2.2/support/tickets/#{id}")
end
|
#get(id) ⇒ Object
21
22
23
|
# File 'lib/voicetel/resources/support.rb', line 21
def get(id)
@transport.request(:get, "/v2.2/support/tickets/#{id}")
end
|
#list ⇒ Object
13
14
15
|
# File 'lib/voicetel/resources/support.rb', line 13
def list
@transport.request(:get, "/v2.2/support/tickets")
end
|
#messages(id) ⇒ Object
34
35
36
|
# File 'lib/voicetel/resources/support.rb', line 34
def messages(id)
@transport.request(:get, "/v2.2/support/tickets/#{id}/messages")
end
|
#reply(id, body) ⇒ Object
38
39
40
|
# File 'lib/voicetel/resources/support.rb', line 38
def reply(id, body)
@transport.request(:post, "/v2.2/support/tickets/#{id}/replies", body: body)
end
|
#update(id, body) ⇒ Object
25
26
27
|
# File 'lib/voicetel/resources/support.rb', line 25
def update(id, body)
@transport.request(:put, "/v2.2/support/tickets/#{id}", body: body)
end
|