Skip to main content

reCaptcha - Error - '403' PERMISSION_DENIED

  • March 28, 2024
  • 3 replies
  • 462 views

Forum|alt.badge.img

Hi,

I'm trying to create assessment in my app by salesforce, it returns an error like "{ "error": { "code": 403, "message": "Requests from this referrer are blocked.", "status": "PERMISSION_DENIED" } }" from backend.

3 replies

JoshD
Staff
Forum|alt.badge.img+2
  • Staff
  • June 25, 2024

Hi Prasanna23,

Josh from the reCAPTCHA team here. Apologies for the slow reply! Are you still having this issue? This error does not look like one from the reCAPTCHA endpoint, so I suspect it may be coming from the Salesforce integration itself. 


Forum|alt.badge.img
  • New Member
  • January 12, 2025

I am getting: { "error": { "code": 403, "message": "Requests to this API method are blocked.", "status": "PERMISSION_DENIED" } }
Before that error I got 400 with this response.
{ "error": { "code": 400, "message": "Invalid JSON payload received. Unknown name \\"event[token]\\": Cannot bind query parameter. Field 'event[token]' could not be found in request message.\\nInvalid JSON payload received. Unknown name \\"event[siteKey]\\": Cannot bind query parameter. Field 'event[siteKey]' could not be found in request message.", "status": "INVALID_ARGUMENT", "details": [ { "@type": "type.googleapis.com/google.rpc.BadRequest", "fieldViolations": [ { "description": "Invalid JSON payload received. Unknown name \\"event[token]\\": Cannot bind query parameter. Field 'event[token]' could not be found in request message." }, { "description": "Invalid JSON payload received. Unknown name \\"event[siteKey]\\": Cannot bind query parameter. Field 'event[siteKey]' could not be found in request message." } ] } ] } }


In both requests I had valid json values (redacted):

{ "event": { "token": "TOKEN_STRING", "siteKey": "MY_SITE_KEY" } }


JoshD
Staff
Forum|alt.badge.img+2
  • Staff
  • January 15, 2025

I am getting: { "error": { "code": 403, "message": "Requests to this API method are blocked.", "status": "PERMISSION_DENIED" } }
Before that error I got 400 with this response.
{ "error": { "code": 400, "message": "Invalid JSON payload received. Unknown name \\"event[token]\\": Cannot bind query parameter. Field 'event[token]' could not be found in request message.\\nInvalid JSON payload received. Unknown name \\"event[siteKey]\\": Cannot bind query parameter. Field 'event[siteKey]' could not be found in request message.", "status": "INVALID_ARGUMENT", "details": [ { "@type": "type.googleapis.com/google.rpc.BadRequest", "fieldViolations": [ { "description": "Invalid JSON payload received. Unknown name \\"event[token]\\": Cannot bind query parameter. Field 'event[token]' could not be found in request message." }, { "description": "Invalid JSON payload received. Unknown name \\"event[siteKey]\\": Cannot bind query parameter. Field 'event[siteKey]' could not be found in request message." } ] } ] } }


In both requests I had valid json values (redacted):

{ "event": { "token": "TOKEN_STRING", "siteKey": "MY_SITE_KEY" } }


Hi azaric,

What type of API method are you using to push this? This says "requests to this API method are blocked" so I'm suspecting you might not be using the supported POST method to make this call:
https://cloud.google.com/recaptcha/docs/reference/rest/v1/projects.assessments/create