Hi Oscar,
If you're using the API Gateway, you'll need to catch this is a post-error global policy, and when you do, you'll need to use the context.get('error') object to get the status code and reason phrase and reset the message.status.statusCode as this is reset when you catch any exception.
Regards,
Steve
------------------------------
Steve Linn
Senior Consulting I/T Specialist
IBM
------------------------------
Original Message:
Sent: Tue April 11, 2023 06:01 AM
From: Jeroen Willems
Subject: uncaught-error "AssemblyRateLimitError"
Hi,
I didn't test it myself yet, but just to be sure you are using API Gateway and not V5C?
If V5C check e.g. https://www.ibm.com/support/pages/capture-429-error-when-rate-limit-exceeds-plan-ibm-api-connect
------------------------------
Jeroen Willems
Integration Architect - Managing Partner
Integration Designers
Original Message:
Sent: Mon April 10, 2023 07:55 PM
From: Oscar Gonzalez
Subject: uncaught-error "AssemblyRateLimitError"
Hi team.
Error cases supported by assembly catches
Ibm | remove preview |
| Error cases supported by assembly catches | Several error cases that can be returned by the assembly are available to the catch function. | View this on Ibm > |
|
|
Hi team.
I'm trying to capture the error that occurs when the API call limit is reached.
In the documentation it appears that with API Gateway I can capture the events with the catch AssemblyRateLimitError
but it doesn't work, I always get the API Connect error and I need to have a custom error.
I need all of your help
Always the error is
{"httpCode":"429","httpMessage":"Too Many Requests","moreInformation":"Assembly Rate Limit exceeded"}
------------------------------
Oscar Gonzalez
------------------------------