---
title: "Get agents for an organization"
method: GET
path: "/v1/{organization}/organization/agent"
tags: ["Organization"]
---

# Get agents for an organization

`GET /v1/{organization}/organization/agent`

Return a list of agents for the organization.

#### Permissions
This endpoint may be impacted by the following permissions:
* Only agents that the authenticated user has the `Organization:GetAgent` permission on will be returned.

## Path parameters

- `organization` string, required

## Query parameters

- `deprecated` boolean, nullable — Whether the agent is deprecated.
- `id` string[] — The IDs of the agents to filter for.
- `limit` integer — The maximum number of agents to return.
- `continuation_token` integer — The continuation token from the previous request used to retrieve the next page of agents.

## Headers

- `x-mongo-cluster-name` string, nullable — The Mongo cluster name to perform this request in. This is usually not needed unless the organization does not exist yet in the Amigo organization infra config database.
- `Sec-WebSocket-Protocol` string[]

## Response `200`

Succeeded.

- SrcAppEndpointsOrganizationGetAgentsResponse
  - `agents` SrcAppEndpointsOrganizationGetAgentsResponseAgentInstance[], required — The agents for this organization.
    - `id` string, required — The ID of the agent.
    - `name` string, required — The name of the agent.
    - `deprecated` boolean, required — Whether the agent has been deprecated.
    - `latest_version` integer, nullable, required — The latest version of the agent. If `None`, no version for the agent exists.
  - `has_more` boolean, required — Whether there are more agents to retrieve.
  - `continuation_token` integer, nullable, required — A token to supply to the next request to retrieve the next page of agents. Only populated if `has_more` is `True`.

## Other responses

- `401` — Invalid authorization credentials.
- `403` — Missing required permissions.
- `404` — The specified organization does not exist.
- `422` — Invalid request path parameter or query parameter failed validation.
- `429` — The user has exceeded the rate limit of 20 requests per minute for this endpoint.
- `503` — The service is going through temporary maintenance.

---

[API](https://skmtc.net/amigo/apis/amigo-api.md) · [All operations](https://skmtc.net/amigo/apis/amigo-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/amigo/amigo-api/revisions/f0f28319e448/schema)
