lib/ucpaas/call.rb in ucpaas-0.1.3 vs lib/ucpaas/call.rb in ucpaas-0.1.4

- old
+ new

@@ -3,14 +3,16 @@ module Call def dull_call(app_id, from_number, to_number, options = {}) client = find_or_create_client(app_id, from_number) client_number = client['clientNumber'] data = { - appId: app_id, - fromClient: client_number, - to: to_number - }.merge(options) - response = post('/Calls/callBack', data) + callback: { + appId: app_id, + fromClient: client_number, + to: to_number + }.merge(options) + } + response = post('/Calls/callBack.json', data) response['resp']['callback'] end private end