PHPackages                             gosuperscript/schema - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Validation &amp; Sanitization](/categories/validation)
4. /
5. gosuperscript/schema

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

gosuperscript/schema
====================

A PHP library for data transformation, type validation, and expression evaluation.

v0.3.4(1mo ago)01.5k[3 PRs](https://github.com/gosuperscript/axiom/pulls)MITPHPPHP ^8.4CI passing

Since Jul 25Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/gosuperscript/axiom)[ Packagist](https://packagist.org/packages/gosuperscript/schema)[ RSS](/packages/gosuperscript-schema/feed)WikiDiscussions 0.x Synced 1mo ago

READMEChangelog (10)Dependencies (23)Versions (38)Used By (0)

Axiom Library
=============

[](#axiom-library)

A powerful PHP library for data transformation, type validation, and expression evaluation. This library provides a flexible framework for defining data schemas, transforming values, and evaluating complex expressions with type safety.

Features
--------

[](#features)

- **Type System**: Robust type validation and transformation for numbers, strings, booleans, lists, and dictionaries
- **Expression Evaluation**: Support for infix expressions with custom operators
- **Match Expressions**: Unified conditional logic — if/then/else, dispatch tables, and cond-style matching
- **Resolver Pattern**: Pluggable resolver system for different data sources
- **Symbol Registry**: Named value resolution and reuse
- **Operator Overloading**: Extensible operator system for custom evaluation logic
- **Monadic Error Handling**: Built on functional programming principles using Result and Option types

Requirements
------------

[](#requirements)

- PHP 8.4 or higher
- ext-intl extension

Installation
------------

[](#installation)

```
composer require gosuperscript/axiom
```

Quick Start
-----------

[](#quick-start)

### Basic Type Transformation

[](#basic-type-transformation)

```
