Type object
File match **/*dbt*/macros/**/*.yaml **/*dbt*/macros/**/*.yml **/*dbt*/models/**/*.yaml **/*dbt*/models/**/*.yml **/*dbt*/seeds/**/*.yaml **/*dbt*/seeds/**/*.yml **/*dbt*/snapshots/**/*.yaml **/*dbt*/snapshots/**/*.yml
Schema URL https://catalog.lintel.tools/schemas/schemastore/dbt-yaml-files/latest.json
Source https://raw.githubusercontent.com/dbt-labs/dbt-jsonschema/main/schemas/latest/dbt_yml_files-latest.json

Validate with Lintel

npx @lintel/lintel check
Type: object

Properties

version number
Constant: 2
analyses object[]
data_tests object[]

Add descriptions to custom singular tests

exposures object[]
groups object[]
macros object[]
metrics object[]
models object[]
saved_queries object[]
seeds object[]
semantic_models object[]
snapshots object[]
sources object[]
unit_tests object[]

Definitions

aggregation_type_params object
percentile number
use_approximate_percentile boolean
use_discrete_percentile boolean
array_of_strings string[]
boolean_or_jinja_string jinja_string | boolean
column_properties object
name string required
description string
constraints object[]
data_tests data_tests[]
data_type string
granularity enum
Values: "day" "hour" "microsecond" "millisecond" "minute" "month" "nanosecond" "quarter" "second" "week" "year"
meta object
policy_tags string[]

Configurations, specific to BigQuery adapter, used to set policy tags on specific columns, enabling column-level security. Only relevant when persist_docs.columns is true.

quote jinja_string | boolean
tags string | array_of_strings
tests data_tests[]
constraints object[]
conversion_metric_type_params object
conversion_type_params object
6 nested properties
base_measure string | object required
conversion_measure string | object required
entity string required

The entity to calculate over

calculation string
Default: "conversion_rate"
Values: "conversion_rate" "CONVERSION_RATE" "conversions" "CONVERSIONS"
constant_properties object[]
window string
cumulative_metric_type_params object
cumulative_type_params object
3 nested properties
grain_to_date string
period_agg enum
Values: "average" "first" "last"
window string
grain_to_date enum
Values: "day" "hour" "microsecond" "millisecond" "minute" "month" "nanosecond" "quarter" "second" "week" "year"
measure string | object
window string
data_tests string | enum | object | object | object
derived_metric_type_params object
expr string
dimension object
name string required
pattern=(?!.*__).*^[a-z][a-z0-9_]*[a-z0-9]$
type enum required
Values: "CATEGORICAL" "categorical" "TIME" "time"
description string
label string
config object
1 nested properties
meta object
expr boolean | string
is_partition boolean
type_params object
2 nested properties
time_granularity enum required
Values: "DAY" "day" "HOUR" "hour" "MICROSECOND" "microsecond" "MILLISECOND" "millisecond" "MINUTE" "minute" "MONTH" "month" "NANOSECOND" "nanosecond" "QUARTER" "quarter" "SECOND" "second" "WEEK" "week" "YEAR" "year"
validity_params object
2 nested properties
is_end boolean
is_start boolean
dimension_type_params object
time_granularity enum required
Values: "DAY" "day" "HOUR" "hour" "MICROSECOND" "microsecond" "MILLISECOND" "millisecond" "MINUTE" "minute" "MONTH" "month" "NANOSECOND" "nanosecond" "QUARTER" "quarter" "SECOND" "second" "WEEK" "week" "YEAR" "year"
validity_params object
2 nested properties
is_end boolean
is_start boolean
docs_config object

Configurations for the appearance of nodes in the dbt documentation.

node_color string

The color of the node on the DAG in the documentation. It must be an Hex code or a valid CSS color name.

pattern=^(#[a-fA-F0-9]{3}|#[a-fA-F0-9]{6}|[^#][a-zA-Z]*)$
show boolean
Default: true
entity object
name string required
pattern=(?!.*__).*^[a-z][a-z0-9_]*[a-z0-9]$
type enum required
Values: "FOREIGN" "foreign" "NATURAL" "natural" "PRIMARY" "primary" "UNIQUE" "unique"
config object
1 nested properties
meta object
entity string
expr boolean | string
export object
name string required
config object
3 nested properties
alias string
export_as enum
Values: "cache" "table" "view"
schema string
freshness_definition object | const: null
freshness_rules object
count jinja_string | number required
period string required
Values: "day" "hour" "minute"
grants object

grant config. each key is a database permission and the value is the grantee of that permission

group string
include_exclude object
exclude string | array_of_strings
include string | array_of_strings
is-time-dimension object
type enum required
Values: "TIME" "time"
jinja_string string
measure object
name string required
pattern=(?!.*__).*^[a-z][a-z0-9_]*[a-z0-9]$
agg enum required
Values: "AVERAGE" "average" "COUNT" "count" "COUNT_DISTINCT" "count_distinct" "MAX" "max" "MEDIAN" "median" "MIN" "min" "PERCENTILE" "percentile" "SUM" "sum" "SUM_BOOLEAN" "sum_boolean"
description string
agg_params object
3 nested properties
percentile number
use_approximate_percentile boolean
use_discrete_percentile boolean
agg_time_dimension string
pattern=(?!.*__).*^[a-z][a-z0-9_]*[a-z0-9]$
config object
1 nested properties
meta object
create_metric boolean
create_metric_display_name string
expr boolean | integer | string
label string
non_additive_dimension object
3 nested properties
name string required
window_choice enum
Values: "MAX" "max" "MIN" "min"
window_groupings string[]
metric_input_measure string | object
metric_input_schema string | object
model_configs object
auto_refresh jinja_string | boolean
backup jinja_string | boolean
contract object
1 nested properties
enforced jinja_string | boolean
event_time string

The column that represents the actual moment the row's event happened. Contrast with, for example, when it was loaded to the warehouse.

file_format string
grant_access_to object[]

Configuration, specific to BigQuery adapter, used to setup authorized views.

grants object

grant config. each key is a database permission and the value is the grantee of that permission

hours_to_expiration number

Configuration specific to BigQuery adapter used to set an expiration delay (in hours) to a table.

kms_key_name string

Configuration of the KMS key name, specific to BigQuery adapter.

pattern=projects/[a-zA-Z0-9_-]*/locations/[a-zA-Z0-9_-]*/keyRings/.*/cryptoKeys/.*
labels object

Configuration specific to BigQuery adapter used to add labels and tags to tables/views created by dbt.

location string
materialized string
on_configuration_change string
Values: "apply" "continue" "fail"
on_schema_change string
Values: "append_new_columns" "fail" "ignore" "sync_all_columns"
snowflake_warehouse string
sql_header string
target_lag string
pattern=^(?:downstream|\d+\s*(?:seconds|minutes|hours|days))$
tblproperties object
non_additive_dimension object
name string required
window_choice enum
Values: "MAX" "max" "MIN" "min"
window_groupings string[]
number_or_jinja_string jinja_string | number
persist_docs_config object

Configurations for the persistence of the dbt documentation.

columns jinja_string | boolean
relation jinja_string | boolean
ratio_metric_type_params object
denominator string | object
filter string
numerator string | object
simple_metric_type_params object
measure string | object
string_or_array_of_strings string | array_of_strings
test_configs object

Configurations set here will override configs set in dbt_project.yml.

alias string

Only relevant when store_failures is true

database string

Only relevant when store_failures is true

enabled jinja_string | boolean
error_if string
fail_calc string
limit integer
schema string

Only relevant when store_failures is true

severity jinja_string | string
store_failures jinja_string | boolean
tags string | array_of_strings
warn_if string
validity_params object
is_end boolean
is_start boolean