{"record":{"id":"9f05f52ba78b2e39","repo":"diegosouzapw/OmniRoute","slug":"cursor-availablemodels-returned-no-models","errorCode":null,"errorMessage":"Cursor AvailableModels returned no models","messagePattern":"Cursor AvailableModels returned no models","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/lib/providerModels/cursorAvailableModels.ts","lineNumber":185,"sourceCode":"\n  if (!response.ok) {\n    const text = await response.text().catch(() => \"\");\n    throw new Error(\n      `Cursor AvailableModels failed: ${response.status}${text ? ` ${text.slice(0, 200)}` : \"\"}`\n    );\n  }\n\n  const contentType = response.headers.get(\"content-type\") || \"\";\n  if (contentType.includes(\"proto\") || contentType.includes(\"protobuf\")) {\n    throw new Error(\n      \"Cursor AvailableModels returned protobuf; JSON catalog unavailable for this client version\"\n    );\n  }\n\n  const payload = await response.json();\n  const models = normalizeCursorAvailableModelsPayload(payload);\n  if (models.length === 0) {\n    throw new Error(\"Cursor AvailableModels returned no models\");\n  }\n  return models;\n}\n","sourceCodeStart":167,"sourceCodeEnd":189,"githubUrl":"https://github.com/diegosouzapw/OmniRoute/blob/a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d/src/lib/providerModels/cursorAvailableModels.ts#L167-L189","documentation":"The AvailableModels response was OK and JSON, but normalizeCursorAvailableModelsPayload produced an empty model list — Cursor returned no usable entries (account without model access or an API shape change).","triggerScenarios":"Thrown at src/lib/providerModels/cursorAvailableModels.ts:185 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the Cursor account actually has model access enabled","Retry — an empty catalog can be transient on the Cursor side","Inspect the raw payload against normalizeCursorAvailableModelsPayload if Cursor changed its API shape"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"a179ffed5bb2e0b883b9ae7214ce8717b2a94c4d","analyzedAt":"2026-08-25T18:35:09.898Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}