{"record":{"id":"05e1d3115cf4d69c","repo":"diegosouzapw/OmniRoute","slug":"provider-returned-no-recognizable-image-payload","errorCode":null,"errorMessage":"Provider returned no recognizable image payload: ${JSON.stringify(payload).slice(0, 240)}","messagePattern":"Provider returned no recognizable image payload: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"open-sse/handlers/imageGeneration.ts","lineNumber":2438,"sourceCode":"    for (const item of payload.images) pushCandidate(item);\n  }\n\n  if (payload?.image) pushCandidate({ b64_json: payload.image });\n  if (payload?.url) pushCandidate({ url: payload.url });\n  if (payload?.sample) pushCandidate({ url: payload.sample });\n  if (payload?.result?.sample) pushCandidate({ url: payload.result.sample });\n  if (Array.isArray(payload?.result?.images)) {\n    for (const item of payload.result.images) pushCandidate(item);\n  }\n\n  const normalized = [];\n  for (const candidate of candidates) {\n    const item = await normalizeProviderImageCandidate(candidate, body, defaultFormat);\n    if (item) normalized.push(item);\n  }\n\n  if (normalized.length === 0 && log) {\n    log.warn(\n      \"IMAGE\",\n      `Provider returned no recognizable image payload: ${JSON.stringify(payload).slice(0, 240)}`\n    );\n  }\n\n  return normalized;\n}\n\nasync function normalizeProviderImageCandidate(candidate, body, defaultFormat) {\n  const wantsBase64 = body?.response_format === \"b64_json\" || defaultFormat === \"b64_json\";\n  let url = null;\n  let b64 = null;\n\n  if (typeof candidate === \"string\") {\n    const dataUriMatch = /^data:[^;]+;base64,(.+)$/i.exec(candidate);\n    if (dataUriMatch) {\n      b64 = dataUriMatch[1];\n    } else if (isHttpUrl(candidate)) {","sourceCodeStart":2420,"sourceCodeEnd":2456,"githubUrl":"https://github.com/diegosouzapw/OmniRoute/blob/a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d/open-sse/handlers/imageGeneration.ts#L2420-L2456","documentation":"Error \"Provider returned no recognizable image payload: ${JSON.stringify(payload).slice(0, 240)}\" thrown in diegosouzapw/OmniRoute.","triggerScenarios":"Thrown at open-sse/handlers/imageGeneration.ts:2438 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d","analyzedAt":"2026-08-25T18:35:09.898Z","schemaVersion":2},"datasetVersion":"2026-08-25T21:54:21.419Z"}