Skip to main content

Connectors API Documentation

GET: Retrieve Connectors

Description

This route is used to retrieve a list of Connectors for a specific project.

Method

GET

Query Parameters

  • sort (string): The field by which to sort the Connectors.
  • page (number): The page number of the results.
  • limit (number): The number of items per page.
  • searchTerm (string): Optional search term to filter Connectors.

Response

  • Returns a JSON response with the list of Connectors or an error message.

Status Codes

  • 200 OK: Connectors retrieved successfully.
  • 500 Internal Server Error: Error listing Connectors.

Throws

  • An error if request validation or Connectors retrieval fails.

Example cURL

curl --location 'https://app.ai12z.net/api/projects/{projectId}/settings/connectors' \
--header 'Authorization: Bearer <YOUR_KEY>' \
--data-urlencode 'sort=name' \
--data-urlencode 'page=1' \
--data-urlencode 'limit=10'

GET: Retrieve Connectors by ID

Description

This route is used to retrieve details of a specific Connectors by its ID.

Method

GET

URL Parameters

  • id (string): The ID of the Connectors to retrieve.

Response

  • Returns a JSON response with logs details such as id, name ,author and description.

Status Codes

  • 200 OK: Connectors retrieved successfully.
  • 500 Internal Server Error:Error retrieving the Connectors.

Throws

  • An error if the Connectors is not found or any other error occurs.

Example cURL

curl --location 'https://app.ai12z.net/api/projects/{projectId}/settings/connectors'\
--header 'Authorization: Bearer <YOUR_KEY>'

PUT: Update a Connectors

Description

This route is used to update an existing Connectors.

Method

PUT

Request Body

Example request body:

{
"cmsConnectors": [
{ "id": "Connectors ID", "name": "Connectors Name" },
{ "id": "Connectors ID", "name": "Connectors Name" }
]
}

Response

  • Returns the updated Connectors.

Status Codes

  • 200 OK: Connectors updated successfully.
  • 500 Internal Server Error: Error updating the Connectors.

Throws

  • An error if request validation or Connectors update fails.

Example cURL

curl --location --request PUT 'https://app.ai12z.net/api/projects/{projectId}/settings/connectors' \
--header 'Authorization: Bearer <YOUR_KEY>' \
--header 'Content-Type: application/json' \
--data-raw '{
"cmsConnectors": [ {"id": "Connectors ID", "name": "Connectors Name"},
{"id": "Connectors ID", "name": "Connectors Name"}]
}'