mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 09:00:42 +00:00
37 lines
1.1 KiB
TypeScript
37 lines
1.1 KiB
TypeScript
import type { ModelProviderConfig } from "../config/types.js";
|
|
import type { OpenClawConfig } from "../config/types.openclaw.js";
|
|
|
|
/**
|
|
* Provider-owned config normalization for `models.providers.<id>` entries.
|
|
*
|
|
* Use this for provider-specific config cleanup that should stay with the
|
|
* plugin rather than in core config-policy tables.
|
|
*/
|
|
export type ProviderNormalizeConfigContext = {
|
|
provider: string;
|
|
providerConfig: ModelProviderConfig;
|
|
};
|
|
|
|
/**
|
|
* Provider-owned env/config auth marker resolution for `models.providers`.
|
|
*
|
|
* Use this when a provider resolves auth from env vars that do not follow the
|
|
* generic API-key conventions.
|
|
*/
|
|
export type ProviderResolveConfigApiKeyContext = {
|
|
provider: string;
|
|
env: NodeJS.ProcessEnv;
|
|
};
|
|
|
|
/**
|
|
* Provider-owned config-default application input.
|
|
*
|
|
* Use this when a provider needs to add global config defaults that depend on
|
|
* provider auth mode or provider-specific model families.
|
|
*/
|
|
export type ProviderApplyConfigDefaultsContext = {
|
|
provider: string;
|
|
config: OpenClawConfig;
|
|
env: NodeJS.ProcessEnv;
|
|
};
|