GET
/
v0
/
agents
List agents
curl --request GET \
  --url https://api.cursor.com/v0/agents \
  --header 'Authorization: Bearer <token>'
{
  "agents": [
    {
      "id": "bc_abc123",
      "name": "Add README Documentation",
      "status": "RUNNING",
      "source": {
        "repository": "https://github.com/your-org/your-repo",
        "ref": "main"
      },
      "target": {
        "branchName": "cursor/add-readme-1234",
        "url": "https://cursor.com/agents?id=bc_abc123",
        "prUrl": "https://github.com/your-org/your-repo/pull/1234",
        "autoCreatePr": false
      },
      "summary": "Added README.md with installation instructions and usage examples",
      "createdAt": "2024-01-15T10:30:00Z"
    }
  ],
  "nextCursor": "bc_def456"
}

Authorizations

Authorization
string
header
required

API key from Cursor Dashboard

Query Parameters

limit
integer

Maximum number of background agents to return

Required range: 1 <= x <= 100
Example:

20

cursor
string

Pagination cursor from the previous response

Minimum length: 1
Example:

"bc_xyz789"

Response

200
application/json

Agents retrieved successfully

The response is of type object.