> For the complete documentation index, see [llms.txt](https://astrals-organization.gitbook.io/php-serialize/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://astrals-organization.gitbook.io/php-serialize/php-serialize-en/readme.md).

# Introduction

**php-serialize** is a powerful attribute-based PHP serialization library (requires PHP ≥ 8.1). It allows you to map objects to arrays or JSON, and can automatically generate OpenAPI documentation based on the same

> 🚀 Unified solution supporting API data serialization and document generation.

## ✨ Features

* 🏷️ Property alias mapping
* 🔄 Automatic type conversion
* 🔁 Support for deep object nesting
* ❌ Support for skipping/excluding fields
* 🧩 Recursive DTO (Data Transfer Object) serialization
* 🧬 Automatically generate OpenAPI schema based on object definitions
* ⚙️ Framework-agnostic — compatible with Laravel, Symfony, and more
