{"record":{"id":"000aa145c20f5405","repo":"deepseek-ai/deepseek-harness","slug":"web-provider-credential-missing","errorCode":"WEB_PROVIDER_CREDENTIAL_MISSING","errorMessage":"DeepSeek search has no API key for \"${ref}\"; store it through the credentials service (the web Models page writes it), export it in the launching environment, or set a literal \"apiKey\" in the web-search-deepseek config","messagePattern":"DeepSeek search has no API key for \"(.+?)\"; store it through the credentials service \\(the web Models page writes it\\), export it in the launching environment, or set a literal \"apiKey\" in the web-search-deepseek config","errorType":"exception","errorClass":"WebError","httpStatus":null,"severity":"error","filePath":"packages/web/web-search-deepseek/src/provider.ts","lineNumber":294,"sourceCode":"   * @returns the resolved key.\n   */\n  private async apiKey(options: DeepSeekSearchProviderOptions, signal?: AbortSignal): Promise<string> {\n    throwIfSearchAborted(signal)\n    if (options.apiKey !== undefined && options.apiKey.length > 0) return options.apiKey\n    let resolved: string | undefined\n    try {\n      resolved = await abortable(options.resolveApiKey?.() ?? Promise.resolve(undefined), signal)\n    } catch (error: unknown) {\n      if (signal?.aborted === true || isAbortError(error)) throw searchAborted(signal, error)\n      throw new WebError(\n        `DeepSeek search credential resolution failed: ${String(error)}`,\n        'WEB_PROVIDER_ERROR',\n        { cause: error },\n      )\n    }\n    if (resolved !== undefined && resolved.length > 0) return resolved\n    const ref = options.apiKeyEnv ?? 'DEEPSEEK_API_KEY'\n    throw new WebError(\n      `DeepSeek search has no API key for \"${ref}\"; store it through the credentials service`\n      + ' (the web Models page writes it), export it in the launching environment, or set a literal'\n      + ' \"apiKey\" in the web-search-deepseek config',\n      'WEB_PROVIDER_CREDENTIAL_MISSING',\n    )\n  }\n}\n\n/**\n * Race a same-process asynchronous preflight against caller cancellation. The\n * attached settlement handlers keep observing an uncooperative operation after\n * abort so a later rejection cannot become unhandled.\n */\nfunction abortable<T>(operation: Promise<T>, signal?: AbortSignal): Promise<T> {\n  if (signal === undefined) return operation\n  if (signal.aborted) return Promise.reject(searchAborted(signal))\n  return new Promise<T>((resolve, reject) => {\n    const onAbort = (): void => { reject(searchAborted(signal)) }","sourceCodeStart":276,"sourceCodeEnd":312,"githubUrl":"https://github.com/deepseek-ai/deepseek-harness/blob/b150a551b8d465e31e418e1b2eaf5e79bbb7d28e/packages/web/web-search-deepseek/src/provider.ts#L276-L312","documentation":"Error \"DeepSeek search has no API key for \"${ref}\"; store it through the credentials service (the web Models page writes it), export it in the launching environment, or set a literal \"apiKey\" in the web-search-deepseek config\" thrown in deepseek-ai/deepseek-harness.","triggerScenarios":"Thrown at packages/web/web-search-deepseek/src/provider.ts:294 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Store the DeepSeek API key through the credentials service, export it in the launching environment, or set apiKey in the web-search-deepseek config."],"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"}