Create an API Tool

Create a reusable external HTTP tool.

Endpoint

POST
/api-tools

Request

Response

json

Request Parameters

ParameterTypeRequiredDescription
organization_idNumberYesOrganization ID
nameStringYesInternal tool name
descriptionStringYesWhat the tool does
endpointStringYesExternal HTTP endpoint
methodStringYesHTTP method used by the assistant configuration UI, usually GET or POST
headersObjectNoHeaders sent to the external API
url_parametersArrayNoQuery or path parameters
body_parametersArrayNoJSON body parameters for POST tools
parameters_schemaObjectNoOpenAI-style parameter schema
response_exampleObjectNoExample response to help users understand the tool

POST Body Example

Next Step: Attach the Tool to an Assistant

After creating the tool, attach it with

PATCH
/ai-assistants/:id:

json

Report an issue with this documentation

Please log in to report issues with our documentation.