DeepFellow DOCS

Modify a specific tool

POST
/toolboxes/{toolbox_id}/tools/{tool_id}

Modify a specific tool.

The applicable update variant is inferred from the existing tool's own type, not from the request body — the update schemas have no type field, so any type sent in the body is ignored.

A header value equal to the mask that responses show means "unchanged": the stored value is kept. This lets a client read a tool, edit one field and send the whole definition back. Stored header values are not carried over when the update changes where the headers are sent (server_url, a prefix, a custom request path or method): send the values again or clear the headers.

Needs user bearer token in authorization header.

Raises: HTTPException: 404 if the tool is not in this toolbox; 400 if the update is invalid, a masked header has no stored value, a header value starts with the prefix of stored encrypted values, stored secret headers would follow the tool to a new target, or a knowledge_graph tool is saved while the knowledge graph is disabled on the server; 409 if the tool was modified by another request in the meantime.

Authorization

headerAuthorizationBearer <token>

Path Parameters

toolbox_id*string

A 24-character hexadecimal MongoDB ObjectId string.

Match^[0-9a-fA-F]{24}$
tool_id*string

A 24-character hexadecimal MongoDB ObjectId string.

Match^[0-9a-fA-F]{24}$

Header Parameters

OpenAI-Organization?|

Organization Id from OpenAi compatible endpoint. Required to organization access or project access (with OpenAI-Project header) when logged as User or Admin User.

OpenAI-Project?|

Project Id from OpenAi compatible endpoint. Required to project access for organization api key or User / Admin User access with OpenAI-Organization

Request Body

application/json
  1. body
server_label?string|null
server_url?string|null
allowed_tools?array<string>||null
headers?|null
require_approval?|string|null
server_description?string|null
[key: string]?any

Response Body

Successful Response

application/json
  1. response

Model for output of tool db.

id?|null
definition*||||||
toolbox_id*string

A 24-character hexadecimal MongoDB ObjectId string.

Match^[0-9a-fA-F]{24}$
created_at?integer
Example Request
curl -X POST 'https://deepfellow-server-host/toolboxes/5eb7cf5a86d9755df3a6c593/tools/5eb7cf5a86d9755df3a6c593' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "id": "5eb7cf5a86d9755df3a6c593",  "definition": {    "type": "file_search",    "vector_store_ids": [      "5eb7cf5a86d9755df3a6c593"    ],    "filters": {      "filters": [        {          "key": "string",          "type": "eq",          "value": "string"        }      ],      "type": "and"    },    "max_num_results": 1,    "ranking_options": {      "ranker": "auto",      "score_threshold": 0    }  },  "toolbox_id": "5eb7cf5a86d9755df3a6c593",  "created_at": 0}

We use cookies on our website. We use them to ensure proper functioning of the site and, if you agree, for purposes such as analytics, marketing, and targeting ads.