Agent Builder provides Vault, which is a secure way to store and use secrets in your agents. Use Vault to store sensitive information like API keys, passwords, and other credentials. You can reference secrets in any block in your blueprint and within Python code.Documentation Index
Fetch the complete documentation index at: https://dev.writer.com/llms.txt
Use this file to discover all available pages before exploring further.

Create a secret
Secrets are strings stored as key-value pairs. To create a secret, go to the Vault tab in the Agent Builder UI and click +Add a pair. The example below creates a secret with the nameWRITER_API_KEY. When you type the value, it’s masked in the UI.
Click Save to store the secret.

Use a secret
To use a secret, reference it in a block in your blueprint with the prefix@{vault}. For example, to use the WRITER_API_KEY secret, you would use it as @{vault.WRITER_API_KEY}.
The example below shows adding an authorization header to an HTTP request block using the WRITER_API_KEY secret.


Use a secret in Python code
You can access secrets in Python code blocks within blueprints using thevault object. vault is a dictionary that contains all the secrets in your blueprint.
For example, to access a secret called API_KEY and use it in an HTTP request, you would use the following code:
Next steps
Now that you’ve learned how to store and use secrets in Vault, learn how to make authenticated API calls using HTTP request blocks with your stored credentials. More resources- Access secrets in Python code - Learn how to use vault secrets in event handlers and Python code blocks
- Python code blocks - Add custom Python logic to your blueprints
- Local development - Set up local development with environment variables