Web callback

The module ‚webcallback‘ connects two callees via web callback. Therefore the phone numbers of subscriber A and B have to be transferred to the module. The function call is really simple, the parameters are shown below.

POST /api/rest/v2/?webcallback

POST data:

{
"act": "trycallback",	
"aNumber": "0302434299",
"bNumber": "0302434299"
}

Request Headers:

Connection: keep-alive
x-date: 2014-02-20 18:56:08.000000 GMT+0000
x-authorization: demo:wZdTynO6NdgwCnkMMOp73Lac4n4=
Content-Type: application/x-www-form-urlencoded
Content-Length: 86
Host: login.42call.com

Response Body:

{
    "error": false,
    "codes": [
        {
            "code": 200,
            "description": "OK"
        }
    ],
    "body": {
        "callId": "4AF46744-C346-44FF-80E3-33D89FBE963B",
        "firstownnumber": null,
        "destinationnumber": null,
        "customernumber": "1234",
        "accountnumber": "1234",
        "username": "demo",
        "customercurrency": "eur",
        "customeraccountstate": "18,40"
    }
}

The parameter ‚act‘ describes the current command. In this example the callback is initiated.
An active call could be cutted at any time by passing over stopcallback. For identifying a specific call you need to transmit the callerId in your request.