---
title: "GET /api/{org_id}/gen_ai/agents"
method: GET
path: "/api/{org_id}/gen_ai/agents"
tags: ["GenAI Settings"]
---

# GET /api/{org_id}/gen_ai/agents

`GET /api/{org_id}/gen_ai/agents`

## Request

- Base URL: `https://api.openobserve.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.openobserve.ai/api/{org_id}/gen_ai/agents`
- Auth: API key in header `Authorization`
- TypeScript: <https://skmtc.dev/openobserve/apis/openobserve-api-http/docs/api/:org_id/gen_ai/agents/get.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `org_id` string, required

## Query parameters

- `start_time` integer, nullable
- `end_time` integer, nullable
- `from` integer
- `size` integer
- `source_stream` string, nullable
- `source_stream_type` string, nullable

## Response `200`

Discovered Gen-AI agents

- GenAiAgentListResponse: Paginated Gen-AI agent list response.
  - `agents` GenAiAgentListItem[], required: Agents in the requested page.
    - `env` string, nullable: Environment the agent was observed in (e.g. production), when available.
    - `first_seen` integer, nullable: Epoch-microseconds of the agent's first observed span, when available.
    - `id` string, nullable: Stable agent id when source telemetry provided one.
    - `last_seen` integer, nullable: Epoch-microseconds of the agent's most recent observed span, when available.
    - `name` string, required: Display name for the agent. Falls back to the agent id when no name is available.
    - `source_stream` string, required: Source stream where the agent was observed.
    - `source_stream_type` string, required: Source stream type where the agent was observed.
    - `version` string, nullable: Agent (or service) version the agent was observed at, when available.
  - `total` integer, required: Total number of agents after filtering and authorization.

## Other responses

- `400`: Invalid time range
- `401`: Unauthorized
- `500`: Internal server error

---

[API](https://skmtc.dev/openobserve/apis/openobserve-api-http.md) - [All operations](https://skmtc.dev/openobserve/apis/openobserve-api-http/llms.txt) - [OpenAPI document](https://skmtc.dev/openobserve/apis/openobserve-api-http/revisions/0529b8a10252?raw)
