Skip to main content
For the complete documentation index for agents and LLMs, see llms.txt.

Add Secrets to a ServiceBeta

Beta
This is coming — this page describes a feature that's still being rolled out and may not be available to you yet.

Add a secret to a service when only that service needs a credential, for example a production API key. A service secret overrides workspace and organization secrets with the same name, so you can give one service its own key without changing what other services use. The secret name must match the environment variable that the pipeline component reads.


Prerequisites​

  • You must have permission to read secrets to see the Secrets tab, and permission to write secrets to create, edit, or delete them.
  • You must have a service that runs in serverless mode. If the service is a managed service, the Secrets tab shows a warning that service secrets aren't applied yet.
  • To see how secrets at different levels relate, see Secrets and Integrations.

Create a Service Secret​

  1. In Haystack Enterprise Platform, click Gateway and open the service.
  2. Click Secrets.
  3. Click Create Secret.
  4. In Key, type the secret name, for example OPENAI_API_KEY. Use only letters, numbers, and underscores, and start with a letter or an underscore.
  5. In Value, enter the secret value.
  6. Click Create.

The secret appears in the list with its Key, masked Value, Last updated date, and Created by user. The service uses it the next time it runs. The secret isn't listed in workspace or organization settings.

Edit or Delete a Service Secret​

  1. Open the service and click Secrets.
  2. In the secret's row, choose the edit or delete action.
  3. Save your changes, or confirm the deletion.

If you delete a service secret and a workspace or organization secret with the same name exists, the service uses that secret instead.

What To Do Next​