# Connect an agent over MCP

Give your agent every Nija model as a tool, with an ordinary inference key and a spend cap you control.

## What can an agent do over Nija's MCP server?

An agent can ask any Nija model a question, browse the catalogue with live prices and hand over long work to collect later.

MCP is the Model Context Protocol: the server is at https://nija.africa/mcp, and the MCP quickstart documents every tool and refusal.

- [MCP quickstart](https://nija.africa/docs/mcp)

## How do I connect my agent?

Open Keys, follow Connect an agent, copy the Connector file into your agent host, put your inference key in place of the placeholder and start a new session.

If your host can ask you for the key, use the Editor workspace block instead: the file then holds no key and is safe to share.

1. Sign in and open Keys; create an inference key if you have none, and copy its secret.
2. On Keys, follow Connect an agent.
3. Under Client configuration, copy the Connector file block into your agent host's MCP settings.
4. Replace the placeholder with your key, then start a new session in the agent so it finds the server.

- [Connect an agent](https://nija.africa/keys/mcp)

## Which key does an agent use?

An ordinary inference key: there is no separate MCP sign-up, and the agent spends from your balance at the same prices as your own code.

Give each agent a key of its own with a Credit limit, so you can cap or stop that one agent without touching your code.

When an agent reads its spend cap, the reply names the key by the name you gave it and by the Key ID that Keys shows under that name, so you can tell which key it means.

- [Keys](https://nija.africa/keys)

## How do I see what my agent spent?

Agent requests carry the mcp channel on Activity and on Spend & limits, so you can filter them and total them apart from your own code.

- [Activity](https://nija.africa/activity)
- [Spend & limits](https://nija.africa/spend)
