spec-version
: The version of Gable’s data contract specification.
type
: stringconstraints
: Valid semantic spec version. Currently supported versions are 0.1.0
.namespace
: A unique named collection of contracts. This field is meant to be a user-defined space that has meaning within your organization.
type
: stringconstraints
: (?=.*[a-zA-Z0-9])[A-Za-z0-9\.\_]
(Must include at least one alphanumeric character,can include special characters .
and _
)name
: The name of the contract which, when combined with the namespace, uniquely identifies the contract.
type
: stringconstraints
: (?=.*[a-zA-Z0-9])[a-zA-Z0-9_]
(Must include at least one alphanumeric character, can include special character _
)doc
: Documentation for the contract, can be specified with YAML’s multi-line syntax
type
: stringdataAssetResourceName
: The unique resource name of the data asset this contract covers. See Data Assets for more details
type
: stringconstraints
: Must be a valid resource name in the format <type>://<source>:<dataset>
owner
: The email for the team or individual who owns the data contract
type
: email (string)schema
: The schema definition of the data asset. Gable uses a flexible type system for contract schemas, see the below section on the type specification for more details. At minimum, each field contains a name and type. Types can be primitives, or complex types like unions, lists, and nested objects.
type
: list[Type]
constraints
: In the data contract schema, various constraints can be applied to ensure data quality. These constraints define the conditions that the data must satisfy. Below are the detailed descriptions of the supported constraints:
Warning:
Currently contract constraints only exist for S3
based assets
GREATER_THAN
:
GREATER_THAN_OR_EQUAL_TO
:
LESS_THAN
:
LESS_THAN_OR_EQUAL_TO
:
IS_NULL
:
IS_NULL_THRESHOLD
:
IS_NOT_EMPTY
:
LENGTH
:
LENGTH_GREATER_THAN
:
LENGTH_GREATER_THAN_OR_EQUAL_TO
:
LENGTH_LESS_THAN
:
LENGTH_LESS_THAN_OR_EQUAL_TO
:
OneBusAway
, an open source project providing public APIs for transit information: