{"record":{"id":"750718daa22f071a","repo":"deepseek-ai/deepseek-harness","slug":"forbidden","errorCode":null,"errorMessage":"forbidden","messagePattern":"forbidden","errorType":"http","errorClass":null,"httpStatus":403,"severity":"error","filePath":"packages/client/connection/src/index.ts","lineNumber":166,"sourceCode":"        return new Response('forbidden', { status: 403 })\n      }\n      if (request.method === 'GET' && (pathname === MUX_EVENTS_PATH || pathname === HOST_EVENTS_PATH)) {\n        return new Response('upgrade required', {\n          status: 426,\n          headers: { connection: 'Upgrade', upgrade: 'websocket' },\n        })\n      }\n      const apiProxy = ctx.get('apiProxy')\n      if (apiProxy === undefined) return new Response('not found', { status: 404 })\n      return toFetchHandler(apiProxy).fetch(request)\n    },\n  })\n  const route: WebRoute = {\n    kind: 'prefix',\n    path: API_PATH,\n    handler: async (req, res) => {\n      if (!isTrustedApiRequest(req, trustedHosts)) {\n        res.writeHead(403)\n        res.end('forbidden')\n        return\n      }\n      await bridge(req, res, fetchHandler, maxRequestBodyBytes)\n    },\n  }\n  ctx.effect(() => ctx.webServer.register(route), 'client-connection: /api route')\n  ctx.inject(['apiProxy'], (apiCtx) => {\n    assertImageBodyCapacity(apiCtx, maxRequestBodyBytes)\n    const downlinks = new WebSocketDownlinks(apiCtx.apiProxy)\n    const registerDownlink = (\n      path: string,\n      handle: WebUpgradeRoute['handler'],\n    ): void => {\n      apiCtx.effect(() => apiCtx.webServer.registerUpgrade({\n        path,\n        handler: (req, socket, head) => {\n          if (!isTrustedApiRequest(req, trustedHosts)) {","sourceCodeStart":148,"sourceCodeEnd":184,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/client/connection/src/index.ts#L148-L184","documentation":"Error \"forbidden\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/client/connection/src/index.ts:166 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Authenticate with a valid token/credential and ensure the principal has permission for the requested operation."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b150a551b8d465e31e418e1b2eaf5e79bbb7d28e","analyzedAt":"2026-08-24T18:12:29.105Z","schemaVersion":2},"datasetVersion":"2026-08-24T22:17:12.610Z"}