fix(HTTP Request Node): Add suggestion how to fix '429 - too many requests' errors (#7293)

Github issue / Community forum post (link here to close automatically):
This commit is contained in:
Marcus
2023-09-28 16:00:45 +02:00
committed by GitHub
parent 8bc369dd40
commit 0bc33b1cc2
3 changed files with 7 additions and 9 deletions

View File

@@ -1431,6 +1431,10 @@ export class HttpRequestV3 implements INodeType {
for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
response = promisesResponses.shift();
if (response!.status !== 'fulfilled') {
if (response.reason.statusCode === 429) {
response.reason.message =
"Try spacing your requests out using the batching settings under 'Options'";
}
if (!this.continueOnFail()) {
if (autoDetectResponseFormat && response.reason.error instanceof Buffer) {
response.reason.error = Buffer.from(response.reason.error as Buffer).toString();