Table of Contents

TTMSMCPServer.OnBeforeExecute Event

Occurs immediately before a tool method runs, with the raw request arguments and the values resolved from them. Use it to trace or audit calls.

API unit family: TMS.MCP.Server Declaring type: TTMSMCPServer Inherited from: TTMSMCPCustomServer

Syntax

OnBeforeExecute: TTMSMCPOnBeforeExecuteToolEvent;

Remarks

The handler is raised for tools owned by this server component, after argument resolution and before the tool method is invoked. It cannot replace the arguments or suppress the call; raising an exception from it fails the call instead.

Parameters

Name Description
ATool Tool whose method is about to run.
AJSONParams Raw arguments object as received from the client. It is owned by the server; do not free it.
AArguments Argument values resolved against the tool's declared parameters.