Skip to content

Discover Tools

POST /tools/discover

Probe a tool-protocol server and report what it offers (annex 09 §2.2).

Nothing is persisted: this is the read half of connecting a server, and the rows are written by POST /tools/import. The probe passes the same SSRF validator a run does and resolves the same credentials in the caller’s scope, because an endpoint that contacts an arbitrary address without either is a port scanner behind a login.

422 naming config.endpoint when the server could not be reached, carrying whatever the socket or the server said about it. The kind degrades to a stub mid-run, which is correct there and refused here: a stub is a message for the model, not a tool to import.

FieldTypeNotes
configobjectrequired—
secrets_requiredstring[]optional—
StatusDescriptionBody
200Successful ResponseToolDiscovery
422Validation ErrorHTTPValidationError

The body shows the fields the schema always carries. Which combination is legal is a service rule the schema cannot express, so read the description above before copying this.

Terminal window
curl -X POST https://your-deployment.example.com/tools/discover \
-H "Authorization: Bearer $COBRE_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"config": {}
}'
FieldTypeNotes
sourcestringrequired—
toolsDiscoveredToolView[]optional—