---
title: "List chat user prompts"
method: GET
path: "/api/v2/chats/{chat}/prompts"
tags: ["Chats"]
---

# List chat user prompts

`GET /api/v2/chats/{chat}/prompts`

Returns the user-authored prompts in a chat, newest first,
with each prompt's text parts concatenated in the order they
were authored. Used by the composer to power the up/down
arrow prompt-history cycle without paging through every
message in the chat.

## Path parameters

- `chat` string, uuid, required

## Query parameters

- `limit` integer

## Response `200`

OK

- CodersdkChatPromptsResponse
  - `prompts` CodersdkChatPrompt[]
    - `id` integer
    - `text` string

---

[API](https://skmtc.dev/coder/apis/coder-api.md) · [All operations](https://skmtc.dev/coder/apis/coder-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/coder/coder-api/revisions/bbfaa0a105e8/schema)
