---
title: "List Secrets Across Environments"
method: GET
path: "/agents/{namespace_slug}/{agent_name}/secrets"
tags: ["Secrets"]
---

# List Secrets Across Environments

`GET /agents/{namespace_slug}/{agent_name}/secrets`

Cross-environment view of all secrets for an agent.

    Shows which keys exist in which environments.
    Never returns actual secret values (is_secret=True).
    Values for non-secrets only returned when include_values=True.

## Path parameters

- `namespace_slug` string, required
- `agent_name` string, required

## Query parameters

- `include_values` boolean — Include values for non-secrets (is_secret=False only)

## Response `200`

Successful Response

- CrossEnvSecretsListResponse — Cross-environment secrets view.
  - `all_environments` string[], required — All environment names for the agent
  - `variables` CrossEnvSecretResponse[], required — All secret keys across environments
    - `environments` EnvSecretInfo[], required — List of environments containing this key
      - `env_name` string, required — Environment name
      - `is_secret` boolean, required — Whether this is a secret in this environment
      - `updated_at` string, date-time, nullable — Last update timestamp
      - `value` string, nullable — Value for non-secrets (is_secret=False) only. Always None for secrets.
    - `is_secret` boolean, required — Whether this is a secret
    - `key` string, required — Secret key name
    - `value` string, nullable — Value for non-secrets (is_secret=False) only. Always None for secrets.

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/terminaluse/apis/sb0-api.md) · [All operations](https://skmtc.net/terminaluse/apis/sb0-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/terminaluse/sb0-api/revisions/f24a474dc415/schema)
