PHPackages                             complex-heart/sdk - 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. [Framework](/categories/framework)
4. /
5. complex-heart/sdk

ActiveLibrary[Framework](/categories/framework)

complex-heart/sdk
=================

SDK for Domain-Driven Design that provides framework-agnostic abstractions, allowing you to focus on business logic.

v3.1.0(2mo ago)11.2k1MITPHP ^8.2CI passing

Since Mar 18Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/ComplexHeart/php-sdk)[ Packagist](https://packagist.org/packages/complex-heart/sdk)[ RSS](/packages/complex-heart-sdk/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (7)Versions (6)Used By (1)

Complex Heart PHP SDK
=====================

[](#complex-heart-php-sdk)

[![Test](https://github.com/ComplexHeart/php-sdk/actions/workflows/test.yml/badge.svg)](https://github.com/ComplexHeart/php-sdk/actions/workflows/test.yml)

An SDK for building Domain-Driven Design (DDD) applications in PHP. This metapackage bundles the essential Complex Heart libraries to provide a complete toolset for implementing DDD patterns with value objects, entities, aggregates, and flexible query criteria.

Overview
--------

[](#overview)

The Complex Heart SDK is designed to ease the adoption of Domain-Driven Design principles in PHP projects by providing well-tested, production-ready components that handle common DDD patterns and challenges.

Features
--------

[](#features)

This SDK includes three core packages:

- **[Contracts](https://github.com/ComplexHeart/php-contracts)** - Common interfaces and contracts to decouple domain logic from infrastructure concerns
- **[Domain Model](https://github.com/ComplexHeart/php-domain-model)** - Base classes and utilities for building Aggregates, Entities, and Value Objects
- **[Criteria](https://github.com/ComplexHeart/php-criteria)** - Flexible query pattern implementation for building type-safe, repository-agnostic queries

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

[](#requirements)

- PHP ^8.2
- ext-json

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

[](#installation)

Install via Composer:

```
composer require complex-heart/sdk
```

This will install all three packages and their dependencies.

What's Included
---------------

[](#whats-included)

### Contracts Package

[](#contracts-package)

Provides foundational interfaces for:

- Value Objects
- Entities and Aggregates
- Domain Events
- Repositories
- Services

### Domain Model Package

[](#domain-model-package)

Offers base implementations for:

- Value Objects with validation and immutability
- Entities with identity management
- Aggregate roots with domain event handling
- Rich domain behaviors

### Criteria Package

[](#criteria-package)

Enables flexible querying with:

- Type-safe query building
- Filtering, ordering, and pagination
- Repository-agnostic design
- Composable query specifications

Documentation
-------------

[](#documentation)

For detailed documentation on each package, please visit:

- [Contracts Documentation](https://github.com/ComplexHeart/php-contracts#readme)
- [Domain Model Documentation](https://github.com/ComplexHeart/php-domain-model#readme)
- [Criteria Documentation](https://github.com/ComplexHeart/php-criteria#readme)

License
-------

[](#license)

This project is licensed under the Apache License 2.0 - see the [LICENSE](LICENSE) file for details.

Contributing
------------

[](#contributing)

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

Support
-------

[](#support)

If you encounter any issues or have questions:

- Open an issue on [GitHub Issues](https://github.com/ComplexHeart/php-sdk/issues)
- Check existing issues and discussions
- Review the documentation for each individual package

###  Health Score

47

—

FairBetter than 94% of packages

Maintenance87

Actively maintained with recent releases

Popularity20

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~242 days

Total

4

Last Release

64d ago

Major Versions

v1.0.0 → v2.0.02024-04-02

v2.0.0 → v3.0.02025-10-16

PHP version history (2 changes)v1.0.0PHP ^8.0.0

v2.0.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/7958790dcf5cd51ebbadc52fc7bada326fb3edd4481decf1006e6cfed8e46c43?d=identicon)[usantisteban](/maintainers/usantisteban)

---

Top Contributors

[![othercodes](https://avatars.githubusercontent.com/u/4815856?v=4)](https://github.com/othercodes "othercodes (8 commits)")

---

Tags

aggregatesclean-architecturecqrsdddentitieshexagonal-architectureports-and-adaptersvalue-object

### Embed Badge

![Health badge](/badges/complex-heart-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/complex-heart-sdk/health.svg)](https://phpackages.com/packages/complex-heart-sdk)
```

###  Alternatives

[laravel/telescope

An elegant debug assistant for the Laravel framework.

5.2k67.8M192](/packages/laravel-telescope)[spiral/roadrunner

RoadRunner: High-performance PHP application server and process manager written in Go and powered with plugins

8.4k12.2M84](/packages/spiral-roadrunner)[nolimits4web/swiper

Most modern mobile touch slider and framework with hardware accelerated transitions

41.8k177.2k1](/packages/nolimits4web-swiper)[laravel/dusk

Laravel Dusk provides simple end-to-end testing and browser automation.

1.9k36.7M259](/packages/laravel-dusk)[laravel/prompts

Add beautiful and user-friendly forms to your command-line applications.

708181.8M596](/packages/laravel-prompts)[cakephp/chronos

A simple API extension for DateTime.

1.4k47.7M121](/packages/cakephp-chronos)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
