Tools

Create tool version

POST

Path parameters

idstringRequired
Identifier for a tool. Formatted as a UUID.

Request

This endpoint expects an object.
parameters
stringRequired
Stringified JSON defining the parameters used by this version of the Tool.
version_description
stringOptional
Description that is appended to a specific version of a Tool.
description
stringOptional
Text describing what the tool does.
fallback_content
stringOptional
Text to use if the tool fails to generate content.

Response

This endpoint returns an optional object
tool_type
string
Type of Tool. Values from the ToolType enum.
id
string
Identifier for a Tool. Formatted as a UUID.
version
integer
Version number for a Tool. Version numbers should be integers. The combination of configId and version number is unique.
version_type
string
Inidicates whether this tool is using a fixed version number or auto-updating to the latest version. Values from the VersionType enum.
name
string
Name applied to all versions of a particular Tool.
created_on
integer
The timestamp when the first version of this tool was created.
modified_on
integer
The timestamp when this version of the tool was created.
parameters
string
Stringified JSON defining the parameters used by this version of the Tool.
version_description
stringOptional
Description that is appended to a specific version of a Tool.
fallback_content
stringOptional
Text to use if the tool fails to generate content.
description
stringOptional
Text describing what the tool does.
POST
1curl -X POST https://api.hume.ai/v0/evi/tools/00183a3f-79ba-413d-9f3b-609864268bea \
2 -H "X-Hume-Api-Key: <apiKey>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "parameters": "{ \"type\": \"object\", \"properties\": { \"location\": { \"type\": \"string\", \"description\": \"The city and state, e.g. San Francisco, CA\" }, \"format\": { \"type\": \"string\", \"enum\": [\"celsius\", \"fahrenheit\", \"kelvin\"], \"description\": \"The temperature unit to use. Infer this from the users location.\" } }, \"required\": [\"location\", \"format\"] }",
6 "version_description": "Fetches current weather and uses celsius, fahrenheit, or kelvin based on location of user.",
7 "description": "This tool is for getting the current weather.",
8 "fallback_content": "Unable to fetch current weather."
9}'
200Successful
1{
2 "tool_type": "FUNCTION",
3 "id": "00183a3f-79ba-413d-9f3b-609864268bea",
4 "version": 1,
5 "version_type": "FIXED",
6 "name": "get_current_weather",
7 "created_on": 1715277014228,
8 "modified_on": 1715277602313,
9 "parameters": "{ \"type\": \"object\", \"properties\": { \"location\": { \"type\": \"string\", \"description\": \"The city and state, e.g. San Francisco, CA\" }, \"format\": { \"type\": \"string\", \"enum\": [\"celsius\", \"fahrenheit\", \"kelvin\"], \"description\": \"The temperature unit to use. Infer this from the users location.\" } }, \"required\": [\"location\", \"format\"] }",
10 "version_description": "Fetches current weather and uses celsius, fahrenheit, or kelvin based on location of user.",
11 "fallback_content": "Unable to fetch current weather.",
12 "description": "This tool is for getting the current weather."
13}