mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-01 12:21:25 +00:00
Agents: pass explicit message tool agent id
This commit is contained in:
@@ -488,6 +488,7 @@ const MessageToolSchema = buildMessageToolSchemaFromActions(AllMessageActions, {
|
||||
type MessageToolOptions = {
|
||||
agentAccountId?: string;
|
||||
agentSessionKey?: string;
|
||||
agentId?: string;
|
||||
config?: OpenClawConfig;
|
||||
currentChannelId?: string;
|
||||
currentChannelProvider?: string;
|
||||
@@ -775,9 +776,9 @@ export function createMessageTool(options?: MessageToolOptions): AnyAgentTool {
|
||||
gateway,
|
||||
toolContext,
|
||||
sessionKey: options?.agentSessionKey,
|
||||
agentId: options?.agentSessionKey
|
||||
? resolveSessionAgentId({ sessionKey: options.agentSessionKey, config: cfg })
|
||||
: undefined,
|
||||
agentId:
|
||||
options?.agentId?.trim() ||
|
||||
resolveSessionAgentId({ sessionKey: options?.agentSessionKey, config: cfg }),
|
||||
sandboxRoot: options?.sandboxRoot,
|
||||
abortSignal: signal,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user