docs(types): mark legacy aliases deprecated · openclaw/openclaw@4eba70b
vincentkoc
·
2026-04-29
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -45,6 +45,8 @@ export type MsgContext = {
|
45 | 45 | timestamp?: number; |
46 | 46 | }>; |
47 | 47 | /** |
| 48 | + * @deprecated Use CommandBody. |
| 49 | + * |
48 | 50 | * Raw message body without structural context (history, sender labels). |
49 | 51 | * Legacy alias for CommandBody. Falls back to Body if not set. |
50 | 52 | */ |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -112,7 +112,7 @@ export type ChannelSetupInput = {
|
112 | 112 | useEnv?: boolean; |
113 | 113 | homeserver?: string; |
114 | 114 | dangerouslyAllowPrivateNetwork?: boolean; |
115 | | -/** Compatibility alias for legacy setup callers; prefer dangerouslyAllowPrivateNetwork. */ |
| 115 | +/** @deprecated Compatibility alias; prefer dangerouslyAllowPrivateNetwork. */ |
116 | 116 | allowPrivateNetwork?: boolean; |
117 | 117 | proxy?: string; |
118 | 118 | userId?: string; |
@@ -407,6 +407,8 @@ export type ChannelThreadingAdapter = {
|
407 | 407 | */ |
408 | 408 | allowExplicitReplyTagsWhenOff?: boolean; |
409 | 409 | /** |
| 410 | + * @deprecated Use allowExplicitReplyTagsWhenOff. |
| 411 | + * |
410 | 412 | * Deprecated alias for allowExplicitReplyTagsWhenOff. |
411 | 413 | * Kept for compatibility with older plugin surfaces. |
412 | 414 | */ |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -7,6 +7,7 @@ import {
|
7 | 7 | |
8 | 8 | export type ConfigSetOptions = { |
9 | 9 | strictJson?: boolean; |
| 10 | +/** @deprecated Use strictJson. */ |
10 | 11 | json?: boolean; |
11 | 12 | dryRun?: boolean; |
12 | 13 | allowExec?: boolean; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -49,6 +49,7 @@ type GatewayRunOpts = {
|
49 | 49 | force?: boolean; |
50 | 50 | verbose?: boolean; |
51 | 51 | cliBackendLogs?: boolean; |
| 52 | +/** @deprecated Use cliBackendLogs. */ |
52 | 53 | claudeCliLogs?: boolean; |
53 | 54 | wsLog?: unknown; |
54 | 55 | compact?: boolean; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -42,6 +42,7 @@ export type PluginMarketplaceListOptions = {
|
42 | 42 | |
43 | 43 | export type PluginUninstallOptions = { |
44 | 44 | keepFiles?: boolean; |
| 45 | +/** @deprecated Use keepFiles. */ |
45 | 46 | keepConfig?: boolean; |
46 | 47 | force?: boolean; |
47 | 48 | dryRun?: boolean; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -8,7 +8,7 @@ export type OnboardMode = "local" | "remote";
|
8 | 8 | * are normalized elsewhere (for example `oauth` -> `setup-token`). |
9 | 9 | */ |
10 | 10 | export type BuiltInAuthChoice = |
11 | | -// Legacy alias for `setup-token` (kept for backwards CLI compatibility). |
| 11 | +/** @deprecated Use `setup-token`. */ |
12 | 12 | "oauth" | "setup-token" | "token" | "apiKey" | "custom-api-key" | "skip"; |
13 | 13 | export type AuthChoice = BuiltInAuthChoice | (string & {}); |
14 | 14 | |
@@ -20,7 +20,7 @@ export type GatewayBind = "loopback" | "lan" | "auto" | "custom" | "tailnet";
|
20 | 20 | export type TailscaleMode = "off" | "serve" | "funnel"; |
21 | 21 | export type NodeManagerChoice = "npm" | "pnpm" | "bun"; |
22 | 22 | export type ChannelChoice = ChannelId; |
23 | | -// Legacy alias (pre-rename). |
| 23 | +/** @deprecated Use ChannelChoice. */ |
24 | 24 | export type ProviderChoice = ChannelChoice; |
25 | 25 | export type { SecretInputMode } from "../plugins/provider-auth-types.js"; |
26 | 26 | |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -195,11 +195,11 @@ export type SessionMaintenanceConfig = {
|
195 | 195 | mode?: SessionMaintenanceMode; |
196 | 196 | /** Remove session entries older than this duration (e.g. "30d", "12h"). Default: "30d". */ |
197 | 197 | pruneAfter?: string | number; |
198 | | -/** Deprecated. Use pruneAfter instead. */ |
| 198 | +/** @deprecated Use pruneAfter instead. */ |
199 | 199 | pruneDays?: number; |
200 | 200 | /** Maximum number of session entries to keep. Default: 500. */ |
201 | 201 | maxEntries?: number; |
202 | | -/** Deprecated and ignored. Run `openclaw doctor --fix` to remove. */ |
| 202 | +/** @deprecated Ignored. Run `openclaw doctor --fix` to remove. */ |
203 | 203 | rotateBytes?: number | string; |
204 | 204 | /** |
205 | 205 | * Retention for archived reset transcripts (`*.reset.<timestamp>`). |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -35,7 +35,7 @@ export type CronConfig = {
|
35 | 35 | /** Override default retry policy for one-shot jobs on transient errors. */ |
36 | 36 | retry?: CronRetryConfig; |
37 | 37 | /** |
38 | | - * Deprecated legacy fallback webhook URL used only for stored jobs with notify=true. |
| 38 | + * @deprecated Legacy fallback webhook URL used only for stored jobs with notify=true. |
39 | 39 | * Prefer per-job delivery.mode="webhook" with delivery.to. |
40 | 40 | */ |
41 | 41 | webhook?: string; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -151,10 +151,24 @@ export type ModelsConfig = {
|
151 | 151 | mode?: "merge" | "replace"; |
152 | 152 | providers?: Record<string, ModelProviderConfig>; |
153 | 153 | pricing?: ModelPricingConfig; |
154 | | -// Deprecated legacy compat aliases. Kept in the runtime type surface so |
155 | | -// doctor/runtime fallbacks can read older configs until migration completes. |
| 154 | +/** |
| 155 | + * @deprecated Legacy compat alias. Kept so doctor/runtime fallbacks can read |
| 156 | + * older configs until migration completes. |
| 157 | + */ |
156 | 158 | bedrockDiscovery?: BedrockDiscoveryConfig; |
| 159 | +/** |
| 160 | + * @deprecated Legacy compat alias. Kept so doctor/runtime fallbacks can read |
| 161 | + * older configs until migration completes. |
| 162 | + */ |
157 | 163 | copilotDiscovery?: DiscoveryToggleConfig; |
| 164 | +/** |
| 165 | + * @deprecated Legacy compat alias. Kept so doctor/runtime fallbacks can read |
| 166 | + * older configs until migration completes. |
| 167 | + */ |
158 | 168 | huggingfaceDiscovery?: DiscoveryToggleConfig; |
| 169 | +/** |
| 170 | + * @deprecated Legacy compat alias. Kept so doctor/runtime fallbacks can read |
| 171 | + * older configs until migration completes. |
| 172 | + */ |
159 | 173 | ollamaDiscovery?: DiscoveryToggleConfig; |
160 | 174 | }; |
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | | -// Legacy compat surface for plugins that still import openclaw/extension-api. |
2 | | -// Keep this file intentionally narrow and forward-only. |
| 1 | +/** |
| 2 | + * @deprecated Legacy compat surface for plugins that still import |
| 3 | + * openclaw/extension-api. Use the injected plugin runtime or focused |
| 4 | + * openclaw/plugin-sdk subpaths instead. |
| 5 | + */ |
3 | 6 | |
4 | 7 | const shouldWarnExtensionApiImport = |
5 | 8 | process.env.VITEST !== "true" && |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。