---
title: "Set branch dbt environment"
method: POST
path: "/api/v1/models/{modelId}/branch/{branchName}/dbt"
tags: ["Models"]
---

# Set branch dbt environment

`POST /api/v1/models/{modelId}/branch/{branchName}/dbt`

Set the active dbt environment on a branch.

## Path parameters

- `modelId` string, uuid, required — Model UUID
- `branchName` string, required — Branch name

## Request body

- ModelsBranchDbtBody
  - `dbt_environment_id` string, uuid, required — ID of the dbt environment to activate on this branch
  - `dbt_git_branch` string — Git branch to associate with the dbt environment

## Response `200`

dbt environment set successfully

- SuccessResponse
  - `success` boolean, required — Whether the operation was successful

## Other responses

- `400` — Invalid request body
- `401` — Authentication required
- `403` — Permission denied
- `404` — Model or branch not found

---

[API](https://skmtc.net/omniapp/apis/omni-api.md) · [All operations](https://skmtc.net/omniapp/apis/omni-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/omniapp/omni-api/versions/de7cac8b5983/schema)
