Skip to content

feat: Verifier accept Symfony HttpFoundation Request #160

Description

@EstimationApp

Please describe your feature request.

Symfony is one of the most widely used PHP frameworks, and its controllers receive a Symfony\Component\HttpFoundation\Request, not a PSR-7 RequestInterface.

Today, Symfony users integrating Paddle webhooks must:

  1. Pull in symfony/psr-http-message-bridge.
  2. Pull in a PSR-7 implementation such as nyholm/psr7.
  3. Wire up an HttpMessageFactoryInterface service.
  4. Convert the incoming request on every webhook call before handing it to the verifier.

This is a non-trivial amount of boilerplate for what should be a one-liner.

Describe your solution.

Given Symfony's popularity in the PHP ecosystem, accepting its native Request object directly would significantly lower the barrier to integration and improve developer experience.

(new Verifier())->verify(
    Symfony\Component\HttpFoundation\Request|Psr\Http\Message\RequestInterface $request,
    new Secret('WEBHOOK_SECRET_KEY')
);

Describe alternatives you have considered.

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions