Repository navigation
Description
Description
Currently, the Google Secret Manager backend (GoogleCloudSecretManagerBackend) expects Airflow connections to be stored as URI-encoded strings.
For complex Google Cloud Platform connections, particularly those involving service account credentials, the URI format can become difficult to read, validate, and maintain. In contrast, the AWS Secrets Manager backend supports storing Google connections as structured JSON objects, which significantly improves readability and operability.
Current behavior
GoogleCloudSecretManagerBackend expects secrets in Airflow connection URI format, for example:
google-cloud-platform://?key_path=%2Fkeys%2Fsa.json&project=my-project
This becomes increasingly difficult to manage when handling multiple connection extras and nested configuration values.
Proposed behavior
Allow GoogleCloudSecretManagerBackend to optionally accept a JSON representation of an Airflow connection, similar to the format supported by the AWS Secrets Manager backend.
For example:
{
"conn_type": "google_cloud_platform",
"extra": {
"project": "my-project",
"key_path": "/keys/sa.json",
"scope": "https://www.googleapis.com/auth/cloud-platform"
}
}
Use case/motivation
The AWS Secrets Manager backend already supports JSON-formatted connections, while the Google Secret Manager backend currently requires URI-encoded connection strings.
Supporting JSON in both backends would:
- Provide a more consistent developer experience across cloud-native secrets backends
- Improve readability and maintainability of complex connection configurations
- Simplify secret rotation and manual management
- Reduce the risk of URI encoding and escaping errors
- Improve handling of large extra payloads and complex configuration objects
- Make migrations between SecretsManagerBackend and GoogleCloudSecretManagerBackend simpler
Aligning the connection formats would reduce friction for teams operating across multiple cloud providers and make Airflow secrets management more intuitive and predictable.
Related issues
No response
Are you willing to submit a PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
Activity
kartik00052 commentedon Nov 6, 2026
I want to work on this issue