Skip to content

Repository files navigation

PHP Json Schema Validator

ReleasePHPPHPStanPHPUnitPHPCSPHPMDRector - Instant Upgrades and Automated RefactoringLICENSE

An easy-to-use PHP Json Schema Validator on top of opis/json-schema.

1. Usage

useIxnode\PhpJsonSchemaValidator\Validator;
$data = '[1, 2, 3]';
$schema = [
'type' => 'object'
];
$validator = newValidator(newJson($data), newJson($schema));
$valid = $validator->validate();
// (bool) true

2. Installation

composer require ixnode/php-json-schema-validator
vendor/bin/php-json-schema-validator -V
php-json-schema-validator 0.1.0 (12-31-2022 15:51:08) - Björn Hempel <bjoern@hempel.li>

3. Library development

git clone git@github.com:ixnode/php-json-schema-validator.git &&cd php-json-schema-validator
composer install
composer test

4. License

This tool is licensed under the MIT License - see the LICENSE file for details

About

PHP Json Schema Validator

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages