FlowiseAI/Flowise · error · Error
HTTP Error ${res.status}: ${res.statusText}
Error message
HTTP Error ${res.status}: ${res.statusText} What it means
Thrown inside RequestsPut_Core._call's try block when secureFetch returns a non-ok response. Reports status code and status text. As with 481/484, this is always re-caught by the outer catch (488) and observed as 'Failed to make PUT request: HTTP Error <status>: <text>'.
Source
Thrown at packages/components/nodes/tools/RequestsPut/core.ts:137
...inputBody,
...params.body
}
}
const requestHeaders = {
'Content-Type': 'application/json',
...(params.headers || {}),
...this.headers
}
const res = await secureFetch(inputUrl, {
method: 'PUT',
headers: requestHeaders,
body: JSON.stringify(inputBody)
})
if (!res.ok) {
throw new Error(`HTTP Error ${res.status}: ${res.statusText}`)
}
const text = await res.text()
return text.slice(0, this.maxOutputLength)
} catch (error) {
throw new Error(`Failed to make PUT request: ${error instanceof Error ? error.message : 'Unknown error'}`)
}
}
}
View on GitHub (pinned to abe4a8601a)
Solutions
- Recover the status code from the wrapped message suffix and act on it.
- For 404, confirm the resource URL is correct before retrying.
- For 401/403, supply correct credentials in `headers`.
- For 409, re-fetch and reconcile state before retrying.
Example fix
// before
if (!res.ok) throw new Error(`HTTP Error ${res.status}: ${res.statusText}`)
// after (include body for diagnosis)
if (!res.ok) {
const detail = await res.text().catch(() => '')
throw new Error(`PUT ${inputUrl} failed: ${res.status} ${res.statusText} — ${detail.slice(0, 500)}`)
} Defensive patterns
Strategy: retry
Validate before calling
async function safePut(tool: any, arg: any, maxRetries = 3) {
for (let attempt = 0; attempt <= maxRetries; attempt++) {
try { return await tool._call(arg) }
catch (e) {
const m = (e as Error).message.match(/HTTP Error (\d{3})/)
const code = m ? Number(m[1]) : 0
const transient = code === 409 || code === 429 || (code >= 500 && code < 600)
if (!transient || attempt === maxRetries) throw e
await new Promise((r) => setTimeout(r, 2 ** attempt * 500))
}
}
} Type guard
const isPutConflict = (e: unknown): boolean => /HTTP Error 409/.test(e instanceof Error ? e.message : String(e))
Try / catch
try { return await tool._call(arg) }
catch (e) {
const code = ((e as Error).message.match(/HTTP Error (\d{3})/) || [])[1]
if (code === '404') throw new Error('PUT target does not exist — verify resource URL')
if (code === '405') throw new Error('Endpoint does not accept PUT')
if (code === '409') { await refetchAndMerge(); return await tool._call(arg) }
throw e
} Prevention
- Confirm the resource exists (GET) before PUT to avoid 404 loops.
- Handle 409 conflicts by re-fetching state before retrying.
- PUT is idempotent; safe to retry on 5xx.
When it happens
Trigger: Server rejects the PUT: 400 bad body, 401/403 auth, 404 resource missing, 405 method not allowed, 409 conflict, 413 payload too large, 5xx fault.
Common situations: PUT to a non-existent resource (404); idempotency/version conflict (409); missing auth; payload exceeds server limits; endpoint does not accept PUT.
Related errors
- HTTP Error ${res.status}: ${res.statusText}
- HTTP Error ${res.status}: ${res.statusText}
- HTTP Error ${res.status}: ${res.statusText}
- Failed to make PUT request: ${error instanceof Error ? error
- ${errorMessage}
AI-assisted analysis of FlowiseAI/Flowise@abe4a8601a (2026-08-12).
Data as JSON: /api/errors/078a21a0bc2ff23a.
Report an issue: GitHub.