Skip to content

The agent that grows with you

docs(providers): seed_pool_credentials overriding replaces generic env seeding

Teknium7bea53246bf4
diff --git a/providers/base.py b/providers/base.py
index 35a6bff97af..105b614cde3 100644
--- a/providers/base.py
+++ b/providers/base.py
@@ -636,7 +636,9 @@ class ProviderProfile:
def seed_pool_credentials(self, *, is_suppressed: Callable[[str], bool],
explicitly_configured: Callable[[], bool]) -> list[dict] | None:
- """Pool rows ``{source, access_token, base_url, label}`` this provider seeds itself; None = generic env seeding."""
+ """Pool rows ``{source, access_token, base_url, label}`` this provider seeds itself. Overriding it
+ replaces generic env seeding (that loop would overwrite exchanged tokens with the raw env value),
+ so an override returns ``[]`` for none; only the base implementation keeps generic env seeding."""
return None
def remove_credential_source(self, source: str) -> tuple[tuple[str, ...], tuple[str, ...]] | None:
diff --git a/website/docs/developer-guide/model-provider-plugin.md b/website/docs/developer-guide/model-provider-plugin.md
index adcca23fb8b..cb15ebd96d5 100644
--- a/website/docs/developer-guide/model-provider-plugin.md
+++ b/website/docs/developer-guide/model-provider-plugin.md
@@ -302,7 +302,7 @@ meaning says otherwise.
| `resolve_api_key_secret()` | Provider-owned `(runtime_api_key, source)` | `None` (env/pool ladder) |
| `runtime_base_url()` | Base URL derived from the credential | `None` (env or default) |
| `prepare_pool_entry()` | Turns the selected pool row's secret into the runtime key | the secret as-is |
-| `seed_pool_credentials()` | Pool rows `{source, access_token, base_url, label}` the provider seeds itself | `None` (generic env seeding) |
+| `seed_pool_credentials()` | Pool rows `{source, access_token, base_url, label}` the provider seeds itself; overriding it replaces generic env seeding (return `[]` for none) | not overridden = generic env seeding |
| `remove_credential_source()` | `hermes auth remove`: `(sources_to_suppress, hints)` | `None` (generic removal) |
| `refresh_runtime_credentials()` | Re-mints `(api_key, base_url)` on `unauthorized` \| `stale` \| `auxiliary_unauthorized`; error path only | `None` |
| `is_stale_credential_error()` | A non-auth error really means the credential went stale (pure) | `False` |