---
title: "Lists a feature's copy of the secrets"
method: GET
path: "/lambdas/{privateKey}/features/{feature}/secrets"
tags: ["Secrets"]
---

# Lists a feature's copy of the secrets

`GET /lambdas/{privateKey}/features/{feature}/secrets`

## Request

- Base URL: `https://genhttp.dev/api/v1`
- URL: `https://genhttp.dev/api/v1/lambdas/{privateKey}/features/{feature}/secrets`
- Auth: none declared

The copy its preview reads. The names the code reads are found in the feature's files.

## Path parameters

- `privateKey` string, required
- `feature` string, required

## Response `200`

The feature's secrets by name, and the names its code reads

- SecretListingResponse: The secrets of a lambda, or of a feature's copy of them, by name.
  - `Enabled` boolean: Whether the lambda has its secrets switched on (`PUT …/data/secrets`)
  - `Secrets` SecretResponse[]: What is stored, by name
    - `Name` string: What the code reads it by: `Secret.Read("STRIPE_KEY")`
    - `Created` string, date-time: When it was first stored
    - `Changed` string, date-time: When its value was last replaced
    - `Used` boolean: Whether the code reads it by that name
  - `Used` string[]: Every name the code reads with `Secret.Read("…")` or `Secret.Exists("…")` as a literal - in the version online and the newest one, or in the feature's files
  - `Missing` string[]: The names the code reads that have no value, and that it does not ask about with `Secret.Exists` first: what somebody still has to enter, or the code that reads them fails
  - `Optional` string[]: The names the code asks about with `Secret.Exists` that have no value: it does without them
  - `Limit` integer: How many secrets a lambda may keep

## Other responses

- `204`: A response containing no body
- `404`: No lambda has this editor key, or the lambda has no feature with this key: it never existed, or it was merged or deleted.

---

[API](https://skmtc.dev/genhttp/apis/genhttp-lambda-api.md) · [All operations](https://skmtc.dev/genhttp/apis/genhttp-lambda-api/llms.txt) · [OpenAPI document](https://skmtc.dev/genhttp/apis/genhttp-lambda-api/revisions/8b36699e03df?raw)
