All URIs are relative to https://api.telnyx.com/v2
Method | HTTP request | Description |
---|---|---|
createDialogflowConnection | POST /dialogflow_connections/{connection_id} | Create a Dialogflow Connection |
deleteDialogflowConnection | DELETE /dialogflow_connections/{connection_id} | Delete stored Dialogflow Connection |
getDialogflowConnection | GET /dialogflow_connections/{connection_id} | Retrieve stored Dialogflow Connection |
updateDialogflowConnection | PUT /dialogflow_connections/{connection_id} | Update stored Dialogflow Connection |
DialogflowConnectionResponse createDialogflowConnection(connectionId, dialogflowConnection)
Create a Dialogflow Connection
Save Dialogflow Credentiails to Telnyx, so it can be used with other Telnyx services.
// Import classes:
import com.telnyx.sdk.ApiClient;
import com.telnyx.sdk.ApiException;
import com.telnyx.sdk.Configuration;
import com.telnyx.sdk.auth.*;
import com.telnyx.sdk.model.*;
import com.telnyx.sdk.api.DialogflowIntegrationApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.telnyx.com/v2");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
DialogflowIntegrationApi apiInstance = new DialogflowIntegrationApi(defaultClient);
String connectionId = "connectionId_example"; // String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource.
DialogflowConnection dialogflowConnection = new DialogflowConnection(); // DialogflowConnection | The params expected to create/update a Dialogflow Connection for given connection_id.
try {
DialogflowConnectionResponse result = apiInstance.createDialogflowConnection(connectionId, dialogflowConnection);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DialogflowIntegrationApi#createDialogflowConnection");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
connectionId | String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource. | |
dialogflowConnection | DialogflowConnection | The params expected to create/update a Dialogflow Connection for given connection_id. |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
201 | Return details of the Dialogflow connection associated with the given CallControl connection. | - |
0 | Unexpected error | - |
deleteDialogflowConnection(connectionId)
Delete stored Dialogflow Connection
Deletes a stored Dialogflow Connection.
// Import classes:
import com.telnyx.sdk.ApiClient;
import com.telnyx.sdk.ApiException;
import com.telnyx.sdk.Configuration;
import com.telnyx.sdk.auth.*;
import com.telnyx.sdk.model.*;
import com.telnyx.sdk.api.DialogflowIntegrationApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.telnyx.com/v2");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
DialogflowIntegrationApi apiInstance = new DialogflowIntegrationApi(defaultClient);
String connectionId = "connectionId_example"; // String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource.
try {
apiInstance.deleteDialogflowConnection(connectionId);
} catch (ApiException e) {
System.err.println("Exception when calling DialogflowIntegrationApi#deleteDialogflowConnection");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
connectionId | String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource. |
null (empty response body)
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
204 | The Dialogflow Connection for connection_id was deleted successfully. | - |
0 | Unexpected error | - |
DialogflowConnectionResponse getDialogflowConnection(connectionId)
Retrieve stored Dialogflow Connection
Return details of the Dialogflow connection associated with the given CallControl connection.
// Import classes:
import com.telnyx.sdk.ApiClient;
import com.telnyx.sdk.ApiException;
import com.telnyx.sdk.Configuration;
import com.telnyx.sdk.auth.*;
import com.telnyx.sdk.model.*;
import com.telnyx.sdk.api.DialogflowIntegrationApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.telnyx.com/v2");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
DialogflowIntegrationApi apiInstance = new DialogflowIntegrationApi(defaultClient);
String connectionId = "connectionId_example"; // String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource.
try {
DialogflowConnectionResponse result = apiInstance.getDialogflowConnection(connectionId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DialogflowIntegrationApi#getDialogflowConnection");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
connectionId | String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource. |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Return details of the Dialogflow connection associated with the given CallControl connection. | - |
0 | Unexpected error | - |
DialogflowConnectionResponse updateDialogflowConnection(connectionId, dialogflowConnection)
Update stored Dialogflow Connection
Updates a stored Dialogflow Connection.
// Import classes:
import com.telnyx.sdk.ApiClient;
import com.telnyx.sdk.ApiException;
import com.telnyx.sdk.Configuration;
import com.telnyx.sdk.auth.*;
import com.telnyx.sdk.model.*;
import com.telnyx.sdk.api.DialogflowIntegrationApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.telnyx.com/v2");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
DialogflowIntegrationApi apiInstance = new DialogflowIntegrationApi(defaultClient);
String connectionId = "connectionId_example"; // String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource.
DialogflowConnection dialogflowConnection = new DialogflowConnection(); // DialogflowConnection | The params expected to create/update a Dialogflow Connection for given connection_id.
try {
DialogflowConnectionResponse result = apiInstance.updateDialogflowConnection(connectionId, dialogflowConnection);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DialogflowIntegrationApi#updateDialogflowConnection");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
connectionId | String | Uniquely identifies a Telnyx application (Call Control, TeXML) or Sip connection resource. | |
dialogflowConnection | DialogflowConnection | The params expected to create/update a Dialogflow Connection for given connection_id. |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | Return details of the Dialogflow connection associated with the given CallControl connection. | - |
0 | Unexpected error | - |