---
title: "ListSecrets"
method: POST
path: "/gitpod.v1.SecretService/ListSecrets"
tags: ["gitpod.v1.SecretService"]
---

# ListSecrets

`POST /gitpod.v1.SecretService/ListSecrets`

Lists secrets

 Use this method to:
 - View all project secrets
 - View all user secrets

 ### Examples

 - List project secrets:

   Shows all secrets for a project.

   ```yaml
   filter:
     scope:
       projectId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
   pagination:
     pageSize: 20
   ```

 - List user secrets:

   Shows all secrets for a user.

   ```yaml
   filter:
     scope:
       userId: "123e4567-e89b-12d3-a456-426614174000"
   pagination:
     pageSize: 20
   ```

## Query parameters

- `pageSize` integer
- `token` string

## Request body

- GitpodV1ListSecretsRequest
  - `filter` GitpodV1ListSecretsRequestFilter — unresolved $ref
  - `pagination` GitpodV1PaginationRequest
    - `pageSize` integer — Page size is the maximum number of results to retrieve per page. Defaults to 25. Maximum 100.
    - `token` string — Token for the next set of results that was returned as next_token of a PaginationResponse

## Response `200`

Success

- GitpodV1ListSecretsResponse — unresolved $ref

## Other responses

- `default` — Error

## Changes

- **2026-07-30** `44d50c2ac284` — 2 info
  - added the optional property `secrets/items/credentialProxy` to the response with the `200` status
  - added the optional property `secrets/items/source` to the response with the `200` status
- **2026-04-02** `dabc0ff98cd7` — 1 info
  - removed the `PRINCIPAL_AGENT_EXECUTION` enum value from the `secrets/items/creator/principal` response property for the response status `200`
- **2026-01-21** `2423c089f280` — 2 breaking, 4 info
  - removed `subschema #1, subschema #2, subschema #3` from the `filter/scope` request property `oneOf` list
  - added `subschema #1, subschema #2, subschema #3, subschema #4` to the `secrets/items/scope` response property `oneOf` list for the response status `200`
  - added the new optional request property `filter/scope/serviceAccountId`
  - added `subschema #1, subschema #2, subschema #3, subschema #4` to the `filter/scope` request property `oneOf` list
  - …2 more
- …earlier changes not shown

[Full history](https://skmtc.dev/gitpod-io/apis/gitpod-v1/changes/gitpod.v1.SecretService/ListSecrets/post.md)

---

[API](https://skmtc.dev/gitpod-io/apis/gitpod-v1.md) · [All operations](https://skmtc.dev/gitpod-io/apis/gitpod-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/gitpod-io/gitpod-v1/revisions/44d50c2ac284/schema)
