qandidate/symfony-json-request-transformer
Symfony package that decodes JSON request bodies into standard request parameters, so forms, validation, and controllers handle JSON APIs without custom parsing. A lightweight request transformer for cleaner Symfony JSON endpoints.
qandidate/symfony-json-request-transformer is a single-purpose Symfony bundle: an event listener on kernel.request that detects a JSON Content-Type, decodes the body, and replaces the request's parameter bag so controllers can read JSON fields like form fields. That is the entire surface area — roughly one listener class plus bundle registration.
kernel.request event and no Symfony event-dispatcher contract in that shape; it uses an HTTP middleware pipeline. More importantly, the capability is already native: Illuminate\Http\Request::getInputSource() returns a decoded-JSON ParameterBag when isJson() is true, so $request->input()/$request->json() work out of the box. The package solves a problem Laravel does not have.0 dependents means no field evidence that anyone has done this successfully.$request->json() / input() does not? Is any part of the target system actually Symfony-based, and at which HttpKernel version? Who would own a fork, and against what upgrade cadence? Does our dependency policy permit archived packages in production, and what is the documented exit criterion? The metadata reinforces the answer: score 0.58 with an opportunity score of 17.11 and zero dependents reads as low-momentum, low-leverage.symfony/http-foundation alone does not give you the event listener the package hooks into. Pure Symfony below 6.1: this is the only context where the package historically earned its place, and even there it is now superseded by Request::toArray() / getPayload() and the json request format introduced in 6.1.$request->json('field') or $request->input('field') in Laravel, $request->getPayload()->get('field') in Symfony ≥6.1. If a team genuinely needs a package-level abstraction — for example, uniform validation of JSON bodies across a mixed fleet — write a narrow middleware that calls json_decode with depth/size guards, returns 400 on JSON_ERROR_*, and emits a typed exception. That removes the archived dependency entirely at roughly a day of effort.http-kernel and http-foundation. Verify before any spike: the package requires symfony/http-kernel, which Laravel does not pull in, so installing it drags a parallel HTTP stack into the dependency graph for no functional gain. Assume it will not resolve cleanly against Laravel 10/11 or Symfony 6.4/7 without --ignore-platform-reqs, which is itself a red flag.$request->json() behavior on the actual stack. (2) If a gap exists, prototype the middleware locally rather than installing the package. (3) Run a dependency and license review that explicitly records archived status. (4) Only if the package is still indicated, fork under MIT, pin the fork, add tests for malformed JSON, content-type edge cases, and parameter shadowing, and name an owner. (5) Set a review date tied to the next framework major.application/json; charset=utf-8, vendor +json types); parameter-bag shadowing that lets a JSON body override route or query parameters — a security-review item, not just a bug; deeply nested payloads hitting default depth limits; and ordering conflicts with other request-stage listeners or middleware.getPayload() cannot meet.How can I help you explore Laravel packages today?