branch_configs
Creates, updates, deletes, gets or lists a branch_configs resource.
Overview​
| Name | branch_configs |
| Type | Resource |
| Id | supabase.branches.branch_configs |
Fields​
The following fields are returned by SELECT queries:
- get
| Name | Datatype | Description |
|---|---|---|
db_host | string | |
db_pass | string | |
db_port | integer | |
db_user | string | |
jwt_secret | string | |
postgres_engine | string | |
postgres_version | string | |
ref | string | |
release_channel | string | |
status | string | (INACTIVE, ACTIVE_HEALTHY, ACTIVE_UNHEALTHY, COMING_UP, UNKNOWN, GOING_DOWN, INIT_FAILED, REMOVED, RESTORING, UPGRADING, PAUSING, RESTORE_FAILED, RESTARTING, PAUSE_FAILED, RESIZING) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | branch_id_or_ref, ref | Fetches configurations of the specified database branch |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
branch_id_or_ref | | Branch ref or deprecated branch ID |
ref | string | Supabase project reference (the Project ID shown in the dashboard under Settings -> General; 20 lowercase letters). Resolved from the SUPABASE_PROJECT_ID environment variable when it is set (x-stackQL-envVar); otherwise it must be supplied on every project-scoped query as WHERE ref = '<ref>'. A WHERE value always takes precedence over the environment. (x-stackQL-envVar: SUPABASE_PROJECT_ID) |
SELECT examples​
- get
Fetches configurations of the specified database branch
SELECT
db_host,
db_pass,
db_port,
db_user,
jwt_secret,
postgres_engine,
postgres_version,
ref,
release_channel,
status
FROM supabase.branches.branch_configs
WHERE branch_id_or_ref = '{{ branch_id_or_ref }}' -- required
AND ref = '{{ ref }}' -- required unless SUPABASE_PROJECT_ID is set
;