Class: SevenApi::Resources::Voice
- Inherits:
-
SevenApi::Resource
- Object
- SevenApi::Resource
- SevenApi::Resources::Voice
- Defined in:
- lib/seven_api/resources/voice.rb
Constant Summary
Constants inherited from SevenApi::Resource
Instance Attribute Summary
Attributes inherited from SevenApi::Resource
#api_key, #builder, #conn, #endpoint, #http_methods, #request_methods, #sent_with
Instance Method Summary collapse
-
#hangup(call_id) ⇒ Object
This endpoint ends an active call.
-
#send(params) ⇒ String, Hash
Convert text to speech, call number and read voice message out loud.
Methods inherited from SevenApi::Resource
get_endpoint, get_http_methods, #initialize
Constructor Details
This class inherits a constructor from SevenApi::Resource
Instance Method Details
#hangup(call_id) ⇒ Object
This endpoint ends an active call. Only calls with the status in-progress can be ended. read more: docs.seven.io/en/rest-api/endpoints/voice#hangup-a-call
18 19 20 |
# File 'lib/seven_api/resources/voice.rb', line 18 def hangup(call_id) request(:post, {}, {}, "/#{call_id}/hangup") end |
#send(params) ⇒ String, Hash
Convert text to speech, call number and read voice message out loud. read more: docs.seven.io/en/rest-api/endpoints/voice#send-voice-call
26 27 28 |
# File 'lib/seven_api/resources/voice.rb', line 26 def send(params) request(:post, params) end |