{"record":{"id":"eef07f1cdfcf735a","repo":"FlowiseAI/Flowise","slug":"http-error-res-status-res-statustext-eef07f","errorCode":null,"errorMessage":"HTTP Error ${res.status}: ${res.statusText}","messagePattern":"HTTP Error (.+?): (.+?)","errorType":"http","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/components/nodes/tools/RequestsGet/core.ts","lineNumber":175,"sourceCode":"            } catch (error) {\n                console.warn('Failed to process queryParamsSchema:', error)\n            }\n        } else if (params.queryParams && Object.keys(params.queryParams).length > 0) {\n            // Fallback: treat all parameters as query parameters if no schema is defined\n            const url = new URL(finalUrl)\n            Object.entries(params.queryParams).forEach(([key, value]) => {\n                url.searchParams.append(key, String(value))\n            })\n            finalUrl = url.toString()\n        }\n\n        try {\n            const res = await secureFetch(finalUrl, {\n                headers: requestHeaders\n            })\n\n            if (!res.ok) {\n                throw new Error(`HTTP Error ${res.status}: ${res.statusText}`)\n            }\n\n            const text = await res.text()\n            return text.slice(0, this.maxOutputLength)\n        } catch (error) {\n            throw new Error(`Failed to make GET request: ${error instanceof Error ? error.message : 'Unknown error'}`)\n        }\n    }\n}\n","sourceCodeStart":157,"sourceCodeEnd":185,"githubUrl":"https://github.com/FlowiseAI/Flowise/blob/abe4a8601a058047b350c260676826e21dd14101/packages/components/nodes/tools/RequestsGet/core.ts#L157-L185","documentation":"Thrown inside the try block of _call when the response from secureFetch is not ok (status outside 200-299). It surfaces the raw HTTP status code and status text. Note: in the shipped code this throw is always caught by the surrounding catch (error 482) and re-wrapped, so the message appears as 'Failed to make GET request: HTTP Error <status>: <text>'.","triggerScenarios":"Target server returns any 4xx or 5xx status; endpoint moved (404); auth required (401/403); upstream gateway error (502/503/504); rate limited (429).","commonSituations":"Wrong base URL or path; missing/incorrect Authorization header; the API requires an API key not supplied via requestHeaders; transient server outage or maintenance window; rate-limit policy hit.","solutions":["Log the full wrapped message to recover the real status code, then fix the underlying cause (URL, auth, payload).","For 401/403, supply correct credentials/headers via the tool's `headers` field.","For 429 or 5xx, retry with exponential backoff from the caller.","For 404, verify the endpoint path and that the resource exists."],"exampleFix":"// before\nconst res = await secureFetch(finalUrl, { headers: requestHeaders })\nif (!res.ok) throw new Error(`HTTP Error ${res.status}: ${res.statusText}`)\n\n// after (surface body for diagnostics before throwing)\nconst res = await secureFetch(finalUrl, { headers: requestHeaders })\nif (!res.ok) {\n  const body = await res.text().catch(() => '')\n  throw new Error(`HTTP ${res.status} ${res.statusText}: ${body.slice(0, 500)}`)\n}","handlingStrategy":"retry","validationCode":"async function safeGet(tool: any, maxRetries = 3) {\n  for (let attempt = 0; attempt <= maxRetries; attempt++) {\n    try {\n      return await tool._call({})\n    } catch (e) {\n      const msg = (e as Error).message\n      const m = msg.match(/HTTP Error (\\d{3})/)\n      const code = m ? Number(m[1]) : 0\n      const transient = code === 429 || (code >= 500 && code < 600)\n      if (!transient || attempt === maxRetries) throw e\n      await new Promise((r) => setTimeout(r, 2 ** attempt * 500))\n    }\n  }\n}","typeGuard":"const isTransientHttpError = (e: unknown): boolean => {\n  const m = (e instanceof Error ? e.message : String(e)).match(/HTTP Error (\\d{3})/)\n  if (!m) return false\n  const c = Number(m[1])\n  return c === 429 || (c >= 500 && c < 600)\n}","tryCatchPattern":"try { return await tool._call({}) }\ncatch (e) {\n  const code = ((e as Error).message.match(/HTTP Error (\\d{3})/) || [])[1]\n  if (code === '401' || code === '403') throw new Error('Auth required for GET target')\n  if (code === '404') throw new Error('GET target not found')\n  throw e\n}","preventionTips":["Validate the URL and required auth headers before the first call.","Treat 429/5xx as retryable; 4xx (except 429) as permanent.","Log the unwrapped status code so retries are driven by the real signal."],"tags":["http","network","server-error","status-code"],"backgroundTag":null,"analyzedSha":"abe4a8601a058047b350c260676826e21dd14101","analyzedAt":"2026-08-12T16:04:40.823Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}