I tried with application/json headers and couldn’t able to verify the Recaptcha V3 token.
I found this content-type is working.
const recaptchaFeedback = await fetch(
"https://www.google.com/recaptcha/api/siteverify",
{
method: "POST",
headers: {
"Content-Type":
"application/x-www-form-urlencoded", // Correct content type
},
body: new URLSearchParams({
secret: RECAPTCHA_SECRET,
response: recatatchaToken,
}),
}
);