---
title: "Get dbt source"
method: GET
path: "/api/v1/projects/{projectUuid}/dbt-sources/{projectDbtSourceUuid}"
tags: ["Projects"]
---

# Get dbt source

`GET /api/v1/projects/{projectUuid}/dbt-sources/{projectDbtSourceUuid}`

Get a single dbt source including its connection, with credentials
stripped — used to pre-fill the edit form.

## Path parameters

- `projectUuid` string, uuid, required — Stringified UUIDv4. See [RFC 4112](https://tools.ietf.org/html/rfc4122)
- `projectDbtSourceUuid` string, uuid, required — Stringified UUIDv4. See [RFC 4112](https://tools.ietf.org/html/rfc4122)

## Response `200`

Success

- ApiProjectDbtSourceWithConnectionResponse
  - `results` ProjectDbtSourceWithConnection, required — A single dbt source including its connection, with sensitive credentials (tokens, keys) stripped — used to pre-fill the edit form. Secrets left out here are preserved on update via `mergeMissingDbtConfigSecrets`.
    - `hasCredentialError` boolean, required
    - `projectSubPath` string, nullable, required
    - `branch` string, nullable, required
    - `repository` string, nullable, required
    - `type` 'dbt' | 'dbt_cloud_ide' | 'github' | 'gitlab' | 'bitbucket' | 'azure_devops' | 'none' | 'manifest', required
    - `precedence` number, double, required
    - `isPrimary` boolean, required
    - `name` string, required
    - `projectDbtSourceUuid` string, required
    - `dbtConnection` union, required
      - DbtLocalProjectConfig
        - `type` 'dbt', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `profiles_dir` string
        - `project_dir` string
      - DbtCloudIDEProjectConfig
        - `type` 'dbt_cloud_ide', required
        - `api_key` string, required
        - `environment_id` string, required
        - `discovery_api_endpoint` string
        - `tags` string[]
        - `webhook_hmac_secret` string
      - DbtGithubProjectConfig
        - `type` 'github', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `authorization_method` 'personal_access_token' | 'installation_id', required
        - `personal_access_token` string
        - `installation_id` string
        - `repository` string, required
        - `branch` string, required
        - `project_sub_path` string, required
        - `host_domain` string
      - DbtBitBucketProjectConfig
        - `type` 'bitbucket', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `username` string, required
        - `personal_access_token` string, required
        - `repository` string, required
        - `branch` string, required
        - `project_sub_path` string, required
        - `host_domain` string
      - DbtGitlabProjectConfig
        - `type` 'gitlab', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `personal_access_token` string, required
        - `repository` string, required
        - `branch` string, required
        - `project_sub_path` string, required
        - `host_domain` string
      - DbtAzureDevOpsProjectConfig
        - `type` 'azure_devops', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `personal_access_token` string, required
        - `organization` string, required
        - `project` string, required
        - `repository` string, required
        - `branch` string, required
        - `project_sub_path` string, required
      - DbtNoneProjectConfig
        - `type` 'none', required
        - `target` string
        - `environment` DbtProjectEnvironmentVariable[]
          - `value` string, required
          - `key` string, required
        - `selector` string
        - `hideRefreshButton` boolean
      - DbtManifestProjectConfig
        - `type` 'manifest', required
        - `manifest` string, required
        - `hideRefreshButton` boolean, required
  - `status` 'ok', required

## Other responses

- `default` — Error

---

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