Lambda not getting triggered for API call

0

On hitting APIs, authorizer lambda is triggered and responds with Success/Allow but main lambda is not triggered to complete the API call. Response of Authorizer:{ Version: '2012-10-17', Statement: [ { Action: 'execute-api:Invoke', Effect: 'Allow', Resource: '<<arn>>/api/POST/audit/postaudit' } ] }

The same code is deployed through Gitlab CI in different branches, some branche APIs are working fine while other branches having above error.

2 Antworten
0

Hi

Lets try debugging:

  • Ensure the main Lambda is still integrated with the API method in API Gateway. Test it directly using a sample event. Link refrence
  • Enable the Logging on the API GW to see what happening about the triggering. Enable Logging on API GW
  • Check your GitLab CI pipeline for deployment discrepancies. Check GitLab CI for deployment differences.
  • Review authorizer policy and CORS settings.
profile picture
EXPERTE
GK
beantwortet vor 24 Tagen
0

Make sure that the Lambda function's resource policy allows API Gateway to invoke it.

profile pictureAWS
EXPERTE
Uri
beantwortet vor 24 Tagen

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen