---
title: "List Agent Branches"
method: GET
path: "/v1/convai/agents/{agent_id}/branches"
tags: ["Agents Platform"]
---

# List Agent Branches

`GET /v1/convai/agents/{agent_id}/branches`

Returns a list of branches an agent has

## Path parameters

- `agent_id` string, required — The id of an agent. This is returned on agent creation.

## Query parameters

- `include_archived` boolean — Whether archived branches should be included
- `limit` integer — How many results at most should be returned
- `include_commit_status` boolean — Whether to compute how far each branch has diverged from main (commits_ahead/commits_behind). This walks the version DAG of every branch, so it is slow on agents with long histories and is off by default, leaving those fields null.

## Headers

- `xi-api-key` string, nullable — Your API key. This is required by most endpoints to access our API programmatically. You can view your xi-api-key using the 'Profile' tab on the website.

## Response `200`

Successful Response

- ListResponseAgentBranchSummary
  - `meta` ListResponseMeta
    - `total` integer, nullable
    - `page` integer, nullable
    - `page_size` integer, nullable
  - `results` AgentBranchSummary[], required
    - `id` string, required
    - `name` string, required
    - `agent_id` string, required
    - `description` string, required
    - `created_at` integer, required
    - `last_committed_at` integer, required
    - `is_archived` boolean, required
    - `protection_status` 'writer_perms_required' | 'admin_perms_required'
    - `access_info` ResourceAccessInfo
      - `is_creator` boolean, required — Whether the user making the request is the creator of the agent
      - `creator_name` string, required — Name of the agent's creator
      - `creator_email` string, required — Email of the agent's creator
      - `role` 'admin' | 'editor' | 'commenter' | 'viewer', required — The role of the user making the request
      - `anonymous_access_level_override` 'admin' | 'editor' | 'commenter' | 'viewer', nullable — The access level for anonymous users. If None, the resource is not shared publicly.
      - `access_source` 'creator' | 'explicit' | 'workspace_admin' | 'workspace_default', nullable — Why the requesting user has access to this resource. 'creator' = caller is the owner. 'explicit' = caller (or one of their workspace groups) is listed in role_to_group_ids beyond the workspace-wide everyone group. 'workspace_default' = the workspace-wide everyone group is listed in role_to_group_ids (every non-anon workspace member, including admins, sees this resource). 'workspace_admin' = caller is a workspace admin and the admin seat is the *only* path to access; reserved for docs nobody else can see. Lets the UI disclose why an admin-bypass viewer sees a doc that wasn't explicitly shared with them.
    - `current_live_percentage` number — Percentage of traffic live on the branch
    - `parent_branch_id` string, nullable — ID of the parent branch
    - `draft_exists` boolean — Whether a draft exists for the branch
    - `draft_created_at` integer, nullable — Unix seconds when the caller's draft on this branch was first created, or null when they have no draft. A draft created before last_committed_at was written against a config the branch has since moved past, so it may not reflect the current one.
    - `draft_is_behind_tip` boolean — Whether the caller's draft on this branch was created before the branch's last commit, meaning it was written against a config the branch has since moved past and may not reflect the current one.
    - `calls_7d` integer — Number of calls in the last 7 days
    - `commits_ahead` integer, nullable — Number of commits on this branch not yet on main, relative to their common ancestor. Null if it could not be computed (e.g. no common ancestor, or the branch history exceeds the comparison budget).
    - `commits_behind` integer, nullable — Number of commits on main not yet incorporated into this branch, relative to their common ancestor. Null if it could not be computed (e.g. no common ancestor, or the branch history exceeds the comparison budget).
    - `merged_into_branch_id` string, nullable — ID of the branch this branch's tip version was merged into, if any

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-04** `b1797a1d5e80` — 2 info
  - added the optional property `results/items/draft_created_at` to the response with the `200` status
  - added the optional property `results/items/draft_is_behind_tip` to the response with the `200` status
- **2026-08-06** `1cae8adcc965` — 1 info
  - added the new optional `query` request parameter `include_commit_status`
- **2026-08-05** `ebff0190de5c` — 3 info
  - added the optional property `results/items/commits_ahead` to the response with the `200` status
  - added the optional property `results/items/commits_behind` to the response with the `200` status
  - added the optional property `results/items/merged_into_branch_id` to the response with the `200` status

[Change history](https://skmtc.dev/elevenlabs/apis/elevenlabs-api-documentation/changes/v1/convai/agents/:agent_id/branches/get.md)

---

[API](https://skmtc.dev/elevenlabs/apis/elevenlabs-api-documentation.md) · [All operations](https://skmtc.dev/elevenlabs/apis/elevenlabs-api-documentation/llms.txt) · [OpenAPI document](https://skmtc.dev/elevenlabs/apis/elevenlabs-api-documentation/revisions/48a38e3b0dbd?raw)
