---
title: "List project secrets (metadata only — values never returned), newest first."
method: GET
path: "/projects/{project_id}/secrets"
tags: ["Secrets"]
---

# List project secrets (metadata only — values never returned), newest first.

`GET /projects/{project_id}/secrets`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/projects/{project_id}/secrets`
- Auth: HTTP bearer

## Path parameters

- `project_id` integer, required

## Query parameters

- `environment_id` integer
- `page` integer
- `page_size` integer

## Response `200`

One page of secrets (metadata only, no values), newest first

- ProjectSecretList: One page of a project's secrets (metadata only), newest first.
  - `items` ProjectSecretResponse[], required: The items on this page.
    - `compose_services` string[], required: Compose services this secret is restricted to. Empty means every service in the stack.
    - `created_at` string, date-time, required
    - `environments` ProjectSecretEnvironmentInfo[], required
      - `id` integer, required
      - `main_url` string, required
      - `name` string, required
    - `id` integer, required
    - `include_in_preview` boolean, required
    - `key` string, required
    - `project_id` integer, required
    - `updated_at` string, date-time, required
  - `page` integer, required: The page served, starting at 1.
  - `page_size` integer, required: The page size served (at most 100).
  - `total` integer, required: Items across all pages.

## Other responses

- `401`: Unauthorized
- `403`: Insufficient permissions
- `404`: Project not found
- `500`: Internal server error

## Changes

- **2026-11-26** `e1864d950604`: 1 breaking, 8 info
  - the response's body type changed from `array` to `object` for status `200`
  - added the new optional `query` request parameter `page`
  - added the new optional `query` request parameter `page_size`
  - added the non-success response with the status `401`
  - …5 more
- **2026-11-25** `480a86944327`: 1 info
  - the endpoint scheme security `bearer_auth` was added to the API
- **2026-09-07** `cdc1afae1752`: 1 info
  - added the required property `items/compose_services` to the response with the `200` status
- **2026-09-07** `f7404eb7ac98`: 1 breaking
  - removed the required property `items/compose_services` from the response with the `200` status
- **2026-08-17** `bd326cf0ea13`: 1 info
  - added the required property `items/compose_services` to the response with the `200` status

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/projects/:project_id/secrets/get.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
