---
title: "Execute MCP Tool"
method: POST
path: "/v1/mcp/tool/execute"
tags: ["MCP Tools"]
---

# Execute MCP Tool

`POST /v1/mcp/tool/execute`

Executes an MCP (Model Context Protocol) tool that has been configured in Bifrost. This endpoint is used to execute tool calls returned by AI models during conversations. Requires MCP to be configured in Bifrost.

## Request body

- ToolCall
  - `id` string — Unique tool call identifier
  - `type` 'function' — Tool call type
  - `function` FunctionCall, required
    - `name` string, required — Function name
    - `arguments` string, required — JSON string of function arguments

## Response `200`

Tool execution successful

- BifrostMessage
  - `role` 'user' | 'assistant' | 'system' | 'tool', required — Role of the message sender
  - `content` union — Message content - can be simple text or structured content with text and images
    - string — Simple text content
    - ContentBlock[] — Structured content with text and images
      - union
        - object
          - `type` 'text', required — Content type for text blocks
          - `text` string, required — Text content
        - object
          - `type` 'image_url', required — Content type for image blocks
          - `image_url` ImageURLStruct, required
            - `url` string, required — Image URL or data URI
            - `detail` 'low' | 'high' | 'auto' — Image detail level
  - `tool_call_id` string — ID of the tool call (for tool messages)
  - `tool_calls` ToolCall[] — Tool calls made by assistant
    - `id` string — Unique tool call identifier
    - `type` 'function' — Tool call type
    - `function` FunctionCall, required
      - `name` string, required — Function name
      - `arguments` string, required — JSON string of function arguments
  - `refusal` string — Refusal message from assistant
  - `annotations` Annotation[] — Message annotations
    - `type` string, required — Annotation type
    - `url_citation` Citation, required
      - `start_index` integer, required — Start index in the text
      - `end_index` integer, required — End index in the text
      - `title` string, required — Citation title
      - `url` string — Citation URL
      - `sources` unknown
      - `type` string — Citation type
  - `thought` string — Assistant's internal thought process

## Other responses

- `400` — unresolved $ref
- `429` — unresolved $ref
- `500` — unresolved $ref

---

[API](https://skmtc.dev/getbifrost/apis/bifrost-http-transport-api.md) · [All operations](https://skmtc.dev/getbifrost/apis/bifrost-http-transport-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/getbifrost/bifrost-http-transport-api/revisions/e70d3ae3c0d0/schema)
