---
title: "List versions of an Agent Observability prompt"
method: GET
path: "/api/v2/llm-obs/v1/prompts/{prompt_id}/versions"
tags: ["Agent Observability"]
---

# List versions of an Agent Observability prompt

`GET /api/v2/llm-obs/v1/prompts/{prompt_id}/versions`

## Request

- Base URL: `https://api.datadoghq.com`
- URL: `https://api.datadoghq.com/api/v2/llm-obs/v1/prompts/{prompt_id}/versions`
- Auth: one of:
  - API key in header `DD-API-KEY` and API key in header `DD-APPLICATION-KEY`
  - OAuth 2
    - Authorization code: `/oauth2/v1/authorize`
    - Token URL: `/oauth2/v1/token`
- TypeScript: <https://skmtc.dev/datadog/apis/datadog-api-v2-collection/docs/api/v2/llm-obs/v1/prompts/:prompt_id/versions/get.ts> (a function with typed inputs; its response is checked against the schema)

List all versions of an Agent Observability prompt, ordered newest to oldest. If the prompt does not exist, is not registered, or is archived, the response contains an empty list.

## Path parameters

- `prompt_id` string, required

## Response `200`

OK

- LLMObsPromptVersionsResponse: Response containing the versions of an Agent Observability prompt.
  - `data` LLMObsPromptVersionListData[], required: Prompt versions ordered from newest to oldest.
    - `attributes` LLMObsPromptVersionListDataAttributes, required: Attributes of a prompt version returned in a list, excluding its template.
      - `author` string: UUID of the user who authored this version.
      - `created_at` string, date-time: Timestamp stored on this prompt version.
      - `datasets` LLMObsPromptDataset[]: Datasets observed in runs associated with this prompt version.
        - `id` string, required: Unique identifier of the dataset.
        - `name` string: Name of the dataset.
      - `description` string: Description of this version.
      - `labels` string[]: Labels attached to this version (for example `development`, `staging`, `production`).
      - `last_seen_at` string, date-time: Timestamp of the most recent observed run of this prompt version.
      - `ml_app` string: The ML application this prompt is associated with.
      - `ml_apps` string[]: ML applications observed running this prompt version.
      - `prompt_id` string, required: Customer-provided identifier of the parent prompt.
      - `prompt_uuid` string, required: Unique identifier of the parent prompt.
      - `tags` string[]: Tags observed on runs of this prompt version.
      - `user_version` string: User-supplied identifier for this version.
      - `version` integer, required: Sequential version number.
      - `version_created_at` string, date-time: Timestamp when this version was created.
    - `id` string, required: Unique identifier of the prompt version.
    - `type` 'prompt-template-versions', required: Resource type of an Agent Observability prompt version.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `429`: Too many requests

---

[API](https://skmtc.dev/datadog/apis/datadog-api-v2-collection.md) - [All operations](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/llms.txt) - [OpenAPI document](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/revisions/3f70db624329?raw)
