> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cohesive.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Results

> What a Cohesive tool call returns: content, structured data, exit codes, metadata, and the limits on size and time.

A tool call returns the result as text, and as structured content when the result is JSON. Errors arrive the same way — as a result marked `isError`, with a label naming what went wrong — so an agent can read a failure and decide what to do rather than losing the turn to a transport error.

## Exit codes

Every result carries the exit code of the work behind it, in `_meta` and in the error text.

| Code | Meaning | What to do |
| - | - | - |
| `0` | Success | Nothing. The content is the answer |
| `1` | Error | Read the message; it says what failed |
| `2` | Usage error | The arguments were wrong. The result lists the properties the tool accepts |
| `3` | Authentication failed | The session was rejected. Sign in again from your client |
| `4` | Not found | The id doesn't resolve, or you can't reach it |
| `5` | Server below the platform minimum | Not yours to fix. Write to [support@cohesive.ai](mailto:support@cohesive.ai) |
| `6` | Payment required | Don't retry. The organization needs credits or a subscription |

## Metadata

Each result carries `_meta` keys under the `cohesive.ai/` prefix:

| Key | Value |
| - | - |
| `cohesive.ai/exit_code` | The exit code above |
| `cohesive.ai/argv` | The resolved arguments for the call |
| `cohesive.ai/duration_ms` | How long the call took |
| `cohesive.ai/version` | The server version that ran it |
| `cohesive.ai/truncated` | Present when the output was cut |

## Size limits

Output is capped at 256 KiB. Past that, the result is truncated, `cohesive.ai/truncated` is set, and the text ends with a note saying so — narrow the request with `node_ids`, `bounds`, or `limit`, or page through with `before` and `limit`.

Images come back inline up to 3 MiB. A capture above that isn't returned as bytes: the result tells the agent to call `cohesive_file_get` and use the signed `download_url` instead. Narrowing a capture with `node_ids` or `bounds` is usually the better move.

Request bodies are capped at 8 MiB.

## Time limits

A tool call gets 120 seconds by default. Tools that routinely take longer, like a canvas render, carry their own budget, and nothing runs past 15 minutes whatever it asks for.

A call that runs out of time comes back as an error saying so, with the same advice: narrow the request. Fewer nodes, tighter `bounds`.

If your client hangs up mid-call, the run is cancelled rather than left to burn its budget.

<Tip>
  Read-only tools are marked `read-only` and destructive ones `destructive` on [every tool's page](/mcp-server/tools/canvas) and in the annotations on the wire. Clients that ask for approval before acting use those hints — they're worth honoring if you're building one.
</Tip>
