The External Secrets Enterprise product suite is a premium product.
It requires a specific subscription. Contact us for more information.
It requires a specific subscription. Contact us for more information.
To use the SendGrid API Key Generator, you must have the Enterprise Distribution of ESO available via ESI Agent or via our Helm chart bundle
Introduction
The SendGrid Generator automatically provisions scoped API keys for your applications using the SendGrid Admin API.It eliminates the need for manually creating and managing API tokens in the SendGrid dashboard, enabling fine-grained access and secure rotation via ESO. This generator is especially useful when isolating credentials across services or tenants and when ensuring secure deletion of unused API tokens during cleanup.
Output Keys and Values
Key | Description |
---|---|
apiKey | The generated SendGrid API key (SG.x... ) |
Parameters
Key | Default | Description |
---|---|---|
dataResidency | global | Optional value to control SendGrid’s data residency location ("global" , "eu" ). |
scopes | [] | List of scopes to apply to the API key. See SendGrid docs for options. |
auth.secretRef.apiKeySecretRef | Required | Secret containing the Admin API Key with permission to manage API keys. |
Set up
Requirements
- You must have an existing SendGrid Admin API Key with permission to create and delete API keys.
- The generator uses the
/v3/api_keys
endpoint to create and rotate keys.
Admin API Key Secret
Example of a Kubernetes secret holding your Admin API Key:Generator Config
ExternalSecret Config
Using the Generated Secret
Notes and Considerations
- Only one API key is created per rotation cycle. Old keys are deleted during cleanup.
- The
dataResidency
value is used to control which SendGrid API region is used (e.g.,"eu"
for EU data residency). - API keys are uniquely named using a generated label (e.g.,
Managed By ESO Generator: <name> <UID>
).