Skip to main content
POST
/
agents
/
{agentId}
/
tools
Add Tool
curl --request POST \
  --url https://eu-gcp-api.vg-stuff.com/v3/agents/{agentId}/tools \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "tool": {
    "name": "<string>",
    "description": "<string>",
    "isDefault": true,
    "method": "GET",
    "serverUrl": "<string>",
    "serverUrlSecret": "<string>",
    "disabled": true,
    "isVapiTool": true,
    "vapiId": "<string>",
    "isGlobal": true,
    "fields": [
      {
        "id": "<string>",
        "in": "<string>",
        "type": "string",
        "value": "<unknown>",
        "defaultValue": "<unknown>",
        "key": "<string>",
        "description": "<string>",
        "required": true,
        "reusable": true,
        "isEnv": true,
        "isSystem": true,
        "isGlobal": true,
        "agentId": "<string>",
        "userId": "<string>"
      }
    ],
    "channels": [
      "web-chat"
    ]
  }
}
'
{
  "success": true,
  "message": "<string>",
  "data": {
    "id": "<string>",
    "name": "<string>",
    "description": "<string>",
    "isDefault": true,
    "method": "GET",
    "serverUrl": "<string>",
    "serverUrlSecret": "<string>",
    "createdAt": "<string>",
    "updatedAt": "<string>",
    "disabled": true,
    "isVapiTool": true,
    "vapiId": "<string>",
    "isGlobal": true,
    "variablesIds": [
      "<string>"
    ],
    "agentId": "<string>",
    "userId": "<string>",
    "backchannellingPhrases": [
      "<string>"
    ],
    "fields": [
      {
        "id": "<string>",
        "in": "<string>",
        "type": "string",
        "value": "<unknown>",
        "defaultValue": "<unknown>",
        "key": "<string>",
        "description": "<string>",
        "required": true,
        "reusable": true,
        "isEnv": true,
        "isSystem": true,
        "isGlobal": true,
        "agentId": "<string>",
        "userId": "<string>"
      }
    ],
    "channels": [
      "web-chat"
    ]
  }
}

Example Request

{
  "tool": {
    "name": "Get Weather",
    "description": "Fetches current weather data for a given location",
    "serverUrl": "https://api.example.com/weather",
    "method": "GET",
    "fields": [
      {
        "id": "location",
        "key": "city",
        "type": "string",
        "in": "query",
        "description": "City name for weather lookup",
        "required": true
      }
    ]
  }
}
name and description are required. The description helps the AI understand when to use the tool.
Configure channels to restrict which platforms can use this tool (e.g., ["web-chat", "whatsapp"]).

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

agentId
string
required

The unique identifier of the agent

Body

application/json
tool
object
required

Response

Successful response

success
boolean
required

Indicates if the tool was created successfully

message
string
required

Response message

data
object
required

Created tool object