Skip to main content

Verifying provided files comply with HSDS specification.

Project description

HSDS Validator

The HSDS validator validates provided files against Human Services Data Specification (HSDS), ensuring that they have no extra or missing fields and returning a report if the validation fails.

The validator will be accessed via the Command Line Interface (CLI) locally or deployed as an API using Docker.

Set up

Clone the repository: git clone https://github.com/stevensblueprint/hsds-validator.git

Switch into the project directory: cd hsds-validator

Create a virtual environment: python -m venv .venv (powershell) or python3 -m venv .venv (bash)

Make sure you have a version of python >= 3.13 and pip installed.

Run pip install -r requirements.txt

Or:

Install uv via pip install uv and run uv sync to install dependencies.

Run the API

On macOS/Linux

source .venv/bin/activate # Activate the virtual environment

cd api # Navigate to the API folder

uv run api # Start the API server (Press Ctrl + C in the terminal to stop)

deactivate # Deactivate the virtual environment

On Windows (PowerShell)

.venv\Scripts\activate # Activate the virtual environment

cd api # Navigate to the API folder

uv run api # Start the API server (Press Ctrl + C in the terminal to stop)

deactivate # Deactivate the virtual environment

Run the CLI

On macOS/Linux

source .venv/bin/activate   # Activate the virtual environment

python3 -m cli.main <input_directory> <schema_directory> [-o]

deactivate                  # Deactivate the virtual environment

On Windows (PowerShell)

.venv\Scripts\activate      # Activate the virtual environment

python3 -m cli.main <input_directory> <schema_directory> [-o]

deactivate                  # Deactivate the virtual environment

Parameters

  • <input_directory>: Path to directory containing JSON files to validate (required)
  • <schema_directory>: Path to directory containing JSON schema files (required)
  • -o, --save: Optional flag to save validation results to validation_results.json in the input directory

Example

python3 -m cli.main examples/program examples/json_schema
python3 -m cli.main examples/program examples/json_schema -o

Project details


Download files

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

Source Distribution

hsds_validator-0.1.1.tar.gz (50.3 kB view details)

Uploaded Source

Built Distribution

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

hsds_validator-0.1.1-py3-none-any.whl (16.6 kB view details)

Uploaded Python 3

File details

Details for the file hsds_validator-0.1.1.tar.gz.

File metadata

  • Download URL: hsds_validator-0.1.1.tar.gz
  • Upload date:
  • Size: 50.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for hsds_validator-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b78684351bd18fc0bb43c661886eac23649882f9806cac2e4036b92baf409ed2
MD5 015c467c6a4a8e1e092be4d29ed279cc
BLAKE2b-256 ddbe2b9f992c9a0f20378fb44739574627098d5c7703d84b0d05c8a991ccad61

See more details on using hashes here.

Provenance

The following attestation bundles were made for hsds_validator-0.1.1.tar.gz:

Publisher: publish_python_package.yml on stevensblueprint/hsds-validator

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

File details

Details for the file hsds_validator-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: hsds_validator-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 16.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for hsds_validator-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 798281faef2e2a4a82ad970e975354c754d7df0bf646a2b661d19e705ceecda3
MD5 6fcc86807a782368376efe8484e5cd69
BLAKE2b-256 fc7d69034d3d81caa87d97cf9c1ee3686c17fb57730d2481b1a1b53a517ea84c

See more details on using hashes here.

Provenance

The following attestation bundles were made for hsds_validator-0.1.1-py3-none-any.whl:

Publisher: publish_python_package.yml on stevensblueprint/hsds-validator

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 Pingdom Monitoring Sentry Error logging StatusPage Status page