LoguDocs
Open Logu

Quickstart: Claude Code and MCP

Give an AI agent a way to ask you: Logu's MCP tools (ask_human, get_decision, send_event, report_metric…) and, for Claude Code and Codex, hooks that put permission prompts on your phone.

Claude Code: one command#

npx -y @logu/cli install claude-code

It shows a code and opens the Logu app: check the code, pick the workspace and the agent ("Claude Code on" your computer, or one you already have) and click Connect. Then:

  • Permission prompts come to your phone as asks: Approve runs the tool, Decline tells Claude why (anything you type becomes the reason). With no answer in time, Claude Code shows its normal prompt.
  • The question Claude ends a turn with becomes an ask; your answer continues the session.
  • Logu's MCP tools are registered for every session (logu mcp), so Claude can ask you on its own.

npx -y @logu/cli install codex does the same for OpenAI Codex, as its own agent.

Any MCP client#

Streamable HTTP at https://api.logu.dev/mcp, with an API key as a bearer token:

claude mcp add --transport http logu https://api.logu.dev/mcp \
  --header "Authorization: Bearer $LOGU_API_KEY"

Or over stdio with the API key logu login saved (it never lands in the client's config):

claude mcp add --scope user logu -- npx -y @logu/cli mcp

Clients that support MCP authorization (claude.ai, ChatGPT, Cursor) need no API key at all: see Connectors.

How an agent uses the tools#

  1. ask_human with project, title and optionally body, options and default_option. It waits up to wait_seconds (max 50).
  2. If the ask is still waiting, call get_decision with its ask_id, again and again.
  3. Proceed only when the result says approved: true; next says what to do now.

send_event tells the human something happened, report_metric reports a number, and whoami says which agent and workspace the tools act as.

Next#