FeatureFuel
2

Add support for accessing raw request body in custom endpoints

Source: directus/directus#25261 · opened by @AkioSarkiz
Summary Currently, Directus does not provide a built-in way to access the raw request body (e.g., application/json) within custom endpoints. However, accessing the raw body is a common requirement for many use cases — especially when verifying signatures from third-party webhooks such as Stripe. As a workaround, developers are resorting to low-level access patterns like the one seen in this Stripe webhook extension: [directus-extension-stripe/src/stripe-hook/index.ts#L77]( While functional, this approach bypasses the standard Directus request handling flow and can lead to maintenance and compatibility issues. A native method to access the raw body would provide a cleaner, more reliable, and official solution. Basic Example Motivation Developers need a clear and simple way to access the raw request body in custom endpoints to implement logic like webhook signature verification and handle various payloads. Without native support, they rely on fragile workarounds t…

No pledges yet. Be the first to back this.

Make a pledge

Pledge your monetary support if this feature is added.

$

Comments

No comments yet.

Replying to

Add a comment

What do you think about this feature request?


Similar requests