dbt-protos

1.0.443 · active · verified Sun Mar 29

dbt-protos is a Python library that provides public Protocol Buffer (proto) bindings for dbt. It serves as a central, 100% generated repository for dbt's public proto definitions, facilitating internal communication and metadata handling within the dbt ecosystem. Currently at version 1.0.443, its release cadence is closely tied to dbt Core and other related dbt libraries.

Warnings

Install

Imports

Quickstart

This quickstart demonstrates how to import and instantiate a generated Protocol Buffer message from `dbt-protos`. Since `dbt-protos` is primarily a binding library for internal dbt structures, direct end-user application logic using these protos is less common than other dbt libraries. This example uses a hypothetical 'Project' message from `dbt_common_pb2`.

from dbt_protos.dbt_common_pb2 import Project

# Instantiate a generated proto message (e.g., a 'Project' message)
project_message = Project(name="my_dbt_project", dbt_version="1.8.0")

print(f"Created dbt Project message: {project_message.name} (dbt version: {project_message.dbt_version})")

view raw JSON →