Skip to main content

Easy use of the JSON SchemaStore from Python, as a referencing.Registry

Project description

schemastore.py

A collection of all JSON Schemas from the schemastore.org catalog, installable so they may be used without internet access.

Installation

Use your favorite package manager, e.g. via:

$ uv pip install schemastore

or

$ pip install schemastore

Usage

Schemas are made usable as a referencing.Registry. It is available as:

import schemastore
registry = schemastore.registry()

and use any of the API from the aforementioned referencing package to make use of the schemas, such as:

print(registry.get_or_retrieve("https://json.schemastore.org/github-action.json").value)

though more typically you will use the registry alongside a JSON Schema validator such as those provided by the jsonschema library:

import jsonschema
import schemastore


# Validate whether the string "foo" is a valid GitHub actions workflow (it is not.)
jsonschema.validate(
    '"foo"',
    {"$ref": "https://json.schemastore.org/github-action.json"},
    registry=schemastore.registry(),
)

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

schemastore-0.2.3.tar.gz (6.1 MB view details)

Uploaded Source

Built Distribution

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

schemastore-0.2.3-py3-none-any.whl (2.7 MB view details)

Uploaded Python 3

File details

Details for the file schemastore-0.2.3.tar.gz.

File metadata

  • Download URL: schemastore-0.2.3.tar.gz
  • Upload date:
  • Size: 6.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for schemastore-0.2.3.tar.gz
Algorithm Hash digest
SHA256 904c4e5df11968c5c3cf91d08a2b7f5f833a3f449fca80470c395154aea8a1d2
MD5 711add4913013db1a8305b76614ada7c
BLAKE2b-256 dae1999c99abac1cefad1a92559c92fcab3ce17847a5b44f95737f3520d5d138

See more details on using hashes here.

Provenance

The following attestation bundles were made for schemastore-0.2.3.tar.gz:

Publisher: ci.yml on python-jsonschema/schemastore

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

File details

Details for the file schemastore-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: schemastore-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 2.7 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for schemastore-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 049b62589e7cc3a11fa5d1977cdbf0524cf1c905a81cd0f9d27075b7578cf2d3
MD5 3f15138b951ff38d8672601f247c8a70
BLAKE2b-256 ce312d9c3ed7046c6869efb23a9d48e8968912ffe1150879793ec4ca78c08bae

See more details on using hashes here.

Provenance

The following attestation bundles were made for schemastore-0.2.3-py3-none-any.whl:

Publisher: ci.yml on python-jsonschema/schemastore

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