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

> ## Agent Instructions
> Start with /introduction/getting-started. Use the Direct Query API (POST /api/lens/query) with the Newton Fusion model (text, image, and video reasoning) or the Newton Omega encoder (time-series embeddings). ATAI_API_ENDPOINT is the base URL https://platform.u1.archetypeai.app with no version path; every endpoint path begins with /api. Pages whose descriptions are marked (Archived) document the legacy Lens runtime — do not use them for new projects.

# Get Bundle

> Retrieve a single bundle, optionally with its recent runs

Requires [version 1.1.9](https://docs.archetypeai.app/release-notes/1.1.x.md#v1-1-9) or later of the Archetype platform.

> [!WARNING]
>
> This endpoint is deprecated and will be removed from the platform soon. Use the Packages API's
> [Get Package](https://docs.archetypeai.app/api-reference/agents/packages/get-package.md) endpoint instead.

## Overview

This endpoint returns one bundle by its `bnd_` id.

Set `include_latest_runs=true` to attach the bundle's most recent runs, so a bundle detail view can show run history without a second call to `/api/agents/instances`.

## Request

**bundle\_id** `string` *required*

Bundle `bnd_` id.

**include\_latest\_runs** `boolean` (default: false)

Include the bundle's most recent runs as `latest_runs`. Off by default — it costs an extra join per bundle.

## Response

**id** `string` *required*

TypeID-encoded bundle identifier (`bnd_` prefix).

**name** `string` *required*

Human label for the bundle.

**description** `string` *required*

Human description of the bundle.

**blueprint\_id** `string` *required*

The pinned blueprint's immutable `blp_` id. Resolve its key via the blueprint registry when needed.

**values** `object` *required*

User value overrides, layered over the blueprint defaults at run time.

**status** `string` *required*

Build lifecycle of the bundle: `building`, `ready`, or `failed`.

**is\_canonical** `boolean` *required*

True for a canonical (platform-authored) bundle, visible to every org.

**created\_at** `string` *required*

Creation timestamp (date-time).

**org\_id** `string`

Owning org; omitted for a canonical bundle.

**models** `object` *required*

Per-slot model overrides: slot name to registry tag. If this object is empty, the bundle uses
the blueprint's default for every slot.

**artifacts** `object`

Artifact links attached to the bundle.

**latest\_runs** `array`

The bundle's five most recent runs, newest first. Present only when the read asked for it via `include_latest_runs=true`; an empty array means the bundle has never been run. Runs are scoped to the caller's org, so a canonical bundle shows only the caller's own runs of it.

### Run summary object (`latest_runs[]`)

**id** `string` *required*

TypeID-encoded agent identifier (`agt_` prefix).

**status** `string` *required*

Agent lifecycle status: `running`, `paused`, `completed`, `failed`, or `cancelled`.

**created\_at** `string` *required*

Creation timestamp (date-time).

**started\_at** `string`

When the run started; `null` before then.

**completed\_at** `string`

When the run finished; `null` while unfinished.

**job\_id** `string`

External executor's job id for this run (a JOS `job_` id). Present once the run has been dispatched.

**error** `string`

Failure detail; `null` unless the run failed.

```bash cURL theme={"system"}
curl "$ATAI_API_URL/api/agents/bundles/bnd_01jc9pd42kzq7v8n3h5m6rtx0w" \
  -H "Authorization: Bearer $ATAI_API_KEY"
```

```bash cURL - With Run History theme={"system"}
curl "$ATAI_API_URL/api/agents/bundles/bnd_01jc9pd42kzq7v8n3h5m6rtx0w?include_latest_runs=true" \
  -H "Authorization: Bearer $ATAI_API_KEY"
```

```python Python theme={"system"}
import os
import requests

base_url = os.environ["ATAI_API_URL"]
api_key = os.environ["ATAI_API_KEY"]

response = requests.get(
    f"{base_url}/api/agents/bundles/bnd_01jc9pd42kzq7v8n3h5m6rtx0w",
    headers={"Authorization": f"Bearer {api_key}"},
    params={"include_latest_runs": "true"},
)

if response.status_code == 200:
    bundle = response.json()
    print(f"{bundle['name']} pins {bundle['blueprint_id']} (status {bundle['status']})")
    for run in bundle.get("latest_runs") or []:
        print(f"  {run['id']}: {run['status']}")
else:
    print(f"Error: {response.json()['errors']}")
```

```javascript JavaScript theme={"system"}
const response = await fetch(
  `${process.env.ATAI_API_URL}/api/agents/bundles/bnd_01jc9pd42kzq7v8n3h5m6rtx0w?include_latest_runs=true`,
  {
    headers: {
      'Authorization': `Bearer ${process.env.ATAI_API_KEY}`
    }
  }
);

const body = await response.json();

if (response.ok) {
  console.log(`${body.name} pins ${body.blueprint_id} (status ${body.status})`);
  (body.latest_runs ?? []).forEach(run => console.log(`  ${run.id}: ${run.status}`));
} else {
  console.error('Error:', body.errors);
}
```

```json 200 - Success theme={"system"}
{
  "id": "bnd_01jc9pd42kzq7v8n3h5m6rtx0w",
  "org_id": "org_01jc8m5r2vq9xt4bn7h3kdzs6w",
  "name": "Pump A monitor",
  "description": "Open-set monitor tuned for pump A telemetry.",
  "blueprint_id": "blp_01jc9n7k3xf8mbq2v5t0ary6de",
  "models": {},
  "values": {},
  "artifacts": {
    "calibration": "s3://.../knn_index"
  },
  "status": "ready",
  "is_canonical": false,
  "created_at": "2026-08-11T15:02:19Z",
  "latest_runs": [
    {
      "id": "agt_01jc9q8v5nm3ry7t2bkz4dhs6f",
      "status": "running",
      "job_id": "job_01jc9q9k4t8v2mnr5xh7bdzy3s",
      "created_at": "2026-08-11T15:10:00Z",
      "started_at": "2026-08-11T15:10:04Z",
      "completed_at": null,
      "error": null
    }
  ]
}
```

```json 404 - Bundle not found theme={"system"}
{
  "errors": [
    {
      "code": "<error_code>",
      "message": "Bundle not found.",
      "suggestion": null,
      "error_uid": "err-xxxxxxxx"
    }
  ]
}
```

## Important Notes

> [!NOTE]
>
> * Without `include_latest_runs=true`, `latest_runs` is absent — an empty array means the bundle has never been run.
> * A run's name is always its bundle's name, so it is not repeated in `latest_runs`. Fetch the full run (connectors, blueprint reference) from `GET /api/agents/instances/{agent_id}`.


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