Technical reference
SecretRef 認証情報サーフェス
このページでは、正準の SecretRef 認証情報サーフェスを定義します。
スコープの意図:
- スコープ内: OpenClaw が発行またはローテーションしない、厳密にユーザー指定の認証情報。
- スコープ外: 実行時に発行される、またはローテーションされる認証情報、OAuth リフレッシュ用素材、およびセッション類似のアーティファクト。
サポートされる認証情報
openclaw.json ターゲット (secrets configure + secrets apply + secrets audit)
models.providers.*.apiKeymodels.providers.*.headers.*models.providers.*.request.auth.tokenmodels.providers.*.request.auth.valuemodels.providers.*.request.headers.*models.providers.*.request.proxy.tls.camodels.providers.*.request.proxy.tls.certmodels.providers.*.request.proxy.tls.keymodels.providers.*.request.proxy.tls.passphrasemodels.providers.*.request.tls.camodels.providers.*.request.tls.certmodels.providers.*.request.tls.keymodels.providers.*.request.tls.passphraseskills.entries.*.apiKeyagents.defaults.memorySearch.remote.apiKeyagents.list[].tts.providers.*.apiKeyagents.list[].memorySearch.remote.apiKeytalk.providers.*.apiKeytalk.realtime.providers.*.apiKeymessages.tts.providers.*.apiKeytools.web.fetch.firecrawl.apiKeyplugins.entries.acpx.config.mcpServers.*.env.*plugins.entries.brave.config.webSearch.apiKeyplugins.entries.codex.config.appServer.authTokenplugins.entries.codex.config.appServer.headers.*plugins.entries.exa.config.webSearch.apiKeyplugins.entries.google-meet.config.realtime.providers.*.apiKeyplugins.entries.google.config.webSearch.apiKeyplugins.entries.xai.config.webSearch.apiKeyplugins.entries.moonshot.config.webSearch.apiKeyplugins.entries.perplexity.config.webSearch.apiKeyplugins.entries.firecrawl.config.webSearch.apiKeyplugins.entries.minimax.config.webSearch.apiKeyplugins.entries.tavily.config.webSearch.apiKeyplugins.entries.parallel.config.webSearch.apiKeyplugins.entries.voice-call.config.realtime.providers.*.apiKeyplugins.entries.voice-call.config.streaming.providers.*.apiKeyplugins.entries.voice-call.config.tts.providers.*.apiKeyplugins.entries.voice-call.config.twilio.authTokentools.web.search.*.apiKeytools.web.search.apiKeygateway.auth.passwordgateway.auth.tokengateway.remote.tokengateway.remote.passwordcron.webhookTokenchannels.telegram.botTokenchannels.telegram.webhookSecretchannels.telegram.accounts.*.botTokenchannels.telegram.accounts.*.webhookSecretchannels.slack.botTokenchannels.slack.appTokenchannels.slack.relay.authTokenchannels.slack.userTokenchannels.slack.signingSecretchannels.slack.accounts.*.botTokenchannels.slack.accounts.*.appTokenchannels.slack.accounts.*.relay.authTokenchannels.slack.accounts.*.userTokenchannels.slack.accounts.*.signingSecretchannels.sms.authTokenchannels.sms.accounts.*.authTokenchannels.discord.tokenchannels.discord.pluralkit.tokenchannels.discord.voice.tts.providers.*.apiKeychannels.discord.accounts.*.tokenchannels.discord.accounts.*.pluralkit.tokenchannels.discord.accounts.*.voice.tts.providers.*.apiKeychannels.irc.passwordchannels.irc.nickserv.passwordchannels.irc.accounts.*.passwordchannels.irc.accounts.*.nickserv.passwordchannels.feishu.appSecretchannels.feishu.encryptKeychannels.feishu.verificationTokenchannels.feishu.accounts.*.appSecretchannels.feishu.accounts.*.encryptKeychannels.feishu.accounts.*.verificationTokenchannels.qqbot.clientSecretchannels.qqbot.accounts.*.clientSecretchannels.msteams.appPasswordchannels.mattermost.botTokenchannels.mattermost.accounts.*.botTokenchannels.matrix.accessTokenchannels.matrix.passwordchannels.matrix.accounts.*.accessTokenchannels.matrix.accounts.*.passwordchannels.nextcloud-talk.botSecretchannels.nextcloud-talk.apiPasswordchannels.nextcloud-talk.accounts.*.botSecretchannels.nextcloud-talk.accounts.*.apiPasswordchannels.zalo.botTokenchannels.zalo.webhookSecretchannels.zalo.accounts.*.botTokenchannels.zalo.accounts.*.webhookSecret- 兄弟
serviceAccountRef経由のchannels.googlechat.serviceAccount(互換性の例外) - 兄弟
serviceAccountRef経由のchannels.googlechat.accounts.*.serviceAccount(互換性の例外)
auth-profiles.json ターゲット (secrets configure + secrets apply + secrets audit)
profiles.*.keyRef(type: "api_key";auth.profiles.<id>.mode = "oauth"の場合は未サポート)profiles.*.tokenRef(type: "token";auth.profiles.<id>.mode = "oauth"の場合は未サポート)
注記:
- auth-profile プランターゲットには
agentIdが必要です。 - プランエントリは
profiles.*.key/profiles.*.tokenをターゲットにし、兄弟 ref (keyRef/tokenRef) を書き込みます。 - auth-profile ref は実行時解決と監査カバレッジに含まれます。
openclaw.jsonでは、SecretRef は{"source":"env","provider":"default","id":"DISCORD_BOT_TOKEN"}のような構造化オブジェクトを使用する必要があります。レガシーのsecretref-env:<ENV_VAR>マーカー文字列は SecretRef 認証情報パスでは拒否されます。有効なマーカーを移行するにはopenclaw doctor --fixを実行してください。- OAuth ポリシーガード:
auth.profiles.<id>.mode = "oauth"は、そのプロファイルの SecretRef 入力と組み合わせることはできません。このポリシーに違反すると、起動/再読み込みおよび auth-profile 解決は即座に失敗します。 - SecretRef 管理のモデルプロバイダーでは、生成される
agents/*/agent/models.jsonエントリは、apiKey/ヘッダーサーフェスについて非シークレットのマーカー (解決済みのシークレット値ではない) を永続化します。 - マーカーの永続化はソースを権威とします。OpenClaw は解決済みの実行時シークレット値からではなく、アクティブなソース設定スナップショット (解決前) からマーカーを書き込みます。
- Web 検索について:
- 明示的なプロバイダーモード (
tools.web.search.providerが設定されている) では、選択されたプロバイダーキーのみがアクティブです。 - 自動モード (
tools.web.search.providerが未設定) では、優先順位によって解決される最初のプロバイダーキーのみがアクティブです。 - 自動モードでは、選択されていないプロバイダー ref は選択されるまで非アクティブとして扱われます。
- レガシーの
tools.web.search.*プロバイダーパスは互換性期間中も引き続き解決されますが、正準の SecretRef サーフェスはplugins.entries.<plugin>.config.webSearch.*です。
- 明示的なプロバイダーモード (
サポートされない認証情報
スコープ外の認証情報には以下が含まれます:
commands.ownerDisplaySecrethooks.tokenhooks.gmail.pushTokenhooks.mappings[].sessionKeyauth-profiles.oauth.*channels.discord.threadBindings.webhookTokenchannels.discord.accounts.*.threadBindings.webhookTokenchannels.whatsapp.creds.jsonchannels.whatsapp.accounts.*.creds.json
根拠:
- これらの認証情報は、発行済み、ローテーション対象、セッションを持つ、または OAuth で永続するクラスであり、読み取り専用の外部 SecretRef 解決には適合しません。
関連
Was this useful?