Package com.bandwidth.sdk.api
Class CallsApi
- java.lang.Object
-
- com.bandwidth.sdk.api.CallsApi
-
public class CallsApi extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateCallResponse
createCall(String accountId, CreateCall createCall)
Create Call Creates an outbound phone call.okhttp3.Call
createCallAsync(String accountId, CreateCall createCall, ApiCallback<CreateCallResponse> _callback)
Create Call (asynchronously) Creates an outbound phone call.okhttp3.Call
createCallCall(String accountId, CreateCall createCall, ApiCallback _callback)
Build call for createCallApiResponse<CreateCallResponse>
createCallWithHttpInfo(String accountId, CreateCall createCall)
Create Call Creates an outbound phone call.ApiClient
getApiClient()
CallState
getCallState(String accountId, String callId)
Get Call State Information Retrieve the current state of a specific call.okhttp3.Call
getCallStateAsync(String accountId, String callId, ApiCallback<CallState> _callback)
Get Call State Information (asynchronously) Retrieve the current state of a specific call.okhttp3.Call
getCallStateCall(String accountId, String callId, ApiCallback _callback)
Build call for getCallStateApiResponse<CallState>
getCallStateWithHttpInfo(String accountId, String callId)
Get Call State Information Retrieve the current state of a specific call.String
getCustomBaseUrl()
int
getHostIndex()
void
setApiClient(ApiClient apiClient)
void
setCustomBaseUrl(String customBaseUrl)
void
setHostIndex(int hostIndex)
void
updateCall(String accountId, String callId, UpdateCall updateCall)
Update Call Interrupts and redirects a call to a different URL that should return a BXML document.okhttp3.Call
updateCallAsync(String accountId, String callId, UpdateCall updateCall, ApiCallback<Void> _callback)
Update Call (asynchronously) Interrupts and redirects a call to a different URL that should return a BXML document.void
updateCallBxml(String accountId, String callId, String body)
Update Call BXML Interrupts and replaces an active call's BXML document.okhttp3.Call
updateCallBxmlAsync(String accountId, String callId, String body, ApiCallback<Void> _callback)
Update Call BXML (asynchronously) Interrupts and replaces an active call's BXML document.okhttp3.Call
updateCallBxmlCall(String accountId, String callId, String body, ApiCallback _callback)
Build call for updateCallBxmlApiResponse<Void>
updateCallBxmlWithHttpInfo(String accountId, String callId, String body)
Update Call BXML Interrupts and replaces an active call's BXML document.okhttp3.Call
updateCallCall(String accountId, String callId, UpdateCall updateCall, ApiCallback _callback)
Build call for updateCallApiResponse<Void>
updateCallWithHttpInfo(String accountId, String callId, UpdateCall updateCall)
Update Call Interrupts and redirects a call to a different URL that should return a BXML document.
-
-
-
Constructor Detail
-
CallsApi
public CallsApi()
-
CallsApi
public CallsApi(ApiClient apiClient)
-
-
Method Detail
-
getApiClient
public ApiClient getApiClient()
-
setApiClient
public void setApiClient(ApiClient apiClient)
-
getHostIndex
public int getHostIndex()
-
setHostIndex
public void setHostIndex(int hostIndex)
-
getCustomBaseUrl
public String getCustomBaseUrl()
-
setCustomBaseUrl
public void setCustomBaseUrl(String customBaseUrl)
-
createCallCall
public okhttp3.Call createCallCall(String accountId, CreateCall createCall, ApiCallback _callback) throws ApiException
Build call for createCall- Parameters:
accountId
- Your Bandwidth Account ID. (required)createCall
- JSON object containing information to create an outbound call (required)_callback
- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException
- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 201 Call Successfully Created * Location - The URL for further interactions with this call
400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
createCall
public CreateCallResponse createCall(String accountId, CreateCall createCall) throws ApiException
Create Call Creates an outbound phone call. All calls are initially queued. Your outbound calls will initiated at a specific dequeueing rate, enabling your application to \"fire and forget\" when creating calls. Queued calls may not be modified until they are dequeued and placed, but may be removed from your queue on demand. <b>Please note:</b> Calls submitted to your queue will be placed approximately in order, but exact ordering is not guaranteed.- Parameters:
accountId
- Your Bandwidth Account ID. (required)createCall
- JSON object containing information to create an outbound call (required)- Returns:
- CreateCallResponse
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 201 Call Successfully Created * Location - The URL for further interactions with this call
400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
createCallWithHttpInfo
public ApiResponse<CreateCallResponse> createCallWithHttpInfo(String accountId, CreateCall createCall) throws ApiException
Create Call Creates an outbound phone call. All calls are initially queued. Your outbound calls will initiated at a specific dequeueing rate, enabling your application to \"fire and forget\" when creating calls. Queued calls may not be modified until they are dequeued and placed, but may be removed from your queue on demand. <b>Please note:</b> Calls submitted to your queue will be placed approximately in order, but exact ordering is not guaranteed.- Parameters:
accountId
- Your Bandwidth Account ID. (required)createCall
- JSON object containing information to create an outbound call (required)- Returns:
- ApiResponse<CreateCallResponse>
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 201 Call Successfully Created * Location - The URL for further interactions with this call
400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
createCallAsync
public okhttp3.Call createCallAsync(String accountId, CreateCall createCall, ApiCallback<CreateCallResponse> _callback) throws ApiException
Create Call (asynchronously) Creates an outbound phone call. All calls are initially queued. Your outbound calls will initiated at a specific dequeueing rate, enabling your application to \"fire and forget\" when creating calls. Queued calls may not be modified until they are dequeued and placed, but may be removed from your queue on demand. <b>Please note:</b> Calls submitted to your queue will be placed approximately in order, but exact ordering is not guaranteed.- Parameters:
accountId
- Your Bandwidth Account ID. (required)createCall
- JSON object containing information to create an outbound call (required)_callback
- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException
- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 201 Call Successfully Created * Location - The URL for further interactions with this call
400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
getCallStateCall
public okhttp3.Call getCallStateCall(String accountId, String callId, ApiCallback _callback) throws ApiException
Build call for getCallState- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)_callback
- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException
- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 Call found - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
getCallState
public CallState getCallState(String accountId, String callId) throws ApiException
Get Call State Information Retrieve the current state of a specific call. This information is near-realtime, so it may take a few minutes for your call to be accessible using this endpoint. **Note**: Call information is kept for 7 days after the calls are hung up. If you attempt to retrieve information for a call that is older than 7 days, you will get an HTTP 404 response.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)- Returns:
- CallState
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 Call found - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
getCallStateWithHttpInfo
public ApiResponse<CallState> getCallStateWithHttpInfo(String accountId, String callId) throws ApiException
Get Call State Information Retrieve the current state of a specific call. This information is near-realtime, so it may take a few minutes for your call to be accessible using this endpoint. **Note**: Call information is kept for 7 days after the calls are hung up. If you attempt to retrieve information for a call that is older than 7 days, you will get an HTTP 404 response.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)- Returns:
- ApiResponse<CallState>
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 Call found - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
getCallStateAsync
public okhttp3.Call getCallStateAsync(String accountId, String callId, ApiCallback<CallState> _callback) throws ApiException
Get Call State Information (asynchronously) Retrieve the current state of a specific call. This information is near-realtime, so it may take a few minutes for your call to be accessible using this endpoint. **Note**: Call information is kept for 7 days after the calls are hung up. If you attempt to retrieve information for a call that is older than 7 days, you will get an HTTP 404 response.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)_callback
- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException
- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 Call found - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallCall
public okhttp3.Call updateCallCall(String accountId, String callId, UpdateCall updateCall, ApiCallback _callback) throws ApiException
Build call for updateCall- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)updateCall
- JSON object containing information to redirect an existing call to a new BXML document (required)_callback
- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException
- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 200 Call was successfully modified. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCall
public void updateCall(String accountId, String callId, UpdateCall updateCall) throws ApiException
Update Call Interrupts and redirects a call to a different URL that should return a BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)updateCall
- JSON object containing information to redirect an existing call to a new BXML document (required)- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 Call was successfully modified. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallWithHttpInfo
public ApiResponse<Void> updateCallWithHttpInfo(String accountId, String callId, UpdateCall updateCall) throws ApiException
Update Call Interrupts and redirects a call to a different URL that should return a BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)updateCall
- JSON object containing information to redirect an existing call to a new BXML document (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 200 Call was successfully modified. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallAsync
public okhttp3.Call updateCallAsync(String accountId, String callId, UpdateCall updateCall, ApiCallback<Void> _callback) throws ApiException
Update Call (asynchronously) Interrupts and redirects a call to a different URL that should return a BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)updateCall
- JSON object containing information to redirect an existing call to a new BXML document (required)_callback
- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException
- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 200 Call was successfully modified. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallBxmlCall
public okhttp3.Call updateCallBxmlCall(String accountId, String callId, String body, ApiCallback _callback) throws ApiException
Build call for updateCallBxml- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)body
- (required)_callback
- Callback for upload/download progress- Returns:
- Call to execute
- Throws:
ApiException
- If fail to serialize the request body object- Http Response Details:
Status Code Description Response Headers 204 Call BXML was successfully replaced. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallBxml
public void updateCallBxml(String accountId, String callId, String body) throws ApiException
Update Call BXML Interrupts and replaces an active call's BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)body
- (required)- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Call BXML was successfully replaced. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallBxmlWithHttpInfo
public ApiResponse<Void> updateCallBxmlWithHttpInfo(String accountId, String callId, String body) throws ApiException
Update Call BXML Interrupts and replaces an active call's BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)body
- (required)- Returns:
- ApiResponse<Void>
- Throws:
ApiException
- If fail to call the API, e.g. server error or cannot deserialize the response body- Http Response Details:
Status Code Description Response Headers 204 Call BXML was successfully replaced. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
updateCallBxmlAsync
public okhttp3.Call updateCallBxmlAsync(String accountId, String callId, String body, ApiCallback<Void> _callback) throws ApiException
Update Call BXML (asynchronously) Interrupts and replaces an active call's BXML document.- Parameters:
accountId
- Your Bandwidth Account ID. (required)callId
- Programmable Voice API Call ID. (required)body
- (required)_callback
- The callback to be executed when the API call finishes- Returns:
- The request call
- Throws:
ApiException
- If fail to process the API call, e.g. serializing the request body object- Http Response Details:
Status Code Description Response Headers 204 Call BXML was successfully replaced. - 400 Bad Request - 401 Unauthorized - 403 Forbidden - 404 Not Found - 405 Method Not Allowed - 409 Conflict - 415 Unsupported Media Type - 429 Too Many Requests * Retry-After - When you should try your request again.
500 Internal Server Error -
-
-