ToolDefinition
openmolt / ToolDefinition
Interface: ToolDefinition
Defined in: types/index.ts:123
Definition of a single tool within an integration.
Properties
body?
optionalbody:Record<string,unknown>
Defined in: types/index.ts:141
Request body. Supports Liquid templates.
description
description:
string
Defined in: types/index.ts:127
Human-readable description of what the tool does.
endpoint?
optionalendpoint:string
Defined in: types/index.ts:135
Path appended to the integration's baseUrl. Supports Liquid templates with input.*.
execute()?
optionalexecute: (input,context) =>Promise<unknown>
Defined in: types/index.ts:145
Custom async function invoked when the tool is called. Takes precedence over HTTP config.
Parameters
input
Record<string, unknown>
context
Returns
Promise<unknown>
handle
handle:
string
Defined in: types/index.ts:125
Unique handle used to identify the tool within its integration.
headers?
optionalheaders:Record<string,unknown>
Defined in: types/index.ts:139
Additional headers to merge for this specific tool.
inputSchema?
optionalinputSchema:ZodTypeAny
Defined in: types/index.ts:148
Zod schema describing the expected input object.
method?
optionalmethod:string
Defined in: types/index.ts:133
HTTP method.
outputSchema?
optionaloutputSchema:ZodTypeAny
Defined in: types/index.ts:150
Zod schema describing the expected output object (informational for the agent).
queryParams?
optionalqueryParams:Record<string,unknown>
Defined in: types/index.ts:137
Query parameters. Supports Liquid templates.
scopes?
optionalscopes:string[]
Defined in: types/index.ts:129
Scopes from the integration's scopes map that are required to use this tool.