---
title: "Get a revision"
method: GET
path: "/agents/{agent_id}/revisions/{revision_id}"
tags: ["agents"]
---

# Get a revision

`GET /agents/{agent_id}/revisions/{revision_id}`

## Request

- Base URL: `/api/v1` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/v1/agents/{agent_id}/revisions/{revision_id}`
- Auth: API key in header `X-Axilio-Api-Key`
- TypeScript: <https://skmtc.dev/axilioai/apis/axilio-api/docs/agents/:agent_id/revisions/:revision_id/get.ts> (a function with typed inputs; its response is checked against the schema)

Fetches one of an agent's revisions with its instructions or code. A revision of another agent is 404.

## Path parameters

- `agent_id` string, uuid, required: The agent's id.
- `revision_id` string, uuid, required: The revision's id.

## Response `200`

OK

- AgentRevision: One revision of an agent: instructions or code. Revisions are append-only.
  - `$schema` string, uri: A URL to the JSON Schema for this object.
  - `agent_id` string, uuid, required: The agent the revision belongs to.
  - `author_user_id` string, uuid, nullable, required: The user who added the revision. Null once they have deleted their account.
  - `base_revision_id` string, uuid: On a proposed fix, the revision the repaired run ran.
  - `code` string: The script, on a code revision.
  - `created_at` string, date-time, required: When the revision was added.
  - `id` string, uuid, required: The revision's id.
  - `instructions` string: The task, on an instructions revision.
  - `kind` 'code' | 'instructions', required: code: the revision is a script. instructions: the revision is a task the agent works through a model.
  - `message` string: The author's note on the revision.
  - `on_failure` 'fail' | 'ask' | 'repair': On a code revision, what a run does when a step fails: fail the run, ask (pause for a person, who retries the step or completes the run), or repair (the agent takes over and proposes a fix).
  - `promoted_at` string, date-time: On a proposed fix, when it was promoted to current.
  - `proposal_state` 'waiting' | 'superseded' | 'promoted': Set when the revision is a fix a repair proposed, which is not current until promoted: waiting to be promoted, superseded (the agent has moved on from the revision it fixes, so it can't be promoted), or promoted.
  - `revision` integer, required: The revision's number within the agent, from 1.
  - `source_run_id` string, uuid: The run the revision came from: on a proposed fix, the run whose repair wrote it; on an agent saved from a run, that run.

## Other responses

- `403`: Forbidden
- `404`: Not Found
- `422`: Unprocessable Entity
- `500`: Internal Server Error

## Changes

- **2026-11-01** `80de09d0e643`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/axilioai/apis/axilio-api/changes/agents/:agent_id/revisions/:revision_id/get.md)

---

[API](https://skmtc.dev/axilioai/apis/axilio-api.md) - [All operations](https://skmtc.dev/axilioai/apis/axilio-api/llms.txt) - [OpenAPI document](https://skmtc.dev/axilioai/apis/axilio-api/revisions/80de09d0e643?raw)
