# AI agents

These docs are written to be read by your AI agent as much as by you. Point the agent at the files below, give it a credential made for the task, and it can do the migration work through Aegis while you approve each change.

## Files for agents

| File | What it is |
| --- | --- |
| [`/llms.txt`](https://docs.qblackbit.com/llms.txt) | The index, in the [llms.txt](https://llmstxt.org) format: a short summary, then every page as a link to its plain Markdown version |
| [`/llms-full.txt`](https://docs.qblackbit.com/llms-full.txt) | Every page of this site in one plain-text file |
| `/<page>.md` | Any page as plain Markdown: add `.md` to its address, for example [`/quickstart/cloud.md`](https://docs.qblackbit.com/quickstart/cloud.md), or `index.md` for a section, such as [`/guides/index.md`](https://docs.qblackbit.com/guides/index.md). Each page links to its own at the bottom |
| [`/prompts.json`](https://docs.qblackbit.com/prompts.json) | The [prompt library](https://docs.qblackbit.com/prompts/index.md) as data, with each brief's full text |
| [`/openapi/aegis-cloud-v1.json`](https://docs.qblackbit.com/openapi/aegis-cloud-v1.json), [`/openapi/aegis-core-v1.json`](https://docs.qblackbit.com/openapi/aegis-core-v1.json) | The OpenAPI documents the API reference is built from |
| `https://aegis.qblackbit.com/llms.txt` | The cloud service's own short brief for agents |

All of them are generated from the same sources as these pages on every build, so they never disagree with what you read here.

## Brief your agent

The quickest way is a prompt from the [library](https://docs.qblackbit.com/prompts/index.md): pick your case, select **Copy prompt**, paste it into your agent. If you write your own brief, include:

1. The goal, and the repository or folder the agent works in.
2. "Read `https://docs.qblackbit.com/llms.txt` first, and use only endpoints and commands written there."
3. Where the credential is (an environment variable or a file), never the credential itself.
4. That every change is shown as a diff and waits for your approval.
5. That classical algorithms keep working until the new path is verified.

## Credentials for an agent

| Where | What to give the agent | Ends |
| --- | --- | --- |
| Aegis Cloud | An API key with the `developer` role (or `auditor` to read), labelled for the task, made under **API keys** | When you revoke it in the app. Keys do not expire on their own; expiring keys are (Planned) |
| Aegis Core | A token from `POST /v1/sys/tokens` with the `operator` role (or `auditor`), a `scope` limited to the task's routes, operations and keys, and `expires_in` of a few hours | When it expires, or when an administrator revokes it with `POST /v1/sys/tokens/{name}/revoke` |

Never paste a key or token into a chat. Agents keep conversation history, and chat logs are not secret stores.

## The MCP server

`aegis-mcp` is a Model Context Protocol server (protocol version 2025-06-18) that lets an agent use Aegis Cloud as tools, with your organisation's API key:

| Tool | Calls |
| --- | --- |
| `list_algorithms` | `GET /api/v1/algorithms` |
| `usage` | `GET /api/v1/usage` |
| `hash` | `POST /api/v1/hash` |
| `sign` | `POST /api/v1/keys/{name}/sign` |
| `verify` | `POST /api/v1/keys/{name}/verify` |
| `encapsulate` | `POST /api/v1/encapsulate` |

It never makes, exports or deletes keys. It runs over standard input and output, or over HTTP on a loopback address only, with a bearer token from a file. A configuration looks like this:

```json
{
  "mcpServers": {
    "aegis": {
      "command": "aegis-mcp",
      "env": { "AEGIS_CLOUD_URL": "https://aegis.qblackbit.com", "AEGIS_API_KEY_FILE": "/path/to/agent.key" }
    }
  }
}
```

`aegis-mcp` is built, but a public download is (Planned), and so is a hosted MCP server with sign-in. Until then, agents call the [Cloud API](https://docs.qblackbit.com/api/cloud.md) directly, which is what the prompt library does.

## Facts an agent should state accurately

- The post-quantum algorithms are the NIST standards FIPS 203 (ML-KEM), FIPS 204 (ML-DSA) and FIPS 205 (SLH-DSA); hybrids pair them with X25519 or the NIST curves.
- Nothing is "quantum-proof", and qblackbit claims no certification for Aegis or the cloud service.
- Free and Pro run in qblackbit's cloud, each organisation's keys under its own key-encryption key. Enterprise runs on the customer's own machines with no connection to qblackbit.
- Anything marked Planned on [Built and planned](https://docs.qblackbit.com/overview/status.md) does not exist yet.
