Integrations API Documentation
GET: Retrieve Integrations
Description
This route is used to retrieve a list of integrations for a specific Agent and optional search capabilities.
Method
GET
Query Parameters
sort
(string): The field by which to sort the integrations.page
(number): The page number of the results.limit
(number): The number of items per page.searchTerm
(string): Optional search term to filter integrations.
Response
- Returns a JSON response with the list of integrations or an error message.
Status Codes
200 OK
: Integrations retrieved successfully.500 Internal Server Error
: Error listing integrations.
Throws
- An error if request validation or integrations retrieval fails.
Example cURL
curl --location 'https://app.ai12z.net/api/Agents/{AgentId}/integrations' \
--header 'Authorization: Bearer <YOUR_KEY>' \
--data-urlencode 'sort=name' \
--data-urlencode 'page=1' \
--data-urlencode 'limit=10'
GET: Retrieve Integration by ID
Description
This route is used to retrieve details of a specific integrations by its ID.
Method
GET
URL Parameters
id
(string): The ID of the integration to retrieve.
Response
- Returns a JSON response with integration details such as
id
,name
,key
,value
andnataResponse
.
Status Codes
200 OK
: Integrations retrieved successfully.500 Internal Server Error
:Error retrieving the integrations.
Throws
- An error if the integrations is not found or any other error occurs.
Example cURL
curl --location 'https://app.ai12z.net/api/Agents/{AgentId}/integrations' \
--header 'Authorization: Bearer <YOUR_KEY>'
DELETE: Delete a Integration
Description
This route is used to delete an existing integration.
Method
DELETE
Request Body
Example request body:
{
"id": "Integrations ID"
}
Response
- Returns a confirmation message indicating successful deletion.
Status Codes
200 OK
: Integration deleted successfully.500 Internal Server Error
: Error deleting the Integration.
Throws
- An error if request validation or integration deletion fails.
Example cURL
curl --location --request DELETE 'https://app.ai12z.net/api/Agents/{AgentId}/integrations' \
--header 'Authorization: Bearer <YOUR_KEY>' \
--header 'Content-Type: application/json' \
--data-raw '{
"id": "Integration ID"
}'