Each of these examples shows the HTTP request and the response from the Call Setup API in each of the scenarios.

Example 1: Get the status of a call that is scheduled to start in the future

HTTP Request

GET /call/2.0/NND4QvEgFlltU0ObJtGbgGRfO4X/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{“sessionid”:”NND4QvEgFlltU0ObJtGbgGRfO4X”,”callState”:”scheduled”, "time":"2013-07-25 4:35:50","scheduledTime":"2013-07-29 16:30:00",“more”:”no”,”hasChanged”:”yes”}

Example 2: Get the status of a call that is in the process of starting

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{"sessionid":"NND4QvEgFlltU0ObJtGbgGRfO4X","callState":"unknown", "more":"maybe","hasChanged":"yes"}

Example 3: Get the status of a call that has now started

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{“sessionid”:”1TfU02Xfme2GMuzfUh0rkdgvz4”,”callState”:”initiated”,”time”:” 1343129570”,”more”:”yes”, “hasChanged”:”yes”}

Example 4: Get the status of a call that has now connected

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{“sessionid”:”1TfU02Xfme2GMuzfUh0rkdgvz4”,”callState”:”connected”,”time”:” 1343129590”,”more”:”yes”, “hasChanged”:”yes”}

Example 5: Get the status of a call where the current state is still connected

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{“sessionid”:”1TfU02Xfme2GMuzfUh0rkdgvz4”,”callState”:”connected”,”time”:” 1343129590”,”more”:”yes”, “hasChanged”:”no”}

Example 6: Get the status of a call that has now ended

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

200 OK

Response Content Type

application/json

Response Body

{“sessionid”:”1TfU02Xfme2GMuzfUh0rkdgvz4”,”callState”:”disconnected”,”time”:”1343129630”,”more”:”no”, “hasChanged”:”yes”}

Example 7: Get the status of a call whose session token has expired

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

404 Not Found

Response Content Type

text/plain

Response Body

Call session no longer exists because it has ended

Example 8: Request with an invalid URI path

In this example, the Get Call Status request is missing part of the URI.

HTTP Request

GET /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4

The response should be:

Response Status

404 Not Found

Example 9: Invalid HTTP method

In this example, the wrong HTTP method is used in the Get Call Status request.

HTTP Request

PUT /call/2.0/1TfU02Xfme2GMuzfUh0rkdgvz4/status

The response should be:

Response Status

405 Method Not Allowed


Copyright © 1997, 2016 Oracle and/or its affiliates. All rights reserved. Legal Notices