[System]
You are a helpful assistant that answers strictly in JSON. Here's the JSON schema you must adhere to:
<schema>
{"$schema":"http://json-schema.org/draft-07/schema","$id":"http://example.com/example.json","type":"object","title":"Tyk gateway OSS config file schema","description":"Schema that describes the config file of OSS tyk gateway.","default":{"_description":"Bare minimum config","listen_port":8080,"log_level":"info","secret":"foo","use_db_app_configs":false,"app_path":"/opt/tyk-gateway/apps/","storage":{"type":"redis","host":"tyk-redis","port":6379},"policies":{"policy_source":"file","policy_record_name":"/opt/tyk-gateway/policies/policies.json"},"enable_analytics":false,"analytics_config":{"type":""}},"examples":[{"_description":"Config example with JSVM enabled","listen_port":8080,"log_level":"info","secret":"foo","use_db_app_configs":false,"app_path":"/opt/tyk-gateway/apps/","storage":{"type":"redis","host":"tyk-redis","port":6379},"policies":{"policy_source":"file","policy_record_name":"/opt/tyk-gateway/policies/policies.json"},"enable_analytics":false,"analytics_config":{"type":""},"allow_insecure_configs":true,"hash_keys":true,"enable_hashed_keys_listing":true,"global_session_lifetime":100,"enable_jsvm":true,"enable_bundle_downloader":true,"bundle_base_url":"","tyk_js_path":"/opt/tyk-gateway/js/tyk.js","middleware_path":"/opt/tyk-gateway/middleware"}],"required":["listen_port","secret","use_db_app_configs","app_path","storage","policies"],"properties":{"listen_port":{"$id":"#/properties/listen_port","type":"integer","title":"The listen_port schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[8080]},"log_level":{"$id":"#/properties/log_level","type":"string","title":"The log_level schema","description":"Configuration field to control the gateway logging level.","enum":["error","warn","info","debug"],"default":"info","examples":["info","debug"]},"secret":{"$id":"#/properties/secret","type":"string","title":"The secret schema","description":"Configuration field as API key for the Tyk Gateway API. It should be passed along as the `X-Tyk-Authorization header in any requests made.","default":"","examples":["352d20ee67be67f6340b4c0605b044b7"]},"template_path":{"$id":"#/properties/template_path","type":"string","title":"The template_path schema","description":"An explanation about the purpose of this instance.","default":"","examples":["/opt/tyk-gateway/templates"]},"tyk_js_path":{"$id":"#/properties/tyk_js_path","type":"string","title":"The tyk_js_path schema","description":"An explanation about the purpose of this instance.","default":"","examples":["/opt/tyk-gateway/js/tyk.js"]},"middleware_path":{"$id":"#/properties/middleware_path","type":"string","title":"The middleware_path schema","description":"An explanation about the purpose of this instance.","default":"","examples":["/opt/tyk-gateway/middleware"]},"use_db_app_configs":{"$id":"#/properties/use_db_app_configs","type":"boolean","title":"Loading API configurations from DB","description":"For licensed users this needs to be true. False means it's not using a DB to load the configurations.","default":false,"examples":[false]},"app_path":{"$id":"#/properties/app_path","type":"string","title":"The app_path schema","description":"An explanation about the purpose of this instance.","default":"","examples":["/opt/tyk-gateway/apps/"]},"storage":{"$id":"#/properties/storage","type":"object","title":"The storage schema","description":"An explanation about the purpose of this instance.","default":{},"examples":[{"type":"redis","host":"tyk-redis","port":6379,"username":"","password":"","database":0,"optimisation_max_idle":2000,"optimisation_max_active":4000}],"required":["type","host","port"],"properties":{"type":{"$id":"#/properties/storage/properties/type","type":"string","title":"The type schema","description":"An explanation about the purpose of this instance.","default":"","examples":["redis"]},"host":{"$id":"#/properties/storage/properties/host","type":"string","title":"The host schema","description":"An explanation about the purpose of this instance.","default":"","examples":["tyk-redis"]},"port":{"$id":"#/properties/storage/properties/port","type":"integer","title":"The port schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[6379]},"username":{"$id":"#/properties/storage/properties/username","type":"string","title":"The username schema","description":"An explanation about the purpose of this instance.","default":"","examples":["<change-me>"]},"password":{"$id":"#/properties/storage/properties/password","type":"string","title":"The password schema","description":"An explanation about the purpose of this instance.","default":"","examples":["<change-me>"]},"database":{"$id":"#/properties/storage/properties/database","type":"integer","title":"The Redis database to be selected after connecting to the server","description":"Only single-node and failover clients.","default":0,"examples":[0]},"optimisation_max_idle":{"$id":"#/properties/storage/properties/optimisation_max_idle","type":"integer","title":"The optimisation_max_idle schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[2000]},"optimisation_max_active":{"$id":"#/properties/storage/properties/optimisation_max_active","type":"integer","title":"The optimisation_max_active schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[4000]}},"additionalProperties":true},"enable_analytics":{"$id":"#/properties/enable_analytics","type":"boolean","title":"The enable_analytics schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[false]},"analytics_config":{"$id":"#/properties/analytics_config","type":"object","title":"Configurations for analytics","description":"`analytics_config` contains setting for analytics captured by the gateway","default":{"type":"","purge_interval":10,"enable_detailed_recording":false},"examples":[],"required":["type"],"properties":{"type":{"$id":"#/properties/analytics_config/properties/type","type":"string","title":"Used for analytis by hybrid gateway","description":"For OSS gateway use an empty string.","default":"","examples":[]},"purge_interval":{"$id":"#/properties/analytics_config/properties/purge_interval","type":"integer","title":"The interval length for purging analytics","description":"Set the interval length on how often the tyk Gateway will purge analytics data. This value is in seconds and defaults to 10 seconds.","default":10,"examples":[1]},"ignored_ips":{"$id":"#/properties/analytics_config/properties/ignored_ips","type":"array","title":"The ignored_ips schema","description":"An explanation about the purpose of this instance.","default":[],"examples":[[]],"additionalItems":true,"items":{"$id":"#/properties/analytics_config/properties/ignored_ips/items"}},"enable_detailed_recording":{"$id":"#/properties/analytics_config/properties/enable_detailed_recording","type":"boolean","title":"Recording full request and response content","description":"Set this value to `true` to have Tyk store the inbound request and outbound response data in HTTP Wire format as part of the Analytics data. Please note, this will greatly increase your analytics DB size and can cause performance degradation on analytics processing by the Dashboard. This setting can be overridden with an organisation flag, enabed at an API level, or on individual Key level.","default":false,"examples":[]}},"additionalProperties":true},"health_check":{"$id":"#/properties/health_check","type":"object","title":"The health_check schema - deprecated!!!","description":"An explanation about the purpose of this instance.","default":{"enable_health_checks":false},"examples":[],"required":["enable_health_checks"],"properties":{"enable_health_checks":{"$id":"#/properties/health_check/properties/enable_health_checks","type":"boolean","title":"The enable_health_checks schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"health_check_value_timeouts":{"$id":"#/properties/health_check/properties/health_check_value_timeouts","type":"integer","title":"The timeout for health checks","description":"health_check_value_timeouts is deprecated!","default":0,"examples":[60]}},"additionalProperties":true},"optimisations_use_async_session_write":{"$id":"#/properties/optimisations_use_async_session_write","type":"boolean","title":"The optimisations_use_async_session_write schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[false]},"enable_non_transactional_rate_limiter":{"$id":"#/properties/enable_non_transactional_rate_limiter","type":"boolean","title":"The enable_non_transactional_rate_limiter schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"enable_sentinel_rate_limiter":{"$id":"#/properties/enable_sentinel_rate_limiter","type":"boolean","title":"The enable_sentinel_rate_limiter schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[false]},"enable_redis_rolling_limiter":{"$id":"#/properties/enable_redis_rolling_limiter","type":"boolean","title":"The enable_redis_rolling_limiter schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[false]},"allow_master_keys":{"$id":"#/properties/allow_master_keys","type":"boolean","title":"The allow_master_keys schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[false]},"policies":{"$id":"#/properties/policies","type":"object","title":"The policies schema","description":"Tell the gateway where to pick the policies from.","default":{"policy_source":"file","policy_record_name":"/opt/tyk-gateway/policies/policies.json"},"examples":[{"policy_source":"file","policy_record_name":"/opt/tyk-gateway/policies/policies.json"}],"required":["policy_source","policy_record_name"],"properties":{"policy_source":{"$id":"#/properties/policies/properties/policy_source","type":"string","title":"Set the policies source","description":"Set to `file` to load policies file from the file system. Set to `service` to use the Dashboard service.","default":"file","examples":[]},"policy_record_name":{"$id":"#/properties/policies/properties/policy_record_name","type":"string","title":"Specifies the path of your JSON file containing the available policies","description":"This option is required if `policies.policy_source` is set to `file`.","default":"/opt/tyk-gateway/policies/policies.json","examples":[]},"policy_path":{"$id":"#/properties/policies/properties/policy_path","type":"string","title":"Specifies the path of the directory  containing the available policies","description":"This option is required if `policies.policy_source` is set to `file`.","default":"/opt/tyk-gateway/policies/","examples":[]}},"additionalProperties":true},"hash_keys":{"$id":"#/properties/hash_keys","type":"boolean","title":"Set the format of the auth token keys in Redis","description":"True value will use the hashed value of the key as the key in Redis.","default":true,"examples":[false]},"close_connections":{"$id":"#/properties/close_connections","type":"boolean","title":"The close_connections schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[]},"http_server_options":{"$id":"#/properties/http_server_options","type":"object","title":"The http_server_options schema","description":"An explanation about the purpose of this instance.","default":{},"examples":[{"enable_websockets":true}],"required":["enable_websockets"],"properties":{"enable_websockets":{"$id":"#/properties/http_server_options/properties/enable_websockets","type":"boolean","title":"The enable_websockets schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]}},"additionalProperties":true},"allow_insecure_configs":{"$id":"#/properties/allow_insecure_configs","type":"boolean","title":"The allow_insecure_configs schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"coprocess_options":{"$id":"#/properties/coprocess_options","type":"object","title":"The coprocess_options schema","description":"An explanation about the purpose of this instance.","default":{},"examples":[{"enable_coprocess":true,"coprocess_grpc_server":""}],"required":["enable_coprocess","coprocess_grpc_server"],"properties":{"enable_coprocess":{"$id":"#/properties/coprocess_options/properties/enable_coprocess","type":"boolean","title":"The enable_coprocess schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"coprocess_grpc_server":{"$id":"#/properties/coprocess_options/properties/coprocess_grpc_server","type":"string","title":"The coprocess_grpc_server schema","description":"An explanation about the purpose of this instance.","default":"","examples":[""]}},"additionalProperties":true},"enable_bundle_downloader":{"$id":"#/properties/enable_bundle_downloader","type":"boolean","title":"The enable_bundle_downloader schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"bundle_base_url":{"$id":"#/properties/bundle_base_url","type":"string","title":"The bundle_base_url schema","description":"An explanation about the purpose of this instance.","default":"","examples":[]},"global_session_lifetime":{"$id":"#/properties/global_session_lifetime","type":"integer","title":"The global_session_lifetime schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[100]},"force_global_session_lifetime":{"$id":"#/properties/force_global_session_lifetime","type":"boolean","title":"The force_global_session_lifetime schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[]},"max_idle_connections_per_host":{"$id":"#/properties/max_idle_connections_per_host","type":"integer","title":"The max_idle_connections_per_host schema","description":"An explanation about the purpose of this instance.","default":0,"examples":[500]},"enable_jsvm":{"$id":"#/properties/enable_jsvm","type":"boolean","title":"The enable_jsvm schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]},"enable_hashed_keys_listing":{"$id":"#/properties/enable_hashed_keys_listing","type":"boolean","title":"The enable_hashed_keys_listing schema","description":"An explanation about the purpose of this instance.","default":false,"examples":[true]}},"additionalProperties":true}
</schema>

[User] Provide a JSON object that satisfies the schema "Tyk gateway OSS config file schema". Here are the required top‑level fields: listen_port, secret, use_db_app_configs, app_path, storage, policies. Return only the valid JSON object.

Tyk gateway OSS config file schema

Schema that describes the config file of OSS tyk gateway.

The listen_port schema

An explanation about the purpose of this instance.

The log_level schema

Configuration field to control the gateway logging level.

The secret schema

Configuration field as API key for the Tyk Gateway API. It should be passed along as the `X-Tyk-Authorization header in any requests made.

The template_path schema

The tyk_js_path schema

The middleware_path schema

Loading API configurations from DB

For licensed users this needs to be true. False means it's not using a DB to load the configurations.

The app_path schema

The storage schema

The type schema

The host schema

The port schema

The username schema

The password schema

The Redis database to be selected after connecting to the server

Only single-node and failover clients.

The optimisation_max_idle schema

The optimisation_max_active schema

The enable_analytics schema

Configurations for analytics

`analytics_config` contains setting for analytics captured by the gateway

Used for analytis by hybrid gateway

For OSS gateway use an empty string.

The interval length for purging analytics

Set the interval length on how often the tyk Gateway will purge analytics data. This value is in seconds and defaults to 10 seconds.

The ignored_ips schema

Recording full request and response content

Set this value to `true` to have Tyk store the inbound request and outbound response data in HTTP Wire format as part of the Analytics data. Please note, this will greatly increase your analytics DB size and can cause performance degradation on analytics processing by the Dashboard. This setting can be overridden with an organisation flag, enabed at an API level, or on individual Key level.

The health_check schema - deprecated!!!

The enable_health_checks schema

The timeout for health checks

health_check_value_timeouts is deprecated!

The optimisations_use_async_session_write schema

The enable_non_transactional_rate_limiter schema

The enable_sentinel_rate_limiter schema

The enable_redis_rolling_limiter schema

The allow_master_keys schema

The policies schema

Tell the gateway where to pick the policies from.

Set the policies source

Set to `file` to load policies file from the file system. Set to `service` to use the Dashboard service.

Specifies the path of your JSON file containing the available policies

This option is required if `policies.policy_source` is set to `file`.

Specifies the path of the directory  containing the available policies

Set the format of the auth token keys in Redis

True value will use the hashed value of the key as the key in Redis.

The close_connections schema

The http_server_options schema

The enable_websockets schema

The allow_insecure_configs schema

The coprocess_options schema

The enable_coprocess schema

The coprocess_grpc_server schema

The enable_bundle_downloader schema

The bundle_base_url schema

The global_session_lifetime schema

The force_global_session_lifetime schema

The max_idle_connections_per_host schema

The enable_jsvm schema

The enable_hashed_keys_listing schema

Provide a JSON object that satisfies the schema "Tyk gateway OSS config file schema". Here are the required top‑level fields: listen_port, secret, use_db_app_configs, app_path, storage, policies. Return only the valid JSON object.


[System]
You are a helpful assistant that answers strictly in JSON. Here's the JSON schema you must adhere to:
<schema>
{"$schema":"http://json-schema.org/draft-07/schema#","title":"Definition","type":"object","properties":{"workspace":{"description":"A workspace definition","anyOf":[{"$ref":"#/definitions/Workspace"},{"type":"null"}]},"environment":{"description":"A environment definition","anyOf":[{"$ref":"#/definitions/Environment"},{"type":"null"}]},"table":{"description":"A table definition","anyOf":[{"$ref":"#/definitions/Table"},{"type":"null"}]},"classifier":{"description":"A classifier definition","anyOf":[{"$ref":"#/definitions/Classifier"},{"type":"null"}]},"function":{"description":"A function definition","anyOf":[{"$ref":"#/definitions/Function"},{"type":"null"}]},"config":{"description":"A config definition","anyOf":[{"$ref":"#/definitions/Config"},{"type":"null"}]},"credential":{"description":"A credential definition","anyOf":[{"$ref":"#/definitions/Credential"},{"type":"null"}]},"sdf-args":{"description":"A config definition","type":["object","null"],"additionalProperties":{"type":"string"}}},"additionalProperties":false,"definitions":{"Workspace":{"description":"A workspace is a collection of one or more catalogs, schemas, tables, and resources, called workspace members, that are managed together.","type":"object","required":["edition","name"],"properties":{"edition":{"description":"The SDF edition, should always be 1.3 (1.2 is deprecated)","type":"string"},"name":{"description":"The name of this workspace (defaults to the workspace directory name if not given) Name must be set for deployment.","type":"string"},"is-tablename-case-sensitive":{"description":"Whether table names are treated as case sensitive in this workspace Applies globally to the entire project, and is non-overridable. Defaults to false\n\nNote: this setting is *only* effective when set on the root workspace file, if set on included workspaces it will be ignored","type":"boolean"},"description":{"description":"A description of this workspace","type":"string"},"repository":{"description":"The URL of the workspace source repository (defaults to 'none' if no repository is given)","type":"string"},"includes":{"description":"An array of directories and filenames containing .sql and .sdf.yml files","type":"array","items":{"$ref":"#/definitions/IncludePath"}},"excludes":{"description":"An array of directories and filenames to be skipped when resolving includes","type":"array","items":{"$ref":"#/definitions/ExcludePath"}},"dependencies":{"description":"Dependencies of the workspace to other workspaces or to cloud database providers","type":"array","items":{"$ref":"#/definitions/Dependency"}},"integrations":{"description":"The integrations for this environment","type":"array","items":{"$ref":"#/definitions/Integration"}},"defaults":{"description":"Defaults for this workspace","anyOf":[{"$ref":"#/definitions/Defaults"},{"type":"null"}]},"source-locations":{"description":"Workspace defined by these set of files","type":"array","items":{"$ref":"#/definitions/FilePath"}},"vars":{"description":"A map of named values for setting SQL variables from your environment Ex. -dt: dt, used in SQL as @dt, and in Jinja as ","type":"object","additionalProperties":{"$ref":"#/definitions/Constant"}},"dbt":{"description":"Configuration for dbt integration","anyOf":[{"$ref":"#/definitions/DbtConfig"},{"type":"null"}]}},"additionalProperties":false},"IncludePath":{"description":"All file path should either be relative to the workspace, or absolute for an object store like AWS s3:// Note that an [IncludePath] specifies a catalog and schema scope for unqualified names (in effect for both creating and querying tables). See [IncludePath::default_catalog] and [IncludePath::default_schema].","type":"object","required":["path"],"properties":{"path":{"description":"A filepath","type":"string"},"type":{"description":"Type of included artifacts: model | test | stats | metadata | resource","allOf":[{"$ref":"#/definitions/IncludeType"}]},"index":{"description":"Index method for this include path: scan | table | schema-table | catalog-schema-table","allOf":[{"$ref":"#/definitions/IndexMethod"}]},"defaults":{"description":"Defaults for files on this path","anyOf":[{"$ref":"#/definitions/Defaults"},{"type":"null"}]}},"additionalProperties":false},"IncludeType":{"oneOf":[{"description":"Models are .sql files (ddls or queries) used for data transformation.","type":"string","enum":["model"]},{"description":"Tests are expectations against the data of models. Uses the sdf-test library by default.","type":"string","enum":["test"]},{"description":"Checks are logical expectations expresses as queries against the information schema of the SDF workspace.","type":"string","enum":["check"]},{"description":"Reports are informational  queries against the information schema of the SDF workspace.","type":"string","enum":["report"]},{"description":"Statistics are informational queries against the data of the models.","type":"string","enum":["stat"]},{"description":"Resources are local data files (like parquet, csv, or json) used by models in the workspace.","type":"string","enum":["resource"]},{"description":"[Deprecated] Metadata are .sdf.yml files to add additional metadata.","type":"string","enum":["metadata"]},{"description":"Specifications are .sdf.yml files to configure your workspace and add additional metadata.","type":"string","enum":["spec"]},{"description":"Macros are .jinja files that define reusable SQL code.","type":"string","enum":["macro"]},{"description":"Seeds are models created from resources. The sdf local engine enables type checking of seeds independently of providers. Seeds can optionally be uploaded to the remote warehouse.","type":"string","enum":["seed"]},{"description":"Slt files are tests that follow sqllogictest format","type":"string","enum":["slt"]}]},"IndexMethod":{"oneOf":[{"type":"string","enum":["scan-dbt"]},{"description":"File path is not used in figuring out the full names of the tables defined in the file. Catalog and schema are inferred from the SQL statement if possible, or from the `defaults` section in the workspace configuration. Table name is inferred from the SQL statement if possible or from the name of the file without the extension. To figure out dependencies between tables and files, SDF will parse every file in the corresponding include path. This is the default option","type":"string","enum":["none"]},{"description":"Table name is inferred from the file name without the extension. Catalog and schema are inferred from the `defaults` configuration. SDF assumes that a referenced table will reside in the file with the corresponding name. As a result, only the required subset of files is parsed. This option is is fast compared to the default, but it requires catalog and schemas to use the default values","type":"string","enum":["table-name"]},{"description":"Table name is inferred from the file name without the extension. Schema is inferred from the directory name in which the file resides. Catalog is inferred from the `defaults` configuration. SDF assumes that a referenced table will reside in the directory/file with the corresponding schema/table name. As a result, only the required subset of files is parsed. This option is also fast, and it allows the schema to vary based on the directory name, but it still requires catalog to use the default values","type":"string","enum":["schema-table-name"]},{"description":"Table name is inferred from the file name without the extension. Schema is inferred from the directory name in which the file resides. Catalog is inferred from the directory name in which the schema directory resides. Defaults are not used. SDF assumes that a referenced table will reside in the catalog/schema/table file with the corresponding schema/catalog/table names. As a result, only the required subset of files is parsed. This option is also fast, and it provides the most flexibility as catalog, schema and table names can all vary","type":"string","enum":["catalog-schema-table-name"]}]},"Defaults":{"type":"object","properties":{"environment":{"description":"The default environment (can only be set on the level of the workspace)","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"dialect":{"description":"The dialect of this environment. If not set, defaults to trino","anyOf":[{"$ref":"#/definitions/Dialect"},{"type":"null"}]},"casing-policy":{"description":"Case normalization policy for names","anyOf":[{"$ref":"#/definitions/CasingPolicy"},{"type":"null"}]},"preprocessor":{"description":"The preprocessor for this environment. If not set, defaults to local","anyOf":[{"$ref":"#/definitions/PreprocessorType"},{"type":"null"}]},"catalog":{"description":"Defines a default catalog. If not set, defaults to the (catalog/workspace) name in an outer scope","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"schema":{"description":"Defines a default schema,  If not set, defaults to the schema name in an outer scope, if not set, defaults to 'pub'","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"materialization":{"description":"Defines the default materialization, if not set defaults to materialization in outer scope, if not set defaults to base-table","anyOf":[{"$ref":"#/definitions/Materialization"},{"type":"null"}]},"creation-flag":{"description":"Defines table creation flags, defaults to  if not set","anyOf":[{"$ref":"#/definitions/TableCreationFlags"},{"type":"null"}]},"utils-lib":{"description":"The default utils library, if set overrides sdf_utils","type":["string","null"]},"test-lib":{"description":"The default test library, if set overrides sdf_test","type":["string","null"]},"materialization-lib":{"description":"The default materialization library, if set overrides sdf_materialization","type":["string","null"]},"linter":{"description":"The named lint rule set, uses defaults (from sdftarget/<environment>/lint.sdf.yml) if not set","type":["string","null"]},"index-method":{"description":"The default index for this tables","anyOf":[{"$ref":"#/definitions/IndexMethod"},{"type":"null"}]},"include-type":{"description":"The default index for this tables","anyOf":[{"$ref":"#/definitions/IncludeType"},{"type":"null"}]},"sync-method":{"description":"The default index for this tables","anyOf":[{"$ref":"#/definitions/SyncType"},{"type":"null"}]},"severity":{"description":"The default severity for this tables tests and checks","anyOf":[{"$ref":"#/definitions/Severity"},{"type":"null"}]},"csv-has-header":{"description":"CSV data has a header [only for external tables]","type":["boolean","null"]},"csv-delimiter":{"description":"CSV data is separated by this delimiter [only for external tables]","type":["string","null"]},"csv-compression":{"description":"Json or CSV data is compressed with this method [only for external tables]","anyOf":[{"$ref":"#/definitions/CompressionType"},{"type":"null"}]}},"additionalProperties":false},"String":{"type":"string"},"Dialect":{"description":"Supported dialects in YAML files\n\nNote: this [Dialect] type is *only* meant for serializing to and from `.sdf.yml` files. For internal use, you should almost always use the semantic dialect type ([types::Dialect]) instead.\n\nNote specifically that the lack of a `.to_string()` method (i.e. [!Display]) on this type is intentional -- you must first convert this type to a [types::Dialect], by using either [Dialect::to_semantic_dialect] or [types::Dialect::from], before you can convert it to a string.","type":"string","enum":["snowflake","trino","bigquery","redshift","spark-lp","sdf","databricks"]},"CasingPolicy":{"type":"string","enum":["preserve","to-upper","to-lower"]},"PreprocessorType":{"type":"string","enum":["none","jinja","sql-vars","all"]},"Materialization":{"oneOf":[{"description":"Permanent table; e.g. for Snowflake, it will generate `CREATE OR REPLACE TABLE AS ...`","type":"string","enum":["table"]},{"description":"Transient tables are cost-optimized as the 90 day data retention period is not enforced. They also limit Snowflake time travel support. e.g. for Snowflake, it will generate `CREATE OR REPLACE TRANSIENT TABLE AS ...`","type":"string","enum":["transient-table"]},{"description":"Temporary table; e.g. for Snowflake, it will generate `CREATE OR REPLACE TEMPORARY TABLE AS ...","type":"string","enum":["temporary-table"]},{"description":"Table with pre-existing data; it is not populated by SDF e.g. for Snowflake, it will generate `CREATE OR REPLACE EXTERNAL TABLE ...`","type":"string","enum":["external-table"]},{"description":"Permanent view (default option); e.g. for Snowflake, it will generate `CREATE OR REPLACE VIEW AS ...`","type":"string","enum":["view"]},{"description":"Materialized view; e.g. for Snowflake, it will generate `CREATE OR REPLACE MATERIALIZED VIEW AS ...`","type":"string","enum":["materialized-view"]},{"description":"Incremental tables are permanent tables that are gradually populated and not overwritten from scratch during every SDF run. Different SQL statements will be generated depending on whether this table already exists or not. In the latter case, an equivalent of `CREATE OR REPLACE TABLE` will be generated; in the former case, one of `INSERT INTO ...`, `MERGE ...`, or `DELETE FROM ...`, followed by `INSERT INTO ...` will be generated depending on the parameters of `incremental-options`","type":"string","enum":["incremental-table"]},{"description":"Snapshot tables are permanent tables that capture a snapshot of some underlying data at the time of running the query. Like incremental tables, snapshot tables are not recomputed from scratch during every SDF run","type":"string","enum":["snapshot-table"]},{"description":"Recursive tables are permanent tables whose queries can have self-references. SDF will generate an equivalent of `CREATE RECURSIVE TABLE AS ...`. Note: in Snowflake, recursive tables are not treated specially---a normal `CREATE OR REPLACE TABLE AS...` is generated for them","type":"string","enum":["recursive-table"]},{"description":"User defined other materializations, it is up to users to define their own materialization logics","type":"object","required":["other"],"properties":{"other":{"type":"string"}},"additionalProperties":false}]},"TableCreationFlags":{"oneOf":[{"description":"Attempts to create a new table; fails if the table already exists.","type":"string","enum":["create-new"]},{"description":"Drops the existing table and creates a new one.","type":"string","enum":["drop-if-exists"]},{"description":"Skips table creation if the table already exists.","type":"string","enum":["skip-if-exists"]},{"description":"Replaces the existing table with a new one. Implementation may vary by DBMS.","type":"string","enum":["create-or-replace"]},{"description":"Creates the table only if it doesn't already exist.","type":"string","enum":["create-if-not-exists"]}]},"SyncType":{"oneOf":[{"description":"Synchronizes directory on pull and push","type":"string","enum":["always"]},{"description":"Synchronizes directory on every pull","type":"string","enum":["on-pull"]},{"description":"Synchronizes directory on every push","type":"string","enum":["on-push"]},{"description":"Never synchronizes directory","type":"string","enum":["never"]}]},"Severity":{"type":"string","enum":["warning","error"]},"CompressionType":{"description":"Compress table data using these methods","oneOf":[{"type":"string","enum":["tar","zstd"]},{"description":"BZIP2 Compression (.bz2)","type":"string","enum":["bzip2"]},{"description":"GZIP Compression (.gzip)","type":"string","enum":["gzip"]},{"description":"None, (default)","type":"string","enum":["none"]}]},"ExcludePath":{"type":"object","required":["path"],"properties":{"path":{"description":"A filepath","type":"string"},"exclude-type":{"description":"Type of excluded artifacts","anyOf":[{"$ref":"#/definitions/ExcludeType"},{"type":"null"}]}},"additionalProperties":false},"ExcludeType":{"oneOf":[{"type":"string","enum":["content"]},{"description":"Excludes this path, can be a glob expression","type":"string","enum":["path"]}]},"Dependency":{"type":"object","required":["name"],"properties":{"name":{"$ref":"#/definitions/String"},"path":{"description":"The relative path from this workspace to the referenced workspace, for a Git repo, from the root of the depot to the workspace","type":["string","null"]},"environment":{"description":"The chosen workspace environment (none means default)","type":["string","null"]},"target":{"description":"The chosen workspace target (none means default)","type":["string","null"]},"git":{"description":"The Git repo","type":["string","null"]},"rev":{"description":"the Git revision (choose only one of the fields: rev, branch, tag)","type":["string","null"]},"branch":{"description":"the Git branch (choose only one of the fields: rev, branch, tag)","type":["string","null"]},"tag":{"description":"the Git tag (choose only one of the fields: rev, branch, tag)","type":["string","null"]},"imports":{"description":"Which models, reports, tests, checks etc. to include from the dependency","type":"array","items":{"type":"string"}}},"additionalProperties":false},"Integration":{"description":"Table providers manage tables in in catalogs (OLD_PROVIDERS)","type":"object","required":["provider"],"properties":{"type":{"description":"The type of the integration [e.g.: database, metadata, data]","default":"database","allOf":[{"$ref":"#/definitions/IntegrationType"}]},"provider":{"description":"The type of the provider [e.g.: snowflake, redshift, s3]","allOf":[{"$ref":"#/definitions/ProviderType"}]},"credential":{"description":"Credential identifier for this provider","type":["string","null"]},"cluster-identifier":{"description":"The cluster identifier for redshift server","writeOnly":true,"type":["string","null"]},"batch-size":{"description":"The size of the batch when querying the provider","type":["integer","null"],"format":"uint","minimum":0.0},"sources":{"description":"A list of (possibly remote) sources to read, matched in order, so write specific pattern before more general patterns","type":"array","items":{"$ref":"#/definitions/SourcePattern"}},"targets":{"description":"A list of (possibly remote) targets to build,  matched in order, so write specific pattern before more general patterns, source patterns are excluded","type":"array","items":{"$ref":"#/definitions/TargetPattern"}},"buckets":{"description":"A list of remote buckets to target","type":"array","items":{"$ref":"#/definitions/DataBucket"}},"output-location":{"description":"The remote output location of the integration","type":["string","null"]}},"additionalProperties":false},"IntegrationType":{"type":"string","enum":["data","metadata","database"]},"ProviderType":{"type":"string","enum":["glue","redshift","snowflake","bigquery","s3","sdf"]},"SourcePattern":{"description":"Sources defines the tables that are possibly remote","type":"object","required":["pattern"],"properties":{"pattern":{"description":"A source that can be read. Sources must be a three part names with globs, eg. *.*.* matches all catalogs, schema and table in scope","type":"string"},"time-travel-qualifier":{"description":"Time travel qualifier expression (e.g. `AT (TIMESTAMP => {{ SOME_TIMESTAMP }})``)","type":["string","null"]},"preload":{"description":"Whether to preload the source","type":["boolean","null"]},"rename-from":{"description":"Renames sources when searching in the remote, the ith ${i} matches the ith * of the name, so to prepend all catalogs,schema,table with _, use \"_${1}._${2}._${3}\"","type":["string","null"]}},"additionalProperties":false},"TargetPattern":{"description":"Sources define the tables that are possibly remote and that will be build","type":"object","properties":{"pattern":{"description":"A pattern must be a three part names with globs, eg. *.*.* matches all catalogs, schema and table in scope","type":["string","null"]},"patterns":{"description":"A list of patterns. A pattern must be a three part names with globs, eg. *.*.* matches all catalogs, schema and table in scope","type":"array","items":{"type":"string"}},"preload":{"description":"Whether to preload the target","type":["boolean","null"]},"rename-as":{"description":"Renames targets, the ith ${i} matches the ith * of the name, so to prepend all catalogs,schema,table with _, use \"_${1}._${2}._${3}\"","type":["string","null"]}},"additionalProperties":false},"DataBucket":{"type":"object","required":["uri"],"properties":{"uri":{"description":"The uri of the bucket","type":"string"},"region":{"description":"The region of the bucket","type":["string","null"]}},"additionalProperties":false},"FilePath":{"description":"All file path should either be relative to the workspace, or absolute for an object store like AWS s3://","type":"object","required":["path"],"properties":{"path":{"description":"A filepath","type":"string"},"time":{"description":"Last modified of the file","writeOnly":true,"anyOf":[{"$ref":"#/definitions/SystemTime"},{"type":"null"}]}},"additionalProperties":false},"SystemTime":{"type":"object","required":["nanos_since_epoch","secs_since_epoch"],"properties":{"secs_since_epoch":{"type":"integer","format":"uint64","minimum":0.0},"nanos_since_epoch":{"type":"integer","format":"uint32","minimum":0.0}}},"Constant":{"anyOf":[{"type":"null"},{"type":"boolean"},{"type":"integer","format":"int64"},{"type":"number","format":"double"},{"type":"string"}]},"DbtConfig":{"type":"object","properties":{"enabled":{"description":"Whether the dbt integration is enabled","type":"boolean"},"project-dir":{"description":"Dbt Project Directory","type":["string","null"]},"target-dir":{"description":"The dbt target directory for the project","type":["string","null"]},"profile-dir":{"description":"The directory where dbt profiles are stored","type":["string","null"]},"profile":{"description":"The dbt profile to use","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"target":{"description":"The dbt target for the profile","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"auto-parse":{"description":"Automatically Run Parse in-between commands (default: true)","type":"boolean"},"disable-introspection":{"description":"Disable introspection (default: false)","type":"boolean"}},"additionalProperties":false},"Environment":{"description":"Environments provide a way to override the fields of a workspace, i.e. if an environment has set field X, then the workspace field X will be overridden by the environment field X.","type":"object","required":["name"],"properties":{"name":{"description":"The name of this workspace (defaults to the workspace directory name if not given) Name must be set for deployment.","allOf":[{"$ref":"#/definitions/String"}]},"description":{"description":"A description of this workspace","type":"string"},"repository":{"description":"The URL of the workspace source repository (defaults to 'none' if no repository is given)","type":"string"},"includes":{"description":"An array of directories and filenames containing .sql and .sdf.yml files","type":"array","items":{"$ref":"#/definitions/IncludePath"}},"excludes":{"description":"An array of directories and filenames to be skipped when resolving includes","type":"array","items":{"$ref":"#/definitions/ExcludePath"}},"defaults":{"description":"Defaults for this workspace","anyOf":[{"$ref":"#/definitions/Defaults"},{"type":"null"}]},"dependencies":{"description":"Dependencies of the workspace to other workspaces or to cloud database providers","type":"array","items":{"$ref":"#/definitions/Dependency"}},"integrations":{"description":"The integrations for this environment","type":"array","items":{"$ref":"#/definitions/Integration"}},"vars":{"description":"A map of named values for setting SQL variables from your environment Ex. -dt: dt, used in SQL as @dt, and in Jinja as ","type":"object","additionalProperties":{"$ref":"#/definitions/Constant"}},"source-locations":{"description":"Workspace defined by these set of files","type":"array","items":{"$ref":"#/definitions/FilePath"}},"preprocessor":{"description":"Experimental: This project has jinja","anyOf":[{"$ref":"#/definitions/PreprocessorType"},{"type":"null"}]},"dbt":{"description":"Configuration for dbt integration","anyOf":[{"$ref":"#/definitions/DbtConfig"},{"type":"null"}]}},"additionalProperties":false},"Table":{"description":"A tables is either defined by given data (also called external table) or defined via a query.","type":"object","required":["name"],"properties":{"name":{"description":"The name of the table (syntax: [[catalog.]schema].table)\n\nNote: this field is typed as a [QualifiedName] for serialization. In almost all cases you should use the [Self::fqn()] method to get the fully qualified [TableName] instead of accessing this field directly.","allOf":[{"$ref":"#/definitions/String"}]},"description":{"description":"A description of this table","type":["string","null"]},"dialect":{"description":"The dialect of this table, defaults to `trino`","anyOf":[{"$ref":"#/definitions/Dialect"},{"type":"null"}]},"casing-policy":{"description":"Case normalization policy for names specified in this table","anyOf":[{"$ref":"#/definitions/CasingPolicy"},{"type":"null"}]},"materialization":{"description":"The table-type of this table (new version)","anyOf":[{"$ref":"#/definitions/Materialization"},{"type":"null"}]},"warehouse":{"description":"The warehouse where this table is computed","type":["string","null"]},"purpose":{"description":"Specify what kind of table or view this is","anyOf":[{"$ref":"#/definitions/TablePurpose"},{"type":"null"}]},"origin":{"description":"The origin of this table <remote> or <local>","allOf":[{"$ref":"#/definitions/TableOrigin"}]},"exists-remotely":{"description":"Whether the table exists in the remote DB (used for is_incremental macro)","type":["boolean","null"]},"table-location":{"description":"Specify table ,location, defaults to none if not set","anyOf":[{"$ref":"#/definitions/TableLocation"},{"type":"null"}]},"creation-flags":{"description":"Defines the table creation options, defaults to none if not set","anyOf":[{"$ref":"#/definitions/TableCreationFlags"},{"type":"null"}]},"incremental-options":{"description":"Options governing incremental table evaluation (only for incremental tables)","anyOf":[{"$ref":"#/definitions/IncrementalOptions"},{"type":"null"}]},"snapshot-options":{"description":"Options governing snapshot table evaluation (only for snapshot tables)","anyOf":[{"$ref":"#/definitions/SnapshotOptions"},{"type":"null"}]},"dependencies":{"description":"All tables that this table depends on (syntax: catalog.schema.table)","type":"array","items":{"$ref":"#/definitions/String"}},"depended-on-by":{"description":"All tables that depend on this table (syntax: catalog.schema.table)","type":"array","items":{"$ref":"#/definitions/String"}},"columns":{"description":"The columns of the schema: name, type, metadata","type":"array","items":{"$ref":"#/definitions/Column"}},"partitioned-by":{"description":"The partitioning format of the table","type":"array","items":{"$ref":"#/definitions/Partition"}},"severity":{"description":"The default severity for this tables tests and checks","anyOf":[{"$ref":"#/definitions/Severity"},{"type":"null"}]},"tests":{"type":"array","items":{"$ref":"#/definitions/Constraint"}},"schedule":{"description":"The schedule of the table [expressed as cron]","type":"string"},"starting":{"description":"The first date of the table [expressed by prefixes of RFC 33]","type":"string"},"classifiers":{"description":"An array of classifier references","type":"array","items":{"type":"string"}},"reclassify":{"description":"Array of reclassify instructions for changing the attached classifier labels","type":"array","items":{"$ref":"#/definitions/Reclassify"}},"lineage":{"description":"Lineage, a tagged array of column references","anyOf":[{"$ref":"#/definitions/Lineage"},{"type":"null"}]},"location":{"description":"Data is at this location","type":["string","null"]},"file-format":{"description":"Store table in this format [only for external tables]","anyOf":[{"$ref":"#/definitions/FileFormat"},{"type":"null"}]},"with-header":{"description":"CSV data has a header [only for external tables]","type":["boolean","null"]},"delimiter":{"description":"CSV data is separated by this delimiter [only for external tables]","type":["string","null"]},"compression":{"description":"Json or CSV data is compressed with this method [only for external tables]","anyOf":[{"$ref":"#/definitions/CompressionType"},{"type":"null"}]},"cycle-cut-point":{"description":"If this table is part of a cyclic dependency then cut the cycle here","type":["boolean","null"]},"source-locations":{"description":"Table is defined by these .sql and/or .sdf files","type":"array","items":{"$ref":"#/definitions/FilePath"}},"sealed":{"description":"This table is either backed by a create table ddl or by a table definition in yml that is the table's complete schema","type":["boolean","null"]},"meta":{"description":"Metadata for this table","type":"object","additionalProperties":{"type":"string"}}},"additionalProperties":false},"TablePurpose":{"oneOf":[{"type":"string","enum":["report"]},{"description":"A regular table","type":"string","enum":["model"]},{"description":"A code contract","type":"string","enum":["check"]},{"description":"A data contract","type":"string","enum":["test"]},{"description":"A data report","type":"string","enum":["stat"]},{"description":"A slt table","type":"string","enum":["slt"]},{"description":"A SDF System table/view, maintained by the sdf cli","type":"string","enum":["system"]},{"description":"An External System table/view, maintained by the database system (e.g. Snowflake, Redshift, etc.)","type":"string","enum":["external-system"]}]},"TableOrigin":{"type":"string","enum":["local","remote"]},"TableLocation":{"type":"string","enum":["mirror","local","remote","intrinsic"]},"IncrementalOptions":{"type":"object","required":["strategy"],"properties":{"strategy":{"description":"Incremental strategy; may be one of `append`, `merge`, or `delete+insert`","allOf":[{"$ref":"#/definitions/IncrementalStrategy"}]},"unique-key":{"description":"Expression used for identifying records in Merge and Delete+Insert strategies; May be a column name or an expression combining multiple columns. If left unspecified, Merge and Delete+Insert strategies behave the same as Append","type":["string","null"]},"merge-update-columns":{"description":"List of column names to be updated as part of Merge strategy; Only one of merge_update_columns or merge_exclude_columns may be specified","type":"array","items":{"$ref":"#/definitions/String"}},"merge-exclude-columns":{"description":"List of column names to exclude from updating as part of Merge strategy; Only one of merge_update_columns or merge_exclude_columns may be specified","type":"array","items":{"$ref":"#/definitions/String"}},"on-schema-change":{"description":"Method for reacting to changing schema in the source of the incremental table Possible values are `fail`, `append`, and `sync`. If left unspecified, the default behavior is to ignore the change and possibly error out if the schema change is incompatible. `fail` causes a failure whenever any deviation in the schema of the source is detected; `append` adds new columns but does not delete the columns removed from the source; `sync` adds new columns and deletess the columns removed from the source;","anyOf":[{"$ref":"#/definitions/OnSchemaChange"},{"type":"null"}]},"compact-mode-warehouse":{"description":"Warehouse to use in the incremental mode","type":["string","null"]}},"additionalProperties":false},"IncrementalStrategy":{"type":"string","enum":["append","merge","delete+insert"]},"OnSchemaChange":{"oneOf":[{"description":"Fail when the new schema of an incremental table does not match the old one","type":"string","enum":["fail"]},{"description":"Keep all the columns of the old incremental table schema while appending the new columns from the new schema. Initialize all the columns that were deleted in the new schema with NULL","type":"string","enum":["append"]},{"description":"Delete all the deleted columns from the incremental table; Append all the new columns","type":"string","enum":["sync"]}]},"SnapshotOptions":{"type":"object","required":["strategy","unique-key"],"properties":{"strategy":{"description":"Snapshot strategy; may be one of `timestamp` (default), or `check`","allOf":[{"$ref":"#/definitions/SnapshotStrategy"}]},"unique-key":{"description":"Expression used for identifying records that will be updated according to the snapshot strategiy; May be a column name or an expression combining multiple columns","type":"string"},"updated-at":{"description":"Name of the timestamp column used to identify the last update time This option is only required for the `timestamp` snapshot strategy","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"check-cols":{"description":"Specification of which columns to check for change (may be a list of column names or `all`) This option is only required for the `check` snapshot strategy","anyOf":[{"$ref":"#/definitions/CheckColsSpec"},{"type":"null"}]},"compact-mode-warehouse":{"description":"Warehouse to use in the snapshot mode","type":["string","null"]}},"additionalProperties":false},"SnapshotStrategy":{"type":"string","enum":["timestamp","check"]},"CheckColsSpec":{"oneOf":[{"description":"A list of column names to be used for checking if a snapshot's source data set was updated","type":"object","required":["cols"],"properties":{"cols":{"type":"array","items":{"$ref":"#/definitions/String"}}},"additionalProperties":false},{"description":"Use all columns to check whether a snapshot's source data set was updated","type":"string","enum":["all"]}]},"Column":{"type":"object","required":["name"],"properties":{"name":{"description":"The name of the column","allOf":[{"$ref":"#/definitions/String"}]},"description":{"description":"A description of this column","type":"string"},"datatype":{"description":"The type of this column","type":["string","null"]},"classifiers":{"description":"An array of classifier references","type":"array","items":{"type":"string"}},"lineage":{"description":"Lineage, a tagged array of column references","anyOf":[{"$ref":"#/definitions/Lineage"},{"type":"null"}]},"forward-lineage":{"description":"Forward Lineage, the columns that this column is used to compute","anyOf":[{"$ref":"#/definitions/Lineage"},{"type":"null"}]},"reclassify":{"description":"Array of reclassify instructions for changing the attached classifier labels","type":"array","items":{"$ref":"#/definitions/Reclassify"}},"samples":{"description":"An array of representative literals of this column [experimental!]","type":"array","items":{"type":"string"}},"default-severity":{"description":"The default severity for this tables tests and checks","allOf":[{"$ref":"#/definitions/Severity"}]},"tests":{"type":"array","items":{"$ref":"#/definitions/Constraint"}}},"additionalProperties":false},"Lineage":{"type":"object","properties":{"copy":{"description":"The output column is computed by copying these upstream columns","type":"array","items":{"$ref":"#/definitions/String"}},"modify":{"description":"The output column is computed by transforming these upstream columns","type":"array","items":{"$ref":"#/definitions/String"}},"scan":{"description":"These upstream columns are indirectly used to produce the output (e.g. in WHERE or GROUP BY)","type":"array","items":{"$ref":"#/definitions/String"}},"apply":{"description":"These functions were used to produce the output column","type":"array","items":{"$ref":"#/definitions/String"}}},"additionalProperties":false},"Reclassify":{"type":"object","properties":{"to":{"description":"Target classifier","type":["string","null"]},"from":{"description":"Expected source classifier","type":["string","null"]}},"additionalProperties":false},"Constraint":{"type":"object","required":["expect"],"properties":{"expect":{"description":"The constraint macro: must have the form lib.macro(args,..), where lib is any of the libs in scope, std is available by default","type":"string"},"severity":{"description":"The severity of this constraint","anyOf":[{"$ref":"#/definitions/Severity"},{"type":"null"}]}},"additionalProperties":false},"Partition":{"description":"A partition is a table column, used to describe to which partition this row belongs to","type":"object","required":["name"],"properties":{"name":{"description":"The name of the partition column","allOf":[{"$ref":"#/definitions/String"}]},"description":{"description":"A description of the partition column","type":["string","null"]},"format":{"description":"The format of the partition column [use strftime format for date/time] See (guide)[https://docs.sdf.com/guide/schedules]","type":["string","null"]}},"additionalProperties":false},"FileFormat":{"description":"Store table data in these formats","type":"string","enum":["parquet","csv","json"]},"Classifier":{"description":"A classifier defines the labels that can be attached to columns or a table.","type":"object","required":["name"],"properties":{"name":{"description":"The name of the classifier type","type":"string"},"description":{"description":"A description of this classifier type","type":"string"},"labels":{"description":"Named classifier labels","type":"array","items":{"$ref":"#/definitions/Label"}},"scope":{"description":"Scope of the classifier: table or column","allOf":[{"$ref":"#/definitions/Scope"}]},"cardinality":{"description":"Cardinality of the classifier: zero-or-one, one or zero-or-many","allOf":[{"$ref":"#/definitions/Cardinality"}]},"propagate":{"description":"Does the classifier propagate from scope to scope or is it a one scope marker","type":"boolean"},"source-locations":{"description":"Classifier defined by these set of .sdf files","type":"array","items":{"$ref":"#/definitions/FilePath"}}},"additionalProperties":false},"Label":{"description":"A classifier element is a scoped classifier label (e.g. the element PII belongs to the classifier scope data)","type":"object","required":["name"],"properties":{"name":{"description":"The name of the label, use \"*\" to allow arbitrary strings as labels","type":"string"},"description":{"description":"A description of this classifier element","type":["string","null"]}},"additionalProperties":false},"Scope":{"type":"string","enum":["column","table"]},"Cardinality":{"type":"string","enum":["zero-or-one","one","zero-or-more"]},"Function":{"description":"A function block defines the signature for user defined","type":"object","required":["name"],"properties":{"name":{"description":"The name of the function [syntax: [[catalog.]schema].function]","allOf":[{"$ref":"#/definitions/String"}]},"section":{"description":"The function category","type":"string"},"dialect":{"description":"The dialect that provides this function","anyOf":[{"$ref":"#/definitions/Dialect"},{"type":"null"}]},"description":{"description":"A description of this function","type":"string"},"variadic":{"description":"Arbitrary number of arguments of an common type out of a list of valid types","allOf":[{"$ref":"#/definitions/Variadic"}]},"kind":{"description":"The function kind","allOf":[{"$ref":"#/definitions/FunctionKind"}]},"parameters":{"description":"The arguments of this function","type":["array","null"],"items":{"$ref":"#/definitions/Parameter"}},"optional-parameters":{"description":"The arguments of this function","type":["array","null"],"items":{"$ref":"#/definitions/OptionalParameter"}},"returns":{"description":"The results of this function (can be a tuple)","anyOf":[{"$ref":"#/definitions/Parameter"},{"type":"null"}]},"constraints":{"description":"The constraints on generic type bounds","type":"object","additionalProperties":{"type":"string"}},"binds":{"description":"The generic type bounds","type":"array","items":{"$ref":"#/definitions/TypeBound"}},"volatility":{"description":"volatility - The volatility of the function.","allOf":[{"$ref":"#/definitions/Volatility"}]},"examples":{"description":"example - Example use of the function (tuple with input/output)","type":"array","items":{"$ref":"#/definitions/Example"}},"cross-link":{"description":"cross-link - link to existing documentation, for example: https://trino.io/docs/current/functions/datetime.html#date_trunc","type":"string"},"reclassify":{"description":"Array of reclassify instructions for changing the attached classifier labels","type":"array","items":{"$ref":"#/definitions/Reclassify"}},"source-locations":{"description":"Function defined by these set of .sdf files","type":"array","items":{"$ref":"#/definitions/FilePath"}},"implemented-by":{"anyOf":[{"$ref":"#/definitions/FunctionImplSpec"},{"type":"null"}]},"special":{"description":"Function can be called without parentheses, e.g. as if it were a constant, e.g. current_date","type":"boolean"}},"additionalProperties":false},"Variadic":{"description":"Arbitrary number of arguments of an common type out of a list of valid types","oneOf":[{"type":"string","enum":["non-uniform"]},{"description":"All arguments have the same types","type":"string","enum":["uniform"]},{"description":"All even arguments have one type, odd arguments have another type","type":"string","enum":["even-odd"]},{"description":"Any length of arguments, arguments can be different types","type":"string","enum":["any"]}]},"FunctionKind":{"type":"string","enum":["scalar","aggregate","window","table"]},"Parameter":{"description":"A function parameter","type":"object","properties":{"name":{"description":"The name of the parameter","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]},"description":{"description":"A description of this parameter","type":["string","null"]},"datatype":{"description":"The datatype of this parameter","type":["string","null"]},"classifier":{"description":"An array of classifier references","type":["array","null"],"items":{"type":"string"}},"constant":{"description":"The required constant value of this parameter","type":["string","null"]},"identifiers":{"description":"The parameter may appear as identifier, without quote","type":["array","null"],"items":{"type":"string"}}},"additionalProperties":false},"OptionalParameter":{"description":"A function parameter","type":"object","required":["datatype","name"],"properties":{"name":{"description":"The name of the parameter","allOf":[{"$ref":"#/definitions/String"}]},"description":{"description":"A description of this parameter","type":["string","null"]},"datatype":{"description":"The datatype of this parameter","type":"string"},"classifier":{"description":"An array of classifier references","type":["array","null"],"items":{"type":"string"}},"constant":{"description":"The required constant value of this parameter","type":["string","null"]},"identifiers":{"description":"The parameter may appear as identifier, without quote","type":["array","null"],"items":{"type":"string"}}},"additionalProperties":false},"TypeBound":{"type":"object","required":["datatypes","type-variable"],"properties":{"type-variable":{"$ref":"#/definitions/String"},"datatypes":{"type":"array","items":{"type":"string"}}},"additionalProperties":false},"Volatility":{"description":"A function's volatility, which defines the functions eligibility for certain optimizations","oneOf":[{"description":"Pure - An pure function will always return the same output when given the same input.","type":"string","enum":["pure"]},{"description":"Stable - A stable function may return different values given the same input across different queries but must return the same value for a given input within a query.","type":"string","enum":["stable"]},{"description":"Volatile - A volatile function may change the return value from evaluation to evaluation. Multiple invocations of a volatile function may return different results when used in the same query.","type":"string","enum":["volatile"]}]},"Example":{"type":"object","required":["input","output"],"properties":{"input":{"description":"The sql string corresponding to the input of this example","type":"string"},"output":{"description":"The output corresponding to running the input string","type":"string"}},"additionalProperties":false},"FunctionImplSpec":{"description":"Indicates how a function's evaluation is implemented.","oneOf":[{"description":"By a built-in primitive in Datafusion. (Being phased out in favor of UDFs.)","type":"string","enum":["builtin"]},{"description":"By a UDF in the sdf-functions crate.","type":"object","required":["rust"],"properties":{"rust":{"$ref":"#/definitions/RustFunctionSpec"}},"additionalProperties":false},{"description":"By a UDF in the datafusion crate.","type":"object","required":["datafusion"],"properties":{"datafusion":{"$ref":"#/definitions/DataFusionSpec"}},"additionalProperties":false},{"description":"By a CREATE FUNCTION. (Not yet supported for evaluation.)","type":"string","enum":["sql"]}]},"RustFunctionSpec":{"type":"object","properties":{"name":{"description":"The name attribute of the implementing UDF. None indicates the UDF is named the same as the function.","type":["string","null"]}},"additionalProperties":false},"DataFusionSpec":{"type":"object","properties":{"udf":{"description":"The name attribute of the implementing UDF. None indicates the UDF is named the same as the function.","anyOf":[{"$ref":"#/definitions/String"},{"type":"null"}]}},"additionalProperties":false},"Config":{"description":"A configuration with section name and properties","type":"object","required":["name"],"properties":{"name":{"description":"The name of the configuration section","type":"string"},"description":{"description":"A description of this configuration section","type":["string","null"]},"properties":{"type":["object","null"],"additionalProperties":{"type":"string"}}},"additionalProperties":false},"Credential":{"type":"object","oneOf":[{"type":"object","required":["type","variant"],"properties":{"type":{"type":"string","enum":["sdf"]},"variant":{"description":"Variant of the credential","allOf":[{"$ref":"#/definitions/SdfAuthVariant"}]},"headless-creds":{"description":"Headless Credentials","anyOf":[{"$ref":"#/definitions/HeadlessCredentials"},{"type":"null"}]}}},{"type":"object","required":["account-id","type","username"],"properties":{"type":{"type":"string","enum":["snowflake"]},"account-id":{"description":"The account id of your snowflake account (e.g. <orgname>.<accountname> or <locator>)","type":"string"},"username":{"description":"The user name to connect to snowflake","type":"string"},"password":{"description":"The password to connect to snowflake (mutually exclusive with private_key_path)","type":["string","null"]},"private-key-path":{"description":"The path to the private key file for key pair authentication (mutually exclusive with password)","type":["string","null"]},"private-key-pem":{"description":"The private key in PEM format (mutually exclusive with private_key_path)","type":["string","null"]},"private-key-passphrase":{"description":"The passphrase for the private key, if it's encrypted","type":["string","null"]},"role":{"description":"The role to use for the connection","type":["string","null"]},"warehouse":{"description":"The warehouse to use for the connection","type":["string","null"]}}},{"type":"object","required":["client-email","private-key","project-id","type"],"properties":{"type":{"type":"string","enum":["bigquery"]},"client-email":{"description":"The client email of your bigquery service account","type":"string"},"private-key":{"description":"The base64-encoded private key of your bigquery service account","type":"string"},"project-id":{"description":"Project Id","type":"string"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["aws"]},"profile":{"description":"The name of th profile to use in the AWS credentials file","type":["string","null"]},"default-region":{"description":"The default region to use for this profile","type":["string","null"]},"role-arn":{"description":"The arn of the role to assume","type":["string","null"]},"external-id":{"description":"The external id to use for the role","type":["string","null"]},"use-web-identity":{"description":"Whether to use a web identity for authentication","type":["boolean","null"]},"access-key-id":{"description":"The access key id to use for the connection","type":["string","null"]},"secret-access-key":{"description":"The secret access key to use for the connection","type":["string","null"]},"session-token":{"description":"The session token to use for the connection","type":["string","null"]}}},{"type":"object","required":["api-key","type"],"properties":{"type":{"type":"string","enum":["openai"]},"api-key":{"description":"The api key to use for the connection","type":"string"}}},{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["empty"]}}}],"required":["name"],"properties":{"name":{"description":"The name of the credential (default = 'default')","type":"string"},"description":{"description":"A description of this credential","type":["string","null"]},"source-locations":{"description":"Credential defined by these set of .sdf files","writeOnly":true,"type":["array","null"],"items":{"$ref":"#/definitions/FilePath"}}}},"SdfAuthVariant":{"type":"string","enum":["interactive","headless","id_token_from_file"]},"HeadlessCredentials":{"type":"object","required":["access_key","secret_key"],"properties":{"access_key":{"type":"string"},"secret_key":{"type":"string"}}}}}
</schema>

[User] Provide a JSON object that satisfies the schema "Definition". Here are the required top‑level fields: none (all optional). Return only the valid JSON object.

Definition

A workspace definition

A environment definition

A table definition

A classifier definition

A function definition

A config definition

A credential definition

A config definition

A workspace is a collection of one or more catalogs, schemas, tables, and resources, called workspace members, that are managed together.

The SDF edition, should always be 1.3 (1.2 is deprecated)

The name of this workspace (defaults to the workspace directory name if not given) Name must be set for deployment.

Whether table names are treated as case sensitive in this workspace Applies globally to the entire project, and is non-overridable. Defaults to false

Note: this setting is *only* effective when set on the root workspace file, if set on included workspaces it will be ignored

A description of this workspace

The URL of the workspace source repository (defaults to 'none' if no repository is given)

An array of directories and filenames containing .sql and .sdf.yml files

An array of directories and filenames to be skipped when resolving includes

Dependencies of the workspace to other workspaces or to cloud database providers

The integrations for this environment

Defaults for this workspace

Workspace defined by these set of files

A map of named values for setting SQL variables from your environment Ex. -dt: dt, used in SQL as @dt, and in Jinja as

Configuration for dbt integration

All file path should either be relative to the workspace, or absolute for an object store like AWS s3:// Note that an [IncludePath] specifies a catalog and schema scope for unqualified names (in effect for both creating and querying tables). See [IncludePath::default_catalog] and [IncludePath::default_schema].

A filepath

Type of included artifacts: model | test | stats | metadata | resource

Index method for this include path: scan | table | schema-table | catalog-schema-table

Defaults for files on this path

Models are .sql files (ddls or queries) used for data transformation.

Tests are expectations against the data of models. Uses the sdf-test library by default.

Checks are logical expectations expresses as queries against the information schema of the SDF workspace.

Reports are informational  queries against the information schema of the SDF workspace.

Statistics are informational queries against the data of the models.

Resources are local data files (like parquet, csv, or json) used by models in the workspace.

[Deprecated] Metadata are .sdf.yml files to add additional metadata.

Specifications are .sdf.yml files to configure your workspace and add additional metadata.

Macros are .jinja files that define reusable SQL code.

Seeds are models created from resources. The sdf local engine enables type checking of seeds independently of providers. Seeds can optionally be uploaded to the remote warehouse.

Slt files are tests that follow sqllogictest format

File path is not used in figuring out the full names of the tables defined in the file. Catalog and schema are inferred from the SQL statement if possible, or from the `defaults` section in the workspace configuration. Table name is inferred from the SQL statement if possible or from the name of the file without the extension. To figure out dependencies between tables and files, SDF will parse every file in the corresponding include path. This is the default option

Table name is inferred from the file name without the extension. Catalog and schema are inferred from the `defaults` configuration. SDF assumes that a referenced table will reside in the file with the corresponding name. As a result, only the required subset of files is parsed. This option is is fast compared to the default, but it requires catalog and schemas to use the default values

Table name is inferred from the file name without the extension. Schema is inferred from the directory name in which the file resides. Catalog is inferred from the `defaults` configuration. SDF assumes that a referenced table will reside in the directory/file with the corresponding schema/table name. As a result, only the required subset of files is parsed. This option is also fast, and it allows the schema to vary based on the directory name, but it still requires catalog to use the default values

Table name is inferred from the file name without the extension. Schema is inferred from the directory name in which the file resides. Catalog is inferred from the directory name in which the schema directory resides. Defaults are not used. SDF assumes that a referenced table will reside in the catalog/schema/table file with the corresponding schema/catalog/table names. As a result, only the required subset of files is parsed. This option is also fast, and it provides the most flexibility as catalog, schema and table names can all vary

The default environment (can only be set on the level of the workspace)

The dialect of this environment. If not set, defaults to trino

Case normalization policy for names

The preprocessor for this environment. If not set, defaults to local

Defines a default catalog. If not set, defaults to the (catalog/workspace) name in an outer scope

Defines a default schema,  If not set, defaults to the schema name in an outer scope, if not set, defaults to 'pub'

Defines the default materialization, if not set defaults to materialization in outer scope, if not set defaults to base-table

Defines table creation flags, defaults to  if not set

The default utils library, if set overrides sdf_utils

The default test library, if set overrides sdf_test

The default materialization library, if set overrides sdf_materialization

The named lint rule set, uses defaults (from sdftarget/<environment>/lint.sdf.yml) if not set

The default index for this tables

The default index for this tables

The default index for this tables

The default severity for this tables tests and checks

CSV data has a header [only for external tables]

CSV data is separated by this delimiter [only for external tables]

Json or CSV data is compressed with this method [only for external tables]

Supported dialects in YAML files

Note: this [Dialect] type is *only* meant for serializing to and from `.sdf.yml` files. For internal use, you should almost always use the semantic dialect type ([types::Dialect]) instead.

Note specifically that the lack of a `.to_string()` method (i.e. [!Display]) on this type is intentional -- you must first convert this type to a [types::Dialect], by using either [Dialect::to_semantic_dialect] or [types::Dialect::from], before you can convert it to a string.

snowflake trino bigquery redshift spark-lp sdf databricks

Permanent table; e.g. for Snowflake, it will generate `CREATE OR REPLACE TABLE AS ...`

Transient tables are cost-optimized as the 90 day data retention period is not enforced. They also limit Snowflake time travel support. e.g. for Snowflake, it will generate `CREATE OR REPLACE TRANSIENT TABLE AS ...`

Temporary table; e.g. for Snowflake, it will generate `CREATE OR REPLACE TEMPORARY TABLE AS ...

Table with pre-existing data; it is not populated by SDF e.g. for Snowflake, it will generate `CREATE OR REPLACE EXTERNAL TABLE ...`

Permanent view (default option); e.g. for Snowflake, it will generate `CREATE OR REPLACE VIEW AS ...`

Materialized view; e.g. for Snowflake, it will generate `CREATE OR REPLACE MATERIALIZED VIEW AS ...`

Incremental tables are permanent tables that are gradually populated and not overwritten from scratch during every SDF run. Different SQL statements will be generated depending on whether this table already exists or not. In the latter case, an equivalent of `CREATE OR REPLACE TABLE` will be generated; in the former case, one of `INSERT INTO ...`, `MERGE ...`, or `DELETE FROM ...`, followed by `INSERT INTO ...` will be generated depending on the parameters of `incremental-options`

Snapshot tables are permanent tables that capture a snapshot of some underlying data at the time of running the query. Like incremental tables, snapshot tables are not recomputed from scratch during every SDF run

Recursive tables are permanent tables whose queries can have self-references. SDF will generate an equivalent of `CREATE RECURSIVE TABLE AS ...`. Note: in Snowflake, recursive tables are not treated specially---a normal `CREATE OR REPLACE TABLE AS...` is generated for them

User defined other materializations, it is up to users to define their own materialization logics

Attempts to create a new table; fails if the table already exists.

Drops the existing table and creates a new one.

Skips table creation if the table already exists.

Replaces the existing table with a new one. Implementation may vary by DBMS.

Creates the table only if it doesn't already exist.

Synchronizes directory on pull and push

Synchronizes directory on every pull

Synchronizes directory on every push

Never synchronizes directory

Compress table data using these methods

BZIP2 Compression (.bz2)

GZIP Compression (.gzip)

None, (default)

A filepath

Type of excluded artifacts

Excludes this path, can be a glob expression

The relative path from this workspace to the referenced workspace, for a Git repo, from the root of the depot to the workspace

The chosen workspace environment (none means default)

The chosen workspace target (none means default)

The Git repo

the Git revision (choose only one of the fields: rev, branch, tag)

the Git branch (choose only one of the fields: rev, branch, tag)

the Git tag (choose only one of the fields: rev, branch, tag)

Which models, reports, tests, checks etc. to include from the dependency

Table providers manage tables in in catalogs (OLD_PROVIDERS)

The type of the integration [e.g.: database, metadata, data]

The type of the provider [e.g.: snowflake, redshift, s3]

Credential identifier for this provider

The cluster identifier for redshift server

The size of the batch when querying the provider

A list of (possibly remote) sources to read, matched in order, so write specific pattern before more general patterns

A list of (possibly remote) targets to build,  matched in order, so write specific pattern before more general patterns, source patterns are excluded

A list of remote buckets to target

The remote output location of the integration

Sources defines the tables that are possibly remote

A source that can be read. Sources must be a three part names with globs, eg. *.*.* matches all catalogs, schema and table in scope

Time travel qualifier expression (e.g. `AT (TIMESTAMP => {{ SOME_TIMESTAMP }})``)

Whether to preload the source

Renames sources when searching in the remote, the ith ${i} matches the ith * of the name, so to prepend all catalogs,schema,table with _, use "_${1}._${2}._${3}"

Sources define the tables that are possibly remote and that will be build

A list of patterns. A pattern must be a three part names with globs, eg. *.*.* matches all catalogs, schema and table in scope

Whether to preload the target

Renames targets, the ith ${i} matches the ith * of the name, so to prepend all catalogs,schema,table with _, use "_${1}._${2}._${3}"

The uri of the bucket

The region of the bucket

A filepath

Last modified of the file

Whether the dbt integration is enabled

Dbt Project Directory

The dbt target directory for the project

The directory where dbt profiles are stored

The dbt profile to use

The dbt target for the profile

Automatically Run Parse in-between commands (default: true)

Disable introspection (default: false)

Environments provide a way to override the fields of a workspace, i.e. if an environment has set field X, then the workspace field X will be overridden by the environment field X.

A description of this workspace

The URL of the workspace source repository (defaults to 'none' if no repository is given)

An array of directories and filenames containing .sql and .sdf.yml files

An array of directories and filenames to be skipped when resolving includes

Defaults for this workspace

Dependencies of the workspace to other workspaces or to cloud database providers

The integrations for this environment

Workspace defined by these set of files

Experimental: This project has jinja

Configuration for dbt integration

A tables is either defined by given data (also called external table) or defined via a query.

The name of the table (syntax: [[catalog.]schema].table)

Note: this field is typed as a [QualifiedName] for serialization. In almost all cases you should use the [Self::fqn()] method to get the fully qualified [TableName] instead of accessing this field directly.

A description of this table

The dialect of this table, defaults to `trino`

Case normalization policy for names specified in this table

The table-type of this table (new version)

The warehouse where this table is computed

Specify what kind of table or view this is

The origin of this table <remote> or <local>

Whether the table exists in the remote DB (used for is_incremental macro)

Specify table ,location, defaults to none if not set

Defines the table creation options, defaults to none if not set

Options governing incremental table evaluation (only for incremental tables)

Options governing snapshot table evaluation (only for snapshot tables)

All tables that this table depends on (syntax: catalog.schema.table)

All tables that depend on this table (syntax: catalog.schema.table)

The columns of the schema: name, type, metadata

The partitioning format of the table

The default severity for this tables tests and checks

The schedule of the table [expressed as cron]

The first date of the table [expressed by prefixes of RFC 33]

An array of classifier references

Array of reclassify instructions for changing the attached classifier labels

Lineage, a tagged array of column references

Data is at this location

Store table in this format [only for external tables]

CSV data has a header [only for external tables]

CSV data is separated by this delimiter [only for external tables]

Json or CSV data is compressed with this method [only for external tables]

If this table is part of a cyclic dependency then cut the cycle here

Table is defined by these .sql and/or .sdf files

This table is either backed by a create table ddl or by a table definition in yml that is the table's complete schema

Metadata for this table

A regular table

A code contract

A data contract

A data report

A slt table

A SDF System table/view, maintained by the sdf cli

An External System table/view, maintained by the database system (e.g. Snowflake, Redshift, etc.)

Incremental strategy; may be one of `append`, `merge`, or `delete+insert`

Expression used for identifying records in Merge and Delete+Insert strategies; May be a column name or an expression combining multiple columns. If left unspecified, Merge and Delete+Insert strategies behave the same as Append

List of column names to be updated as part of Merge strategy; Only one of merge_update_columns or merge_exclude_columns may be specified

List of column names to exclude from updating as part of Merge strategy; Only one of merge_update_columns or merge_exclude_columns may be specified

Method for reacting to changing schema in the source of the incremental table Possible values are `fail`, `append`, and `sync`. If left unspecified, the default behavior is to ignore the change and possibly error out if the schema change is incompatible. `fail` causes a failure whenever any deviation in the schema of the source is detected; `append` adds new columns but does not delete the columns removed from the source; `sync` adds new columns and deletess the columns removed from the source;

Warehouse to use in the incremental mode

Fail when the new schema of an incremental table does not match the old one

Keep all the columns of the old incremental table schema while appending the new columns from the new schema. Initialize all the columns that were deleted in the new schema with NULL

Delete all the deleted columns from the incremental table; Append all the new columns

Snapshot strategy; may be one of `timestamp` (default), or `check`

Expression used for identifying records that will be updated according to the snapshot strategiy; May be a column name or an expression combining multiple columns

Name of the timestamp column used to identify the last update time This option is only required for the `timestamp` snapshot strategy

Specification of which columns to check for change (may be a list of column names or `all`) This option is only required for the `check` snapshot strategy

Warehouse to use in the snapshot mode

A list of column names to be used for checking if a snapshot's source data set was updated

Use all columns to check whether a snapshot's source data set was updated

The name of the column

A description of this column

The type of this column

An array of classifier references

Lineage, a tagged array of column references

Forward Lineage, the columns that this column is used to compute

Array of reclassify instructions for changing the attached classifier labels

An array of representative literals of this column [experimental!]

The default severity for this tables tests and checks

The output column is computed by copying these upstream columns

The output column is computed by transforming these upstream columns

These upstream columns are indirectly used to produce the output (e.g. in WHERE or GROUP BY)

These functions were used to produce the output column

Target classifier

Expected source classifier

The constraint macro: must have the form lib.macro(args,..), where lib is any of the libs in scope, std is available by default

The severity of this constraint

A partition is a table column, used to describe to which partition this row belongs to

The name of the partition column

A description of the partition column

The format of the partition column [use strftime format for date/time] See (guide)[https://docs.sdf.com/guide/schedules]

Store table data in these formats

A classifier defines the labels that can be attached to columns or a table.

The name of the classifier type

A description of this classifier type

Named classifier labels

Scope of the classifier: table or column

Cardinality of the classifier: zero-or-one, one or zero-or-many

Does the classifier propagate from scope to scope or is it a one scope marker

Classifier defined by these set of .sdf files

A classifier element is a scoped classifier label (e.g. the element PII belongs to the classifier scope data)

The name of the label, use "*" to allow arbitrary strings as labels

A description of this classifier element

A function block defines the signature for user defined

The name of the function [syntax: [[catalog.]schema].function]

The function category

The dialect that provides this function

A description of this function

Arbitrary number of arguments of an common type out of a list of valid types

The function kind

The arguments of this function

The arguments of this function

The results of this function (can be a tuple)

The constraints on generic type bounds

The generic type bounds

volatility - The volatility of the function.

example - Example use of the function (tuple with input/output)

cross-link - link to existing documentation, for example: https://trino.io/docs/current/functions/datetime.html#date_trunc

Array of reclassify instructions for changing the attached classifier labels

Function defined by these set of .sdf files

Function can be called without parentheses, e.g. as if it were a constant, e.g. current_date

All arguments have the same types

All even arguments have one type, odd arguments have another type

Any length of arguments, arguments can be different types

A function parameter

The name of the parameter

A description of this parameter

The datatype of this parameter

An array of classifier references

The required constant value of this parameter

The parameter may appear as identifier, without quote

A function parameter

The name of the parameter

A description of this parameter

The datatype of this parameter

An array of classifier references

A function's volatility, which defines the functions eligibility for certain optimizations

Pure - An pure function will always return the same output when given the same input.

Stable - A stable function may return different values given the same input across different queries but must return the same value for a given input within a query.

Volatile - A volatile function may change the return value from evaluation to evaluation. Multiple invocations of a volatile function may return different results when used in the same query.

The sql string corresponding to the input of this example

The output corresponding to running the input string

Indicates how a function's evaluation is implemented.

By a built-in primitive in Datafusion. (Being phased out in favor of UDFs.)

By a UDF in the sdf-functions crate.

By a UDF in the datafusion crate.

By a CREATE FUNCTION. (Not yet supported for evaluation.)

The name attribute of the implementing UDF. None indicates the UDF is named the same as the function.

A configuration with section name and properties

The name of the configuration section

A description of this configuration section

Variant of the credential

Headless Credentials

The account id of your snowflake account (e.g. <orgname>.<accountname> or <locator>)

The user name to connect to snowflake

The password to connect to snowflake (mutually exclusive with private_key_path)

The path to the private key file for key pair authentication (mutually exclusive with password)

The private key in PEM format (mutually exclusive with private_key_path)

The passphrase for the private key, if it's encrypted

The role to use for the connection

The warehouse to use for the connection

client-email private-key project-id type

The client email of your bigquery service account

The base64-encoded private key of your bigquery service account

Project Id

The name of th profile to use in the AWS credentials file

The default region to use for this profile

The arn of the role to assume

The external id to use for the role

Whether to use a web identity for authentication

The access key id to use for the connection

The secret access key to use for the connection

The session token to use for the connection

The api key to use for the connection

The name of the credential (default = 'default')

A description of this credential

Credential defined by these set of .sdf files

Provide a JSON object that satisfies the schema "Definition". Here are the required top‑level fields: none (all optional). Return only the valid JSON object.


[System]
You are a helpful assistant that answers strictly in JSON. Here's the JSON schema you must adhere to:
<schema>
{"$schema":"http://json-schema.org/draft-07/schema","title":"repository","description":"A repository of the current user\nhttps://github.com/DannyBen/secret_hub#bulk-operations","type":"object","patternProperties":{".":{"title":"secrets","description":"Secrets of the current repository\nhttps://github.com/DannyBen/secret_hub#bulk-operations","oneOf":[{"type":"array","minItems":1,"uniqueItems":true,"items":{"description":"A secret of the current repository\nhttps://github.com/DannyBen/secret_hub#bulk-operations","type":"string","minLength":1,"examples":["SECRET","PASSWORD"]}},{"title":"secret","type":"object","patternProperties":{".":{"description":"A secret of the current repository\nhttps://github.com/DannyBen/secret_hub#bulk-operations","type":["string","null"]}}}]}},"additionalProperties":false}
</schema>

[User] Provide a JSON object that satisfies the schema "repository". Here are the required top‑level fields: none (all optional). Return only the valid JSON object.

repository

A repository of the current user
https://github.com/DannyBen/secret_hub#bulk-operations

secrets

Secrets of the current repository
https://github.com/DannyBen/secret_hub#bulk-operations

A secret of the current repository
https://github.com/DannyBen/secret_hub#bulk-operations

secret

Provide a JSON object that satisfies the schema "repository". Here are the required top‑level fields: none (all optional). Return only the valid JSON object.