shureban/laravel-object-mapper
Laravel object mapper maps JSON strings, arrays, and FormRequest data into typed PHP objects (DTOs) using reflection. Use inheritance, a trait, or ObjectMapper directly; supports readonly DTOs and static constructors. Works out of the box via auto-discovery.
Str::camel() or frontend-specific libraries.$casts or API resources for simpler cases.Executives:
"This Laravel package automates the tedious task of converting database snake_case fields (e.g., user_name) to camelCase (userName) for APIs and frontend consumption. It saves development time, reduces bugs from manual mapping, and aligns with modern frontend frameworks. The latest release (v2.0.1) also supports Laravel 13, so this is a low-risk, long-lived dependency rather than something we'll need to rip out at the next framework upgrade. Note we're now on a new major version line (2.x), so any existing 1.x usage needs a short, planned migration."
Engineering/Tech Leads: "v2.0.1 adds Laravel 13 compatibility on top of the 2.x line—no new features, but it confirms the package is actively maintained against current framework releases. If you're still on 1.2.0, plan the 2.x upgrade explicitly: it's a major version bump, so review the v2.0.0 changelog for breaking changes, update your Composer constraint, and regression-test mapping output before merging. For new projects on Laravel 13, this is a safe adopt with no additional integration work. Lightweight, Composer-installed, and consistent with Laravel conventions."
How can I help you explore Laravel packages today?