Skip to main content

:::note Generated reference Generated from honeyframeapi 0.1.8 — do not edit by hand. :::

honeyframeapi.dbt

dbt authoring through the API — build the warehouse from code, no SSH/psql.

On a dbt-engine project, the right way to develop (create tables, transformations, models) is to author dbt models through the platform's dbt API rather than running raw DDL. This handle wraps /api/dbt/* so a script (or a vibe-coder) can write, version, compile, and run dbt models entirely through the governed API:

dbt = client.get_project(1).dbt
dbt.write_file("models/staging/stg_orders.sql",
"select * from {{ source('erp','orders') }}")
dbt.run(select="stg_orders+")
print(dbt.list_models())

For a fresh model with scaffolding (dataset registration, schema yml), prefer create_model. Git ops (git_status/git_commit) version the changes. Most dbt endpoints require org-admin on the platform.

class DbtIDE​

DbtIDE.list_files()​

list_files(directory: str = 'models') -> dict

File tree under a dbt directory (models|macros|tests|seeds|…).

DbtIDE.list_all_files()​

list_all_files() -> dict

DbtIDE.read_file()​

read_file(path: str) -> dict

Read a dbt file: {path, content, size_bytes, modified}.

DbtIDE.write_file()​

write_file(path: str, content: str) -> dict

Create/overwrite a dbt file (auto-registers models in the catalog, auto-commits on the shared workspace). Same endpoint the platform's dbt editor saves through.

DbtIDE.delete_file()​

delete_file(path: str) -> dict

DbtIDE.create_model()​

create_model(name: str, *, schema_name: str = 'staging', sql: str = '', description: str = '', depends_on: Optional[list] = None, recipe_type: str = '') -> dict

Scaffold a new dbt model (layer ∈ staging|intermediate|marts). Registers the dataset + source yml; returns {name, path, schema, sql}.

DbtIDE.list_models()​

list_models() -> list[dict]

DbtIDE.model_names()​

model_names() -> dict

DbtIDE.compile()​

compile(path: str) -> dict

Compile one model to resolved SQL (compiled_sql in the response).

DbtIDE.project_info()​

project_info() -> dict

DbtIDE.execute()​

execute(command: str = 'run', *, select: Optional[str] = None) -> dict

Run a dbt command (run|test|compile|build|seed|snapshot|deps|ls). Returns {success, return_code, output, duration_seconds, command}.

DbtIDE.run()​

run(*, select: Optional[str] = None) -> dict

DbtIDE.test()​

test(*, select: Optional[str] = None) -> dict

DbtIDE.build()​

build(*, select: Optional[str] = None) -> dict

DbtIDE.runs()​

runs(*, limit: int = 50) -> list[dict]

DbtIDE.git_status()​

git_status() -> dict

DbtIDE.git_commit()​

git_commit(message: str, *, files: Optional[list] = None, push: bool = False) -> dict

DbtIDE.git_push()​

git_push() -> dict

Verified against honeyframeapi 0.1.8.