mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 10:01:38 +00:00
feat(config): add tools.alsoAllow additive allowlist
This commit is contained in:
committed by
Pocket Clawd
parent
b9098f3401
commit
2ad3508a33
@@ -140,12 +140,21 @@ export type ToolProfileId = "minimal" | "coding" | "messaging" | "full";
|
||||
|
||||
export type ToolPolicyConfig = {
|
||||
allow?: string[];
|
||||
/**
|
||||
* Additional allowlist entries merged into the effective allowlist.
|
||||
*
|
||||
* Intended for additive configuration (e.g., "also allow lobster") without forcing
|
||||
* users to replace/duplicate an existing allowlist or profile.
|
||||
*/
|
||||
alsoAllow?: string[];
|
||||
deny?: string[];
|
||||
profile?: ToolProfileId;
|
||||
};
|
||||
|
||||
export type GroupToolPolicyConfig = {
|
||||
allow?: string[];
|
||||
/** Additional allowlist entries merged into allow. */
|
||||
alsoAllow?: string[];
|
||||
deny?: string[];
|
||||
};
|
||||
|
||||
@@ -188,6 +197,8 @@ export type AgentToolsConfig = {
|
||||
/** Base tool profile applied before allow/deny lists. */
|
||||
profile?: ToolProfileId;
|
||||
allow?: string[];
|
||||
/** Additional allowlist entries merged into allow and/or profile allowlist. */
|
||||
alsoAllow?: string[];
|
||||
deny?: string[];
|
||||
/** Optional tool policy overrides keyed by provider id or "provider/model". */
|
||||
byProvider?: Record<string, ToolPolicyConfig>;
|
||||
@@ -312,6 +323,8 @@ export type ToolsConfig = {
|
||||
/** Base tool profile applied before allow/deny lists. */
|
||||
profile?: ToolProfileId;
|
||||
allow?: string[];
|
||||
/** Additional allowlist entries merged into allow and/or profile allowlist. */
|
||||
alsoAllow?: string[];
|
||||
deny?: string[];
|
||||
/** Optional tool policy overrides keyed by provider id or "provider/model". */
|
||||
byProvider?: Record<string, ToolPolicyConfig>;
|
||||
|
||||
Reference in New Issue
Block a user