API ReferenceapiaiPOST /v1/tools/{name}/invoke

POST /v1/tools/\{name\}/invoke

Service: ai · operationId: (none)

Required scopes

(no scope declared — review service config)

Path parameters

  • name (string) required

Request body

{
  "type": "object",
  "properties": {},
  "additionalProperties": {}
}

Responses

200 Tool invocation result

{
  "anyOf": [
    {
      "type": "object",
      "properties": {},
      "additionalProperties": {}
    },
    {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {},
        "additionalProperties": {}
      }
    }
  ]
}

400 Invalid tool input

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

403 Forbidden

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

404 Tool not found

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

409 Conflict

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

412 Precondition failed

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

500 Target service is not configured

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

502 Upstream error

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

Example

curl -X POST https://ai.platform.loop.health/v1/tools/{name}/invoke \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{ ... }'