Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hanif365/30fa38b97f1f92191c8dfa96f1e6c3c3 to your computer and use it in GitHub Desktop.
Save hanif365/30fa38b97f1f92191c8dfa96f1e6c3c3 to your computer and use it in GitHub Desktop.
import { NextResponse } from "next/server";
export const POST = async (request) => {
const url = new URL(request.url);
const searchParams = new URLSearchParams(url.search);
const transactionId = searchParams.get("transactionId"); // Retrieves the value of the 'transactionId' parameter
console.log(transactionId);
return NextResponse.json({ transactionId: transactionId });
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment