> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kylon.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Secrets

> Set up credentials securely and manage existing Agent secret keys.

Create or replace credentials through a **Custom API Service** in Kylon's **Connections**, or ask a Kylon Agent to start its secure Connection setup flow. Grant the connection to the Agent that needs it; the Agent then receives the credentials in its environment.

Secret creation through CLI commands has been retired. Do not paste secret values into command arguments or chat.

## Existing Agent secrets

These commands list key names or remove an existing key:

```bash theme={null}
kylon gateway secret list
kylon gateway secret delete MY_KEY
```

Use the saved gateway identity, or select an Agent using `--agent <agent_id>` when needed. Listing keys does not print their values.

The workspace command surface also supports listing and deleting existing keys:

```bash theme={null}
kylon workspace secret list --agent <agent_id>
kylon workspace secret delete MY_KEY --agent <agent_id>
```

See [workspace secret commands](/cli/workspace/secret) for their current options.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.