Median

GET /tool-endpoints

Updated Oct 1, 20261 minute read

Read the tool endpoints

Every route the agent looks to for your tools, and what the last sync found at each one. The endpoints are the truth, but the agent answers from what was synced. Any member's OAuth token can read this.

Part of Tool endpoint.

Responses

StatusDescription
200The endpoints and their tools.
401missing_api_key: no bearer token. invalid_api_key: the key matches no organization or was revoked. publishable_key: a median_pk_ key was sent. invalid_token: the OAuth token is unknown or expired.
403With an OAuth token, no_organization when no organization is bound.
429The organization's API allowance for this class of request is used up. Wait the Retry-After header's seconds. Limits depend on the plan. See rate limits.

200 body

FieldTypeRequiredDescription
endpointsobject[]YesEvery connected route and the tools its last successful sync found.
endpoints[].idstringYes
endpoints[].urlstringYesThe route the agent calls.
endpoints[].status"syncing" | "ready" | "error"YesWhere the last sync got to.
endpoints[].erroranyYesWhy the last sync failed, when it did.
endpoints[].lastSyncedAtanyYesWhen the manifest was last read, in milliseconds.
endpoints[].toolsobject[]Yes
endpoints[].tools[].namestringYes
endpoints[].tools[].descriptionstringYes
endpoints[].tools[].risk"low" | "medium" | "reviewed" | "high"YesHow the tool is gated. low runs freely. medium waits for the visitor's yes. reviewed waits for the visitor's yes, then an automatic review of the conversation decides. high waits for a teammate's approval.
endpoints[].tools[].enabledbooleanYesWhether the agent may hold it.
endpoints[].tools[].syncedAtintegerYesWhen this tool last arrived, in milliseconds.

Example response

{
  "endpoints": [
    {
      "id": "k170abc123",
      "url": "https://example.com/api/median/orders",
      "status": "ready",
      "error": null,
      "lastSyncedAt": 1737000000000,
      "tools": [
        {
          "name": "orderStatus",
          "description": "Look up an order.",
          "risk": "low",
          "enabled": true,
          "syncedAt": 1737000000000
        }
      ]
    }
  ]
}

Example request

curl https://api.median.sh/v1/tool-endpoints \
  -H "Authorization: Bearer $MEDIAN_KEY"

Still need help?

    Esc