Skip to main content

A lightweight JSON Schema validation library for Robot Framework with clear error reporting and flexible validation modes.

Project description

📘 robotframework-jsonvalidator

A lightweight and extensible JSON Schema validation library for use in Robot Framework test suites.
Designed for clarity, reliability, and maintainability, it provides meaningful diagnostics when validating one or multiple JSON documents.


🚀 Overview

robotframework-jsonschemavalidator enables automated test suites to validate JSON payloads using standard JSON Schemas.
It offers configurable validation behavior and clean logging to support both small and large‑scale test automation.

This library focuses on:

  • Clear JSON structure validation
  • Helpful, readable error reporting
  • Easy use within Robot Framework
  • Flexibility for local development and CI/CD environments

See keyword documentation for more information.


✨ Features

  • Schema-based validation using the well‑known jsonschema engine
  • Load schemas from file paths or in‑memory dictionaries
  • Validate single or multiple JSON documents
  • Choose between:
    • Fail‑fast mode for immediate errors
    • Collect‑all mode for batch reporting per test
  • Error reporting includes:
    • Source document identifier
    • JSON path to the error location
    • Failing schema keyword
    • Human‑readable explanation
  • Designed for seamless integration with:
    • Robot Framework
    • CI/CD

📦 Installation

Using uv (recommended)

uv add robotframework-jsonschemavalidator

Using poetry

poetry add robotframework-jsonschemavalidator

Using pip

pip install robotframework-jsonschemavalidator

This makes the library available to Robot Framework as:

*** Settings ***
Library    JsonSchemaValidator

🧱 Project Structure

robotframework-jsonschemavalidator/
├─ pyproject.toml
├─ src/
│   └─ JsonSchemaValidator/
│       ├─ __init__.py
│       ├─ JsonSchemaValidator.py   # Core implementation
│       └─ errors.py
└─ tests/
    └─ atest.robot

🧪 Testing & Development

Running Robot Tests

uv run robot tests/

🤝 Contributing

Contributions are encouraged and appreciated.
To contribute:

  1. Fork the repository
  2. Create a feature branch
  3. Commit changes with meaningful messages
  4. Submit a pull request

For major changes, please open an issue to discuss before starting work.

Contributing Guidelines

  • Maintain consistent naming for keywords
  • Keep documentation up to date with new features
  • Include tests for new functionality
  • Follow existing styles for logging and error reporting

Pull requests and issue reports are welcome!


📄 License

Licensed under the Apache License 2.0. See LICENSE.


Author

Mickel Jacobs

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

robotframework_jsonschemavalidator-1.0.0.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

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

File details

Details for the file robotframework_jsonschemavalidator-1.0.0.tar.gz.

File metadata

File hashes

Hashes for robotframework_jsonschemavalidator-1.0.0.tar.gz
Algorithm Hash digest
SHA256 25c5889a51c6936079865974117e838b77fa569030d86175453d5864a2a5e17a
MD5 e62441f196a6a0c29a11fdead4019290
BLAKE2b-256 53c37df6e2c4b0030b4e7a08cf0bdfe4e02d0705659b9e85dccfde8ea1c93911

See more details on using hashes here.

Provenance

The following attestation bundles were made for robotframework_jsonschemavalidator-1.0.0.tar.gz:

Publisher: deploy.yml on MarketSquare/robotframework-jsonschemavalidator

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

File details

Details for the file robotframework_jsonschemavalidator-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for robotframework_jsonschemavalidator-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8a66eadb45224cf750719d2d558713abbccb48769a7ac7215c3449e149c37e6a
MD5 345d76a1a271b8342e255fb13bba60bc
BLAKE2b-256 78631d1a664b8af27878e93b9e4d0e898a4cbef911f869b068a5733c1ca6391e

See more details on using hashes here.

Provenance

The following attestation bundles were made for robotframework_jsonschemavalidator-1.0.0-py3-none-any.whl:

Publisher: deploy.yml on MarketSquare/robotframework-jsonschemavalidator

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