{"id":13684346,"url":"https://github.com/dereuromark/cakephp-dto","last_synced_at":"2026-04-02T19:12:08.691Z","repository":{"id":41364452,"uuid":"160880030","full_name":"dereuromark/cakephp-dto","owner":"dereuromark","description":"CakePHP DTO plugin - quickly generate useful data transfer objects for your app (mutable/immutable)","archived":false,"fork":false,"pushed_at":"2026-03-30T23:15:28.000Z","size":802,"stargazers_count":29,"open_issues_count":1,"forks_count":6,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-03-31T01:30:03.094Z","etag":null,"topics":["data-transfer","transfer-objects"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dereuromark.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2018-12-07T22:03:29.000Z","updated_at":"2026-03-30T23:13:31.000Z","dependencies_parsed_at":"2023-09-28T19:15:09.000Z","dependency_job_id":"4c51d92c-7ff5-46dc-a51c-6f0b9a2d6d90","html_url":"https://github.com/dereuromark/cakephp-dto","commit_stats":{"total_commits":261,"total_committers":11,"mean_commits":"23.727272727272727","dds":0.4444444444444444,"last_synced_commit":"671ee3d2d60859b208ec4ebf6297848c3ae3315d"},"previous_names":[],"tags_count":52,"template":false,"template_full_name":null,"purl":"pkg:github/dereuromark/cakephp-dto","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dereuromark%2Fcakephp-dto","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dereuromark%2Fcakephp-dto/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dereuromark%2Fcakephp-dto/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dereuromark%2Fcakephp-dto/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dereuromark","download_url":"https://codeload.github.com/dereuromark/cakephp-dto/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dereuromark%2Fcakephp-dto/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31314117,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-02T12:59:32.332Z","status":"ssl_error","status_checked_at":"2026-04-02T12:54:48.875Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-transfer","transfer-objects"],"created_at":"2024-08-02T14:00:32.459Z","updated_at":"2026-04-02T19:12:08.674Z","avatar_url":"https://github.com/dereuromark.png","language":"PHP","funding_links":[],"categories":["Miscellaneous","Plugins"],"sub_categories":["Miscellaneous"],"readme":"# CakePHP DTO plugin\n\n[![CI](https://github.com/dereuromark/cakephp-dto/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/dereuromark/cakephp-dto/actions/workflows/ci.yml?query=branch%3Amaster)\n[![codecov](https://img.shields.io/codecov/c/github/dereuromark/cakephp-dto/master.svg)](https://codecov.io/gh/dereuromark/cakephp-dto)\n[![Latest Stable Version](https://poser.pugx.org/dereuromark/cakephp-dto/v/stable.svg)](https://packagist.org/packages/dereuromark/cakephp-dto)\n[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%208.2-8892BF.svg)](https://php.net/)\n[![License](https://poser.pugx.org/dereuromark/cakephp-dto/license.svg)](LICENSE)\n[![Total Downloads](https://poser.pugx.org/dereuromark/cakephp-dto/d/total.svg)](https://packagist.org/packages/dereuromark/cakephp-dto)\n[![Coding Standards](https://img.shields.io/badge/cs-PSR--2--R-yellow.svg)](https://github.com/php-fig-rectified/fig-rectified-standards)\n\nA Data Transfer Object (DTO) is an object used to pass typed data between layers in your application, similar in\nconcept to [Structs](https://en.wikipedia.org/wiki/Struct_(C_programming_language)) in C, Martin Fowler's [Transfer\n Objects](http://martinfowler.com/eaaCatalog/dataTransferObject.html), or [Value Objects](https://en.wikipedia.org/wiki/Value_object).\n\nThe goal of this package is to structure \"unstructured data\", replacing simple (associative) arrays with a more speaking solution.\n\n**Unique approach:** Unlike other PHP DTO libraries that use runtime reflection, this plugin generates actual PHP code from configuration files.\nThis provides the best possible IDE support, static analysis compatibility, and runtime performance.\nSee [Motivation](https://github.com/php-collective/dto/blob/master/docs/Motivation.md) for a comparison with alternatives.\n\n- By making all fields typeable, we can be sure that their values are never something we didn't expect.\nEspecially with modern PHP and more strict typehinting moving forward this is rather important to detect and fail early.\n- We can have full IDE autocomplete and typehinting.\n- We can use tools like PHPStan to statically analyze the code (more strictly).\n- We can simplify the logic where required fields will now just throw a meaningful exception.\n- We can work with different inflections of field names more easily.\n- Easy way of immutable DTOs with required fields, to trust them in following code.\n- Works out of the box with any [value object](https://github.com/Serhii-DV/awesome-php-value-objects) that is serializable (either as array or string).\n\nThis plugin will provide you with a tool to quickly generate custom and optimized DTOs for your special use cases.\n\nCakePHP integration for [php-collective/dto](https://github.com/php-collective/dto).\n\nThis branch is for use with **CakePHP 5.1+**. For details see [version map](https://github.com/dereuromark/cakephp-dto/wiki#cakephp-version-map).\n\n## Examples\n\nLive examples in the Sandbox: [Github Demo](https://sandbox.dereuromark.de/sandbox/dto-examples/github).\n\nSee [Examples](docs/Examples.md) for basic, immutable, mapper, and complex entity use cases.\nThe generated demo DTOs of those are in [tests/test_app/src/Dto/](tests/test_app/src/Dto/).\n\nNote: Param/return types are enabled and strict types disabled by default.\n\n## Installation\n\nYou can install this plugin into your CakePHP application using [Composer](https://getcomposer.org/).\n\n```\ncomposer require dereuromark/cakephp-dto\n```\n\nThen load the plugin with the following command:\n```\nbin/cake plugin load CakeDto\n```\n\n## Usage\n\nSee [Docs](docs/README.md) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdereuromark%2Fcakephp-dto","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdereuromark%2Fcakephp-dto","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdereuromark%2Fcakephp-dto/lists"}