ChatGPTClaudeGrok / X / CursorGemini

DeepSeek Harness search key also used by chat: same ref

TroubleshootingPublished 2026-10-30Author: DeepSeek Plugin Market
DeepSeek HarnessDSHweb_searchcredentialsDEEPSEEK_API_KEYconfiguration
A key entered on the DeepSeek Harness search page is also used by chat: search stores only a credential reference name, which defaults to DEEPSEEK_API_KEY.

"I entered a key on the search page, and later chat spending also went through that key" — this is neither an illusion nor search counting chat tokens; both places default to the same credential reference name. The search plugin stores no key at all, it writes only a name into the credential domain, and the model route reads that same name by default (#11174). Think of "name" and "value" separately and the relationship becomes obvious.

DeepSeek Harness: Layer 1: what "entering a key on the search page" actually writes

It writes a credential entry reference name, not a search plugin configuration item.

  1. The submit action calls credentials.set(this.ref(), value), writing the value into the credential domain.
  2. this.ref() is the reference name, defaulting to DEEPSEEK_API_KEY.
  3. In the search plugin's schema, the default reference name is the same string.
  4. So "entering a key" is really "assigning a value to this name".
  5. The search plugin side stores only "which name I use", never the secret itself.

DSH plugin: Layer 2: three defaults add up to the same name

The search page, the search plugin, and the API-key model route share the same default reference name, so by default they naturally share one key.

  1. Search settings page: default reference DEEPSEEK_API_KEY.
  2. Search plugin schema: the same default.
  3. DeepSeek API-key model connection: also resolves this name by default.
  4. All three defaults point at one credential entry, and whoever writes it takes effect.
  5. So the key you entered on the search page is what the model route reads.

DeepSeek Harness: Layer 3: why it shows up as "chat using this key"

On an API-key route, the model request carries exactly this credential; search did not forward it, they were the same entry all along.

  1. Before a session calls the model, the adapter fetches the secret by reference name.
  2. What it gets is the entry you just filled in.
  3. So the chat call naturally uses this key.
  4. This has nothing to do with search results or search billing.
  5. The deciding factor is "the provider is an API-key route", not "search is enabled".

DSH Plugin: Layer 4: when this explanation fails

If the session uses the account-login route, the model does not read this reference name and the symptom needs another cause.

  1. Open that session's request/header and read the provider.
  2. If it is account login (deepseek-account), the model does not use an API key.
  3. Then "shared key" does not apply, and you should check account quota or other configuration.
  4. Likewise, changing the reference name only matters on API-key routes.
  5. Confirming this one point saves half of the useless investigation.

DeepSeek Harness: Where the defaults collide

Put the three defaults side by side and the collision is obvious.

LocationDefault referenceRole
Search settings pageDEEPSEEK_API_KEYwrites the value into credential storage
Search plugin schemaDEEPSEEK_API_KEYreads the same name
API-key model connectionDEEPSEEK_API_KEYmodel requests read it too

All three rows point at one name, so "fill it once, both sides take effect" is default behavior rather than an accident.

DSH plugin: Three common misconceptions

Remove these three and misdiagnosis mostly stops.

  1. "Search counted the chat tokens" — no. Search only references the secret and takes no part in chat metering.
  2. "The key is stored in the search plugin" — no. The key lives in the credential domain; the plugin remembers only the reference name.
  3. "Changing the search address separates them" — no. Address and credential are different dimensions, and DEEPSEEK_SEARCH_BASE_URL only controls where requests land.

How to separate them

Giving search its own reference name is the smallest reversible change.

  1. Open search settings and change the credential reference from DEEPSEEK_API_KEY to DEEPSEEK_SEARCH_API_KEY.
  2. Enter the search key under that new name.
  3. Confirm the model route still uses DEEPSEEK_API_KEY with its value unchanged.
  4. Send a message that triggers search and confirm search works.
  5. Send an ordinary chat message and confirm the model still uses the original key.
  6. If search has its own service address, set it with DEEPSEEK_SEARCH_BASE_URL separately, not mixed with the chat baseURL.

Cautions

Name and value are separate decisions; only the name is shared.

  1. Do not read "shared" as "search bills the chat". They are simply one key.
  2. Change the reference name in both places. Renaming without entering a key under the new name breaks search.
  3. This explanation does not apply to account-login routes. Check the provider first.
  4. Search address and chat address are two variables. Mixing them leads you to misdiagnose it as a credential issue.
  5. Verify both directions after the change. Search must run, and chat must use the original key.

On UI shortcuts such as "cmd+R force refresh", the community reply gives no built-in implementation; file a separate request and do not fold it into this credential issue.

One last reminder: if after renaming the reference, search someday starts using the chat key again, first check whether a reinstall or reset restored the default name.

If you do not actually need them separated, keeping the default is simpler — one key for both places, one less configuration.See DSH plugin web_search ignores your gateway: fix baseURL for the related case.

ChatGPTClaudeGrok / X / CursorGemini

FAQ

Why does chat also use the key entered on the DeepSeek Harness search settings page?

Chat also uses that key because both share the same credential reference name in DeepSeek Harness. The search page only calls credentials.set(reference, value) with a default reference of DEEPSEEK_API_KEY, and the API-key model route resolves the same name by default, so entering it overwrites what the model reads.

Does the DeepSeek Harness search plugin store the key itself?

No, the search plugin stores no key in DeepSeek Harness; it references a name in the credential domain, and the credential service handles actual storage. Understanding that is what makes changing the reference name meaningful.

How do I make DeepSeek Harness use different keys for search and chat?

To separate the keys in DeepSeek Harness, change the credential reference in search settings to another name, such as DEEPSEEK_SEARCH_API_KEY, and enter the search key under that new name. The model route keeps reading DEEPSEEK_API_KEY, so the two no longer interfere.

Are the search address and the chat address the same DeepSeek Harness configuration?

No, they are separate: in DeepSeek Harness search has its own endpoint variable, DEEPSEEK_SEARCH_BASE_URL, independent of the chat route's baseURL, and the two can point at different services.

When does the shared-key explanation not apply in DeepSeek Harness?

The shared-key explanation does not apply when a DeepSeek Harness session uses the account-login route (deepseek-account), because the model does not read DEEPSEEK_API_KEY at all and the symptom needs another cause. Check the provider in that session's request/header.

Related Terms

credential reference name
A credential reference name is a pointer to an entry in credential storage, and plugins and model routes use it to fetch a secret. When several features use the same reference name, they share the same key.— https://github.com/deepseek-ai/deepseek-harness/discussions/11174
DEEPSEEK_API_KEY
DEEPSEEK_API_KEY is the default credential reference name for DeepSeek-related features. It is the default in both the search settings page and API-key model routes, so by default both share one key.— https://github.com/deepseek-ai/deepseek-harness/discussions/11174
DEEPSEEK_SEARCH_BASE_URL
DEEPSEEK_SEARCH_BASE_URL is the search feature's independent service address variable, configured separately from the chat route's baseURL. It affects only where search requests land, not model calls.— https://github.com/deepseek-ai/deepseek-harness/discussions/11174
credentials.set
The write interface is `credentials.set`, which stores a value under a reference name in the credential domain. The search settings page calls it on submit, so the write goes to credential storage rather than inside the search plugin.— https://github.com/deepseek-ai/deepseek-harness/discussions/11174

Sources