refactor: narrow provider runtime auth seams

This commit is contained in:
Peter Steinberger
2026-03-28 02:02:41 +00:00
parent a0f48f099e
commit e8866fc738
18 changed files with 132 additions and 100 deletions

View File

@@ -1,6 +1,9 @@
import { ensureAuthProfileStore, listProfilesForProvider } from "openclaw/plugin-sdk/agent-runtime";
import { definePluginEntry, type ProviderAuthContext } from "openclaw/plugin-sdk/plugin-entry";
import { coerceSecretRef } from "openclaw/plugin-sdk/provider-auth";
import {
coerceSecretRef,
ensureAuthProfileStore,
listProfilesForProvider,
} from "openclaw/plugin-sdk/provider-auth";
import { githubCopilotLoginCommand } from "openclaw/plugin-sdk/provider-auth-login";
import { PROVIDER_ID, resolveCopilotForwardCompatModel } from "./models.js";
import { DEFAULT_COPILOT_API_BASE_URL, resolveCopilotApiToken } from "./token.js";

View File

@@ -1,8 +1,11 @@
import { intro, note, outro, spinner } from "@clack/prompts";
import { ensureAuthProfileStore, upsertAuthProfile } from "openclaw/plugin-sdk/agent-runtime";
import { stylePromptTitle } from "openclaw/plugin-sdk/cli-runtime";
import { logConfigUpdated, updateConfig } from "openclaw/plugin-sdk/config-runtime";
import { applyAuthProfileConfig } from "openclaw/plugin-sdk/provider-auth";
import {
applyAuthProfileConfig,
ensureAuthProfileStore,
upsertAuthProfile,
} from "openclaw/plugin-sdk/provider-auth";
import type { RuntimeEnv } from "openclaw/plugin-sdk/runtime";
const CLIENT_ID = "Iv1.b507a08c87ecfe98";