Update dbt environment
The permissions required depend on who owns the environment:
- Your own personal environment - Restricted Querier permissions or higher on the connection
- A shared environment - Connection Admin or Organization Admin permissions
- Another user’s personal environment - Organization Admin permissions
Update an existing dbt environment on the specified connection. This request replaces the environment: name and targetSchema are required, and any omitted optional field is reset to its default. In particular, omitting ownerId sets it to null, which converts the environment to a shared one and requires Connection Admin permissions - send your own user ID when updating your own environment.
Authorizations
Can be either an Organization API Key or Personal Access Token (PAT).
Include in the Authorization header as: Bearer YOUR_TOKEN
Path Parameters
The unique identifier of the connection
The unique identifier of the dbt environment
Body
The name of the dbt environment
1"Development"
The target schema for the environment
1"dev_schema"
Whether deferral is enabled for this environment. Ignored (forced to false) for the default (production) environment.
true
Defines the owner of the environment, which also determines whether the environment is personal or shared. Defaults to null when omitted, so always send the current owner's ID unless you intend to change it.
- Personal environment - Use the ID of the user that owns the environment. Organization Admin permissions are required to set the ID of a user other than the authenticating user.
- Shared environment - Set to
null. Requires Connection Admin or Organization Admin permissions.
"550e8400-e29b-41d4-a716-446655440000"
Target database override
"analytics_dev"
Target name override
"custom_target"
Target role override
"developer"
Environment variables for the dbt environment. To update existing variables, include the variable id field. New variables should omit the id field.
Response
dbt environment updated successfully
Unique identifier of the dbt environment
The name of the dbt environment
Whether this is the default environment
Whether deferral is enabled for this environment. Ignored (forced to false) for the default (production) environment.
The user ID of the owner of the dbt environment, or null
Target database override
Target name override
Target role override
Target schema for the environment
Environment variables

