---
title: "Call a tool"
method: POST
path: "/projects/{projectId}/servers/{serverId}/tools/call"
tags: ["Execution"]
---

# Call a tool

`POST /projects/{projectId}/servers/{serverId}/tools/call`

Executes a tool on the server and returns the MCP `CallToolResult` directly. Tool-level failures (`isError: true` in the result) are **successful calls** — the server answered; only transport/auth errors use the error envelope.

## Path parameters

- `projectId` string, required
- `serverId` string, required

## Request body

- object
  - `toolName` string, required — Tool name, exactly as returned by the tools list.
  - `parameters` object — Tool arguments matching the tool's `inputSchema`. Defaults to `{}`.

## Response `200`

The MCP `CallToolResult`. Check `isError` for tool-level failures.

- CallToolResult — MCP tool execution result, returned verbatim from the server.
  - `content` object[], required — Content blocks (`text`, `image`, `resource`, ...).
  - `structuredContent` object — Structured output matching the tool's `outputSchema`, when declared.
  - `isError` boolean — `true` when the **tool** reported a failure. The HTTP call still succeeds — the server answered.

## Other responses

- `400` — Malformed body or parameters.
- `401` — Missing, invalid, revoked, or orphaned key (`UNAUTHORIZED`) — or the **target MCP server** needs an OAuth grant (`OAUTH_REQUIRED`), which is a property of the server, not your key.
- `403` — Key is valid but not allowed to do this.
- `404` — Unknown project, server, or resource.
- `422` — The target server doesn't support this MCP capability.
- `429` — Per-key rate limit exceeded (60 requests/minute sustained, bursts up to 10). Honor `Retry-After` and back off with jitter.
- `500` — Something failed on MCPJam's side.
- `502` — Could not connect to the target MCP server.
- `504` — The target MCP server connected but didn't respond in time.

---

[API](https://skmtc.net/mcpjam/apis/mcpjam-api.md) · [All operations](https://skmtc.net/mcpjam/apis/mcpjam-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mcpjam/mcpjam-api/revisions/b767df188d0c/schema)
