Skip to main content

Data Product CLI

The dataproduct CLI is an open-source command-line tool for working with data products defined with the Open Data Product Standard (ODPS).

It is the data-product sibling of datacontract-cli (which targets the Open Data Contract Standard) and mirrors its technology and release mechanism. The tool is written in Python and can be used standalone, in CI/CD, or as a Python library.

The behavior of each command is specified in specs/.

Install

uv tool install --python python3.11 dataproduct-cli
# or
pip install dataproduct-cli

Commands

init — create a data product

dataproduct init                       # writes ./dataproduct.odps.yaml
dataproduct init my.odps.yaml          # custom path
dataproduct init --overwrite           # replace an existing file
dataproduct init --template <url|path> # seed from a template or existing product

lint — validate against the ODPS standard

dataproduct lint                                   # lints ./dataproduct.odps.yaml
dataproduct lint my.odps.yaml
dataproduct lint --all-errors                      # report every schema violation
dataproduct lint --output-format junit --output TEST-dataproduct.xml
dataproduct lint --json-schema ./odps.schema.json  # validate against a custom schema

Validation is schema-only in 0.1: the data product is checked against the bundled ODPS v1.0.0 JSON Schema. Exit code is 0 when valid, 1 otherwise.

publish — publish to Entropy Data

export ENTROPY_DATA_API_KEY=...        # from Entropy Data → Settings → API Keys
dataproduct publish my.odps.yaml

publish sends PUT {host}/api/dataproducts/{id} with an x-api-key header. The host defaults to https://api.entropy-data.com and can be overridden with ENTROPY_DATA_HOST. The referenced team must already exist in your org.

Configuration

Purpose Variable (with fallbacks)
API host ENTROPY_DATA_HOSTDATAMESH_MANAGER_HOSTDATACONTRACT_MANAGER_HOSThttps://api.entropy-data.com
API key ENTROPY_DATA_API_KEYDATAMESH_MANAGER_API_KEYDATACONTRACT_MANAGER_API_KEY

.env files are loaded automatically.

Use as a library

from dataproduct.data_product import DataProduct

run = DataProduct(data_product_file="dataproduct.odps.yaml").lint()
assert run.result == "passed"

DataProduct(data_product_file="dataproduct.odps.yaml").publish()

Development

See AGENTS.md.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dataproduct_cli-0.1.0.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dataproduct_cli-0.1.0-py3-none-any.whl (22.1 kB view details)

Uploaded Python 3

File details

Details for the file dataproduct_cli-0.1.0.tar.gz.

File metadata

  • Download URL: dataproduct_cli-0.1.0.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dataproduct_cli-0.1.0.tar.gz
Algorithm Hash digest
SHA256 58738907591095a4291bccf5a9ed5f06540b26b69e4ea3f00de767395808c592
MD5 47cb92093cc97c2d021ed4cb41805948
BLAKE2b-256 206c4576d81dbb53a70918b932fb49dab7557ed2bc01f2d40ce45681975331cf

See more details on using hashes here.

Provenance

The following attestation bundles were made for dataproduct_cli-0.1.0.tar.gz:

Publisher: release.yaml on datacontract/dataproduct-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dataproduct_cli-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: dataproduct_cli-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 22.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dataproduct_cli-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 db2d443afc987bda74ce4ebb48d2066fa0389fd330a0247530ee6fd64472f13a
MD5 83f530f13c42c0ad63bd006f939476ef
BLAKE2b-256 d52596e21892934c20fe0ff63f51805e2a76a68f40ad3ee229596451a448a9d6

See more details on using hashes here.

Provenance

The following attestation bundles were made for dataproduct_cli-0.1.0-py3-none-any.whl:

Publisher: release.yaml on datacontract/dataproduct-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page