---
title: "The Brain as text ready to paste into a chat"
method: GET
path: "/v1/project/{name}/inject"
tags: ["Project Brain"]
---

# The Brain as text ready to paste into a chat

`GET /v1/project/{name}/inject`

## Request

- Base URL: `https://api.chainmemory.ai`
- URL: `https://api.chainmemory.ai/v1/project/{name}/inject`
- Auth: API key in header `x-api-key`

The project's latest state written as plain text by relevance and cut to a character budget: what changed since `since`, open risks (high first, with the priorities that mitigate them and the high risks nobody mitigates), active priorities with their completion criterion, the owner's work rules, recent decisions and milestones, open questions and constraints, headed by the on-chain anchor. With `task`, everything needed to work on one priority instead. Free and read-only.

**Levels.** `public` (default) replaces addresses, ports, server paths and security rules with `[withheld]` and counts them, so the text is safe to paste anywhere. `full` adds them; it is served only to the owner's personal key (organization keys get 403), every request is logged, and if the log cannot be written the request fails with 503. How a project's AIC are safeguarded is never included, at any level. A project key (`aicp_`) only reads its own project. Send `x-cm-client` to name your client in the full-level log.

## Path parameters

- `name` string, required

## Query parameters

- `budget` integer
- `lang` 'en' | 'es'
- `since` integer
- `task` string
- `level` 'public' | 'full'

## Headers

- `x-cm-client` string

## Response `200`

The brief

- object
  - `project` string
  - `version` integer
  - `state_hash` string
  - `level` 'public' | 'full'
  - `budget` integer
  - `lang` string
  - `length` integer
  - `text` string
  - `since` integer, nullable: Absent when `task` is given
  - `task` string: Present only when `task` was given
  - `sensitive_lines` string[]: Only at the full level: the lines the public level withholds, to show the owner before anything is pasted

## Other responses

- `400`: Invalid `level`, `since` or `task`
- `403`: A project key asking for another project, or an organization key asking for the full level
- `404`: No state for this project, or the priority given in `task` does not exist
- `503`: Full level unavailable: the access log could not be prepared or written

---

[API](https://skmtc.dev/chainmemory/apis/chainmemory-api.md) · [All operations](https://skmtc.dev/chainmemory/apis/chainmemory-api/llms.txt) · [OpenAPI document](https://skmtc.dev/chainmemory/apis/chainmemory-api/revisions/5331e0f0b6af?raw)
