Skip to main content
The Invoke CLI is the terminal side of the gateway. Use it to make a workspace, bring the tools your agent uses, get the MCP URL your agent connects to, call a tool yourself, and read back what your agents did.

Installation

Or run it without installing:
You need Node 18+ and Python 3.9+ (invoke is a small Node launcher for a Python CLI).

Sign in

Saves your API key and the Invoke URL locally for later commands. Without --api-key it prompts for the key. invoke status shows your login and active workspace, and invoke doctor checks the key and the API’s health.

Make a workspace and bring your tools

invoke gateway connect takes any MCP server URL, plus the auth header it expects. Its tools then go through Invoke. MCP servers that only allow OAuth sign-in (Slack, Linear, Notion and others) are connected from the console.

Point your agent at it

Give that URL to any MCP client with your key in an X-API-Key: <key> or Authorization: Bearer <key> header. For Claude Code:
For LangGraph (pip install langchain-mcp-adapters):
For the OpenAI Agents SDK (pip install openai-agents):
Tools are listed with names a model API accepts: github.create_issue is listed as github_create_issue. For Claude Desktop and raw JSON-RPC, see Invoke MCP.

Governed calls from the terminal

invoke gateway call makes one governed call, on the same path the SDK and MCP clients use:
It prints what the tool returned, then Invoke’s ids and the receipt line. The same --idempotency-key is the same action: send the call twice and it runs once, and the second call gets the first receipt. The key decides who acts. With an agent’s own key, leave out --agent-id: naming another agent is refused. With an account key, --agent-id <id> acts as that registered agent.

Read back what happened

For a run stage by stage, use invoke.trace() in the SDK or open the run in the console. See Traces.

Upgrading from 0.5

The commands below ran on Invoke’s old runtime API, which the hosted service no longer serves, so they could only fail. 0.6 retires them. Each now prints its replacement instead of calling the API: invoke deploy, invoke dev and invoke agents still work on projects made by earlier versions, but they are no longer listed in the help. Run invoke <command> --help for every flag.

Next steps