talira

Validate, define, and use dynamic and text-based data

open sourceApache-2.0free

CUE is an open source data validation language and inference engine with its roots in logic programming. It merges types and values into one hierarchy, so the same file can be a schema, a set of constraints and the data itself, and combining CUE values in any order gives the same result. Teams use it to validate JSON and YAML, define and check large configurations, template values and defaults to cut boilerplate, generate code and schemas (Go, Protobuf, OpenAPI) and script workflows. The cue command line tool and a Go API do the work, and modules are shared through OCI registries such as the CUE Central Registry. Its roots lie in GCL, Google's internal configuration language. Apache-2.0 licensed.

Libraries for CUE

Talira doesn't list any yet.

Problems it solves

  • validate my YAML and JSON config files against a schema in CI
  • a typed configuration language for large Kubernetes configurations
  • which config language should we use to replace templated YAML
  • merge configuration from several teams without conflicts
  • keep my OpenAPI, Protobuf and Go definitions in sync from one schema
  • check that a new version of a schema is backwards compatible

Features

  • types and values in one lattice: schemas, constraints and data in one language
  • validate JSON and YAML against CUE schemas
  • order-independent unification of configuration from many sources
  • templates and defaults to remove boilerplate
  • generate and extract code and schemas (Go, Protobuf, OpenAPI)
  • modules published to OCI registries such as the CUE Central Registry
  • Go API and cue command line tool

Capabilities

Has a command line toolplan not known
Has official SDKsplan not known

Alternatives

The same job

These do what CUE does.

  1. Pkl A configuration-as-code language with rich validation and tooling
  2. KCL An open-source constraint-based record and functional language for configuration and policy
  3. Nickel Better configuration for less
  4. Jsonnet A configuration language for app and tool developers
  5. HCL The HashiCorp configuration language
  6. Starlark A Python dialect designed as a configuration language, made for Bazel

Compare CUE with the top 3