Next.js Discord

Discord Forum

Sending a payload to nextjs route

Unanswered
Birman posted this in #help-forum
Open in Discord
BirmanOP
I have an intriguing issue with a Next.js route. The route's rendering depends on a payload from a different web application. When redirecting to the Next.js route, I'm unsure of the best way to pass this payload since using query params isn't feasible due to size and security constraints. One approach I considered is hosting a POST API to store the payload in a database before rendering the route, passing an identifier as a query param. However, this adds an additional blocking call. Does anyone know of a more optimal solution? Thanks.

1 Reply

BirmanOP
The payload is available at run time only which should sent by web application before redirecting the user on next js route.