Skip to main content

Update stored Dialogflow Connection

PUT 
/dialogflow_connections/:connection_id

Updates a stored Dialogflow Connection.

Request

Path Parameters

    connection_id stringrequired

    Uniquely identifies a Telnyx application (Call Control).

Body

required

The params expected to create/update a Dialogflow Connection for given connection_id.

    service_account objectrequired

    The JSON map to connect your Dialoglow account.

    dialogflow_api string

    Possible values: [cx, es]

    Default value: es

    Determin which Dialogflow will be used.

    conversation_profile_id string

    The id of a configured conversation profile on your Dialogflow account. (If you use Dialogflow CX, this param is required)

    location string

    The region of your agent is. (If you use Dialogflow CX, this param is required)

    environment string

    Which Dialogflow environment will be used.

Responses

200: Return details of the Dialogflow connection associated with the given CallControl connection.

default: Unexpected error.

Request samples


curl -L -X PUT 'https://api.telnyx.com/v2/dialogflow_connections/:connection_id' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"service_Account": "{\"type\":\"service_account\",\"project_id\":\"your-project-id\",\"private_key_id\":\"your-private-key\",\"private_key\":\"-----BEGIN PRIVATE KEY-----n-----END PRIVATE\",\"client_email\":\"example@example.com\",\"client_id\":\"your-client-id\",\"auth_uri\":\"http://example.com\",\"token_uri\":\"http://example.com\",\"auth_provider_x509_cert_url\":\"http://example.com\",\"client_x509_cert_url\":\"http://example.com\"}",
"dialogflow_api": "cx",
"conversation_profile_id": "a-VMHLWzTmKjiJw5S6O0-w",
"location": "global",
"environment": "development"
}'

Response samples


{
"data": {
"record_type": "dialogflow_connections",
"connection_id": "1234541231",
"conversation_profile_id": "a-VMHLWzTmKjiJw5S6O0-w",
"environment": "development",
"service_account": "****"
}
}