---
title: "Get Agents"
method: GET
path: "/v1/agents"
tags: ["agents"]
---

# Get Agents

`GET /v1/agents`

Example usage:
```
curl -X GET "http://localhost:4000/v1/agents"       -H "Content-Type: application/json"       -H "Authorization: Bearer your-key"     ```

Pass `?health_check=true` to filter out agents whose URL is unreachable:
```
curl -X GET "http://localhost:4000/v1/agents?health_check=true"       -H "Content-Type: application/json"       -H "Authorization: Bearer your-key"     ```

Pass `?query=<task>` to get the best matching agents ranked by semantic similarity:
```
curl -X GET "http://localhost:4000/v1/agents?query=translate+a+PDF+document&top_k=5"       -H "Content-Type: application/json"       -H "Authorization: Bearer your-key"     ```

Returns: List[AgentResponse]

## Query parameters

- `health_check` boolean — When true, performs a GET request to each agent's URL. Agents with reachable URLs (HTTP status < 500) and agents without a URL are returned; unreachable agents are filtered out.
- `query` string, nullable — Describe the task in natural language to rank the agents you can reach by semantic similarity over their name, description, and skills. Each result carries a search_score. Requires litellm_settings.agent_search_embedding_model.
- `top_k` integer — With query: the maximum number of ranked agents to return.

## Response `200`

Successful Response

- AgentResponse[]
  - `agent_card_params` object, required
  - `agent_id` string, required
  - `agent_name` string, required
  - `created_at` string, date-time, nullable
  - `created_by` string, nullable
  - `extra_headers` string[], nullable
  - `keys` AgentKeySummary[], nullable
    - `key_alias` string, nullable
    - `key_name` string, nullable
    - `token` string, required
  - `litellm_params` object, nullable
  - `object_permission` object, nullable
  - `rpm_limit` integer, nullable
  - `search_score` number, nullable
  - `session_rpm_limit` integer, nullable
  - `session_tpm_limit` integer, nullable
  - `spend` number, nullable
  - `static_headers` object, nullable
  - `tpm_limit` integer, nullable
  - `updated_at` string, date-time, nullable
  - `updated_by` string, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-19** `c357baf422ab` — 2 info
  - api tag `agents` added
  - api tag `[beta] A2A Agents` removed
- **2026-09-18** `082b5fabd909` — 8 info
  - api tag `[beta] A2A Agents` added
  - api tag `agents` removed
  - added the new optional `query` request parameter `query`
  - added the new optional `query` request parameter `top_k`
  - …4 more
- **2026-09-15** `b408bdb637df` — 2 info
  - api tag `agents` added
  - api tag `[beta] A2A Agents` removed
- **2026-09-12** `0915d6a9ba99` — 2 info
  - api tag `[beta] A2A Agents` added
  - api tag `agents` removed
- **2026-09-11** `f9848f60f12d` — 2 info
  - api tag `agents` added
  - api tag `[beta] A2A Agents` removed

[Full history](https://skmtc.dev/flock/apis/litellm-api/changes/v1/agents/get.md)

---

[API](https://skmtc.dev/flock/apis/litellm-api.md) · [All operations](https://skmtc.dev/flock/apis/litellm-api/llms.txt) · [OpenAPI document](https://skmtc.dev/flock/apis/litellm-api/revisions/3b2b241e4b0b?raw)
