> For the complete documentation index, see [llms.txt](https://docs.superuser.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.superuser.app/agents/getting-started-with-agents/secrets-and-security.md).

# Secrets and security

Some tools require **secrets** like API keys or database passwords in order to be used correctly.

* Only **open source** tools can request secrets
* You can **always** inspect the code that you share your secrets with
* If package code changes, **your installation will be invalidated**, so your agent will **never** run untrusted code with your secrets
* Secrets are stored on an **API keychain** which only exposes secrets **specifically requested** by the tool, which is set by the developer.

To manage secrets, first find a package that requires secrets like **PostgreSQL**:

<figure><img src="/files/3apSVEeAjZ4uOvtHDVml" alt=""><figcaption></figcaption></figure>

Click **\[ Install ]**. If the package requires secrets, a new **Keychain** tab will appear:

<figure><img src="/files/vBpFhjPE5CZlmdPjfCPN" alt=""><figcaption></figcaption></figure>

Click this tab to view your API keychain.

<figure><img src="/files/PLk4xtvLZsRNEVxUON4N" alt=""><figcaption></figcaption></figure>

Here you can save your secrets. **If a secret is not required, just save the empty textbox**. For example, in the PostgreSQL example above, PG\_SSH\_TUNNEL\_URL and PG\_SSH\_TUNNEL\_PRIVATE\_KEY can be saved as empty strings if the connection URL does not require a proxy.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.superuser.app/agents/getting-started-with-agents/secrets-and-security.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
