Dbt CheckStatus

Dbt CheckStatus

Certified

Monitor a dbt Cloud run

Polls a dbt Cloud run until it ends, streaming step logs and downloading artifacts. Takes a runId, or a jobId or environmentId to read the most recent successful run of that job or environment, which keeps lineage fresh for runs Kestra did not trigger. Fails on non-successful statuses unless failOnUnsuccessful is false. Defaults to 5s polling and a 60m timeout.

yaml
type: io.kestra.plugin.dbt.cloud.CheckStatus
yaml
id: dbt_check_status
namespace: company.team

tasks:
  - id: check_status
    type: io.kestra.plugin.dbt.cloud.CheckStatus
    accountId: "12345"
    token: "{{ secret('DBT_TOKEN') }}"
    runId: "98765"

Refresh lineage on a schedule from the most recent finished run of a dbt Cloud job, including runs Kestra did not trigger.

yaml
id: dbt_lineage_refresh
namespace: company.team

triggers:
  - id: hourly
    type: io.kestra.plugin.core.trigger.Schedule
    cron: "0 * * * *"

tasks:
  - id: refresh_lineage
    type: io.kestra.plugin.dbt.cloud.CheckStatus
    accountId: "12345"
    token: "{{ secret('DBT_TOKEN') }}"
    jobId: "4321"
    assets:
      enableAuto: true
Properties

Numeric ID of the account

The numeric dbt Cloud account ID, visible in the account settings and in the dbt Cloud URL.

API token

A dbt Cloud API token (a Service Account token or a Personal Access token); sent as a Bearer token.

Defaulthttps://cloud.getdbt.com

Base URL to select the tenant

The access URL for your dbt Cloud account. Regional and cell-based accounts use a URL of the form ACCOUNT_PREFIX.REGION.dbt.com, not the legacy cloud.getdbt.com host, which no longer resolves tokens for these accounts and returns a 401 error even with a valid token.

Environment ID

dbt Cloud environment identifier. Reads the most recent successful run anywhere in that environment, whichever job produced it. dbt's manifest covers the whole project, so any run refreshes the full graph. Mutually exclusive with runId and jobId.

Defaulttrue

Fail if the run ends in a non-successful state

When true (default), a run ending in Error or Cancelled raises a task failure. Set to false to read a run without failing the task, which matters when a runId is pinned on a schedule. jobId and environmentId resolve successful runs only, so it does not apply there.

Default1000

Initial delay in milliseconds before retrying

Default: 1000 ms (1 second)

Job ID

dbt Cloud job identifier. Reads that job's most recent successful run, which refreshes lineage for runs triggered outside Kestra. Mutually exclusive with runId and environmentId.

DefaultPT1H

Max wait duration

Upper bound for waiting on completion. Default 60m.

Default3

Maximum number of retries in case of transient errors

Default: 3

The HTTP client configuration

Definitions
allowFailedbooleanstring
Defaultfalse

If true, allow a failed response code (response code >= 400)

allowedResponseCodesarray
SubTypeinteger

List of response code allowed for this request

auth

The authentication to use.

type*Requiredobject
passwordstring

The password for HTTP basic authentication.

usernamestring

The username for HTTP basic authentication.

type*Requiredobject
tokenstring

The token for bearer token authentication.

type*Requiredobject
passwordstring

The password for HTTP Digest authentication.

usernamestring

The username for HTTP Digest authentication.

defaultCharsetstring
DefaultUTF-8

The default charset for the request.

enabledTcpExtendedKeepAlivebooleanstring
Defaulttrue

Whether to enable TCP Keep-Alive extended socket options (TCP_KEEPIDLE, TCP_KEEPINTERVAL, TCP_KEEPCOUNT).

Set to false when running on Windows workers, as these extended socket options are not supported by the Windows JDK and will cause connection failures.

followRedirectsbooleanstring
Defaulttrue

Whether redirects should be followed automatically.

logsarray
SubTypestring
Possible Values
REQUEST_HEADERSREQUEST_BODYRESPONSE_HEADERSRESPONSE_BODY

The enabled log.

proxy

The proxy configuration.

addressstring

The address of the proxy server.

passwordstring

The password for proxy authentication.

portintegerstring

The port of the proxy server.

typestring
DefaultDIRECT
Possible Values
DIRECTHTTPSOCKS

The type of proxy to use.

usernamestring

The username for proxy authentication.

ssl

The SSL request options

insecureTrustAllCertificatesbooleanstring

Whether to disable checking of the remote SSL certificate.

Only applies if no trust store is configured. Note: This makes the SSL connection insecure and should only be used for testing. If you are using a self-signed certificate, set up a trust store instead.

timeout

The timeout configuration.

connectTimeoutstring

The time allowed to establish a connection to the server before failing.

readIdleTimeoutstring
DefaultPT5M

The time allowed for a read connection to remain idle before closing it.

Defaulttrue

Parse run results

If true (default), parses run_results.json to expose node timings; otherwise uploads the artifact as-is.

DefaultPT5S

Poll frequency

Interval between status checks while waiting. Default 5s.

Run ID

dbt Cloud run identifier to monitor. Mutually exclusive with jobId and environmentId.

SubTypestring

Assets

Asset ids described by the run's manifest, whether or not lineage was emitted.

Defaultfalse

Lineage emitted

True when this execution emitted the run's asset lineage, false when it had already been emitted for this run.

Formaturi

Manifest URI

Internal storage URI for the downloaded manifest.json, when present.

Run ID

Identifier of the dbt Cloud run that was read.

Formaturi

Run results URI

Internal storage URI for the downloaded run_results.json, when present.