Module: YunTongXun::Voice

Extended by:
Helper
Defined in:
lib/yuntongxun_api/voice.rb

Class Method Summary collapse

Methods included from Helper

get_response

Class Method Details

.cancel_call(params) ⇒ Object

取消回拨



25
26
27
28
29
30
31
# File 'lib/yuntongxun_api/voice.rb', line 25

def cancel_call(params)
  @accounts = 'Accounts'
  @method   = 'Calls/CallCancel'
  params[:appId] = params[:appId] || YunTongXun.config.app_id

  response = get_response(params)
end

.double_call(params) ⇒ Object

电话回拨



17
18
19
20
21
22
# File 'lib/yuntongxun_api/voice.rb', line 17

def double_call(params)
  @accounts = 'SubAccounts'
  @method   = 'Calls/Callback'

  response = get_response(params)
end

.landing_call(params) ⇒ Object

外呼通知



34
35
36
37
38
39
40
# File 'lib/yuntongxun_api/voice.rb', line 34

def landing_call(params)
  @accounts = 'Accounts'
  @method   = 'Calls/LandingCalls'
  params[:appId] = params[:appId] || YunTongXun.config.app_id

  response = get_response(params)
end

.voice_verify(params) ⇒ Object

语音验证



8
9
10
11
12
13
14
# File 'lib/yuntongxun_api/voice.rb', line 8

def voice_verify(params)
  @accounts = 'Accounts'
  @method   = 'Calls/VoiceVerify'
  params[:appId] = params[:appId] || YunTongXun.config.app_id

  response = get_response(params)
end