{"record":{"id":"2c76eb000fc46e1e","repo":"vercel/ai","slug":"sse-response-body-is-empty","errorCode":null,"errorMessage":"SSE response body is empty","messagePattern":"SSE response body is empty","errorType":"http","errorClass":"APICallError","httpStatus":null,"severity":"error","filePath":"packages/gateway/src/gateway-video-model.ts","lineNumber":82,"sourceCode":"        headers: combineHeaders(\n          resolvedHeaders,\n          headers ?? {},\n          this.getModelConfigHeaders(),\n          await resolve(this.config.o11yHeaders),\n          { accept: 'text/event-stream' },\n        ),\n        body: this.buildRequestBody(options),\n        successfulResponseHandler: async ({\n          response,\n          url,\n          requestBodyValues,\n        }: {\n          url: string;\n          requestBodyValues: unknown;\n          response: Response;\n        }) => {\n          if (response.body == null) {\n            throw new APICallError({\n              message: 'SSE response body is empty',\n              url,\n              requestBodyValues,\n              statusCode: response.status,\n            });\n          }\n\n          const eventStream = parseJsonEventStream({\n            stream: response.body,\n            schema: gatewayVideoEventSchema,\n          });\n\n          const reader = eventStream.getReader();\n          const { done, value: parseResult } = await reader.read();\n          reader.releaseLock();\n\n          if (done || !parseResult) {\n            throw new APICallError({","sourceCodeStart":64,"sourceCodeEnd":100,"githubUrl":"https://github.com/vercel/ai/blob/69428b1f8b037e4d118fb4853428d5c4e620493c/packages/gateway/src/gateway-video-model.ts#L64-L100","documentation":"Error \"SSE response body is empty\" thrown in vercel/ai.","triggerScenarios":"Thrown at packages/gateway/src/gateway-video-model.ts:82 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":"69428b1f8b037e4d118fb4853428d5c4e620493c","analyzedAt":"2026-08-30T12:32:21.016Z","schemaVersion":2},"datasetVersion":"2026-08-30T13:17:10.514Z"}