Skip to main content

Pydantic models for schema.org

PyPI

Schema.org is a community-driven vocabulary that allows users to add structured data to content on the web. It's used by webmasters to help search engines understand web pages. Knowledge graphs such as yago also use schema.org to enforce semantics on wikidata.

Pydantic is the most widely used data validation library for Python.

This project includes a script that converts the schema defined in N-Triples(nt) format into a pydantic object. These objects can be used to validate any input data for conformance.

The inheritance hierarchy of the schema is accurately reflected in the python inheritance hierarchy.

Usage:

curl -LO https://schema.org/version/latest/schemaorg-all-https.nt
uv run create_pydantic.py schemaorg-all-https.nt
pytest

One time setup:

pre-commit install

Schemas are provided under the following license.

Metadata

Release files for schema-org-python 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for schema-org-python 0.1.2
File Size Uploaded Provenance Actions
schema_org_python-0.1.2.tar.gz 539.5 kB Without provenance Details for schema_org_python-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for schema-org-python 0.1.2
File Interpreter ABI Platform Actions
schema_org_python-0.1.2-py3-none-any.whl Python 3 none any Details for schema_org_python-0.1.2-py3-none-any.whl

Total release size: 1.0 MB

Release files / schema_org_python-0.1.2.tar.gz

Download URL schema_org_python-0.1.2.tar.gz
Size 539.5 kB
Tags Source
SHA-256 checksum
How to use checksums
98ec3fc83df58100e7e5c3af2c862d33068d336eef4bd605a1f7f32f5cc9a5f6
BLAKE2b-256 checksum
How to use checksums
71c989b6441722d1ea0dcc59dc6e0d0ab4bcc379aefc826ede9a5943d3f00591
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.3

Release files / schema_org_python-0.1.2-py3-none-any.whl

Download URL schema_org_python-0.1.2-py3-none-any.whl
Size 462.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d96f58ad05c65317a805b5878a63a060656321788a917cb3b909eea5827babbf
BLAKE2b-256 checksum
How to use checksums
04ddc6a5eff53ad2504148f27b0519027400d0e797e82153108611e804382188
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.3

Security for schema-org-python 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page