Skip to main content
Table of Contents

TTMSMCPToolBuilder.DynamicExecuteCallback Method

Assigns the callback that runs when the tool is invoked, receiving its arguments keyed by parameter name. Choose it over the positional callback when optional parameters may be absent from a call.

API unit family: TMS.MCP.Tools Declaring type: TTMSMCPToolBuilder

Syntax

TMS.MCP.Tools.hppPascalC++
class function DynamicExecuteCallback(const ACallback: TTMSMCPDynamicMethod): TTMSMCPToolBuilderClass;
__classmethod TTMSMCPToolBuilderClass __fastcall DynamicExecuteCallback(const Tms::Mcp::Helpers::_di_TTMSMCPDynamicMethod ACallback);

Parameters

Name Description
ACallback The anonymous method to run. It must be assigned.

Returns

The tool builder class, so the configuration can be chained.

Exceptions

Exception Description
EJsonRpcException Raised with an invalid-parameters code when the callback is not assigned.