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

# Connect with MCP

> Connect an Agent tool client to the same data. MCP is not the full HTTP API.

MCP is the tool set an Agent calls explicitly. It talks to the same Server and the same data. It is **not** the full HTTP API.

Automatic recall, capture, and flush still belong to a host hook or framework adapter. MCP only exposes operations you call yourself.

![Same data, three doors: HTTP, the Python Client, and MCP. Coverage differs.](https://mintcdn.com/powercontext/1t_ajifOEOG5YQjP/assets/basic-mcp-surface-en.svg?fit=max\&auto=format\&n=1t_ajifOEOG5YQjP\&q=85\&s=f4b487cf0d4409bec689fed404e282bf)

> [!NOTE]
>
> Field names and error codes follow the latest published [official docs](https://oceanbase.github.io/powercontext/). This page only helps you connect `/mcp` and see what it can do.

## Default URL

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
http://127.0.0.1:8000/mcp
```

This is Streamable HTTP. The default Server listens on loopback with Bearer auth off. If the Server is down, the client should fail to connect. It should not show an empty tool set that looks healthy.

## Minimum client config

Merge this into the Agent MCP config. Do not write a machine-local filesystem path, and do not put a token in the URL.

```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
{
  "mcpServers": {
    "powercontext": {
      "type": "http",
      "url": "http://127.0.0.1:8000/mcp"
    }
  }
}
```

Some Agents spell the type as `streamable-http`. Point them at the same `/mcp`. Codex, Claude Code, and WorkBuddy use different field names and header helpers. Those details stay on their pages.

## What it can and cannot do

MCP deliberately exposes a smaller surface than HTTP. Use this table to decide whether the next step can stay in the Agent, or whether you should switch to the Python Client or HTTP.

| Can | Cannot |
| - | - |
| `remember_memory`, `search_memory`, exact get / list / revise / retire | `prepare_context`. A hook or adapter normally prepares the final `PreparedContext` |
| `capture_content_source` | `flush_memory` |
| Work Contract, Handoff (Hands the current goal, verified progress, blockers, and next step to the next owner. Uncommitted work is still a temporary package.), Task Outcome | Skill generate / export |
| Candidate list / get / approve / reject / revise | Experience operations |
| Read and write the same data as HTTP and the Python Client | Reproduce each integration's automatic recall / capture / flush |

The default MCP tool names in current tests are those operation ids. Read-only Handoff report tools appear only when that feature is on. Do not treat them as the default surface.

`readOnlyHint` and `destructiveHint` on MCP tools are confirmation hints for the Agent. They are **not** an authorization boundary. A proposing Agent can still receive approve tools unless the host withholds them.

> [!WARNING]
>
> `handoff_current_work` writes a boundary Source. Discussing a design, or saying `preview and make no writes`, must not call it.

## After you enable Bearer

Loopback can leave auth off. Once `POWERCONTEXT_SERVER_AUTH_ENABLED=true`:

* `/mcp` itself needs `Authorization: Bearer <token>` for discovery and for tool calls;
* `/openapi.json` needs the same header;
* `/docs` can still open without a token. That does not mean MCP or the API is authorized.

Do not put the token in the URL. Use that Agent's header helper or environment variable, such as `POWERCONTEXT_CODEX_AUTHORIZATION` on Codex.

401/403 is not `empty`. A tool failure must stay visible. Do not pretend a write succeeded.

## How you know it worked

* The client connects to `http://127.0.0.1:8000/mcp` and lists `remember_memory` and `search_memory`.
* A Memory written through MCP is visible to the Python Client on the [API tour](https://powercontext.mintlify.site/en/basic-usage/api-tour.md).
* The tool list does not include `prepare_context`.
* `remember_memory` fails visibly after you stop the Server.
* With Bearer enabled, `/mcp` without a header is not a connected client.

> [!TIP]
>
> If PowerContext fails while automatically fetching context, keep working. If you explicitly write a Memory, commit a Handoff, approve a proposal, or export a Skill, you must see the failure. Read [fail-open](https://powercontext.mintlify.site/en/mental-model/fail-open.md) for the full rule.

## Next step

> [card] [Check the counts in Dashboard](https://powercontext.mintlify.site/en/basic-usage/dashboard.md)
>
> Use the same Scope as the Client and check that the counts match.

> [card] [How coding Agents register MCP](https://powercontext.mintlify.site/en/coding-agents/overview.md)
>
> Codex and Claude Code use different field names. The portable path is [Agent Plugin](https://powercontext.mintlify.site/en/common-agents/agent-plugin.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.