Create API Tool Template
POST
/v2/api/organization/{organization_id}/api-tool-template
API Tool Template
Overview
Functionality
organization_id
in the URL path.template_name
: A string representing the name of the tool template.system_prompt
: A detailed prompt instructing how the tool should behave when calling external APIs.is_enabled
: A boolean flag to indicate whether the tool is active upon creation.Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/v2/api/organization/1/api-tool-template' \
--header 'Content-Type: application/json' \
--data-raw '{
"template_name": "Cerner Tool 3",
"system_prompt": "Fetch Cerner'\''s openAPI spec version 2024.10.10. Use '\''https://fhir-open.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d'\'' as the base URL. If you need to use the patient ID use this ID '\''12724066'\''. You should access all the required endpoints needed to answer the query but do not hit any endpoints UNNECESSARILY. ALWAYS LIMIT the API request to bring ONLY the required fields.",
"is_enabled": true
}'
Response Response Example
201 - Example 1
{
"success": true,
"message": "API Tool Template created successfully.",
"data": {
"id": 3,
"template_name": "Cerner Tool 3",
"system_prompt": "Fetch Cerner's openAPI spec version 2024.10.10. Use 'https://fhir-open.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d' as the base URL. If you need to use the patient ID use this ID '12724066'. You should access all the required endpoints needed to answer the query but do not hit any endpoints UNNECESSARILY. ALWAYS LIMIT the API request to bring ONLY the required fields.",
"is_enabled": true
}
}
Request
Path Params
organization_id
integer <int64>
required
Example:
1
Body Params application/json