Introduction

Voice Agent with Watson provides a Outbound calls that can be made via a REST API to Session Initiation Protocol (i.e., sip or tel) URIs. This feature could be used for robo-calling or for a testing bot that could drive various dialogs. Users of the REST API can monitor the call to completion.

Authentication

IBM Cloud uses token-based Identity and Access Management (IAM) authentication.

With Voice Agent with Watson, you authenticate to the API by using IAM API key. The username should be "apikey" and use the API key value in your service credentials as the password.

IAM authentication. Replace {variable} with the API key value in your service credentials.

curl -u "apikey:{variable}" -X {request_method}  "url"

Service endpoint

  • https://gateway.voiceagent.cloud.ibm.com
  • https://gateway-wdc.voiceagent.cloud.ibm.com

US East endpoint example. Replace {variable} with the API key value in your service credentials.

curl -u "apikey:{variable}" -X {request_method} "https://gateway.voiceagent.cloud.ibm.com"

Error handling

This API uses standard HTTP response codes to indicate whether a method completed successfully. Check out the following table for a general description of each error type.

HTTP Status Code Response Model
200 vgwSessionID
400 Bad Request
403 Forbidden
404 Not Found

Methods

Initiating an outbound call

Initiating an outbound call using the cURL commands

POST /vgw/outboundCalls//startOutboundCall
Request

Sends the following key-value pairs in a JSON object.

Response

Status Code

  • Outbound calling session created successfully.

No Sample Response

This method does not specify any sample responses.