define_native_tool
define_native_tool
Define a function that the platform implements itself, such as end_call, under
your own description and parameters. The function is sent with
web_hook_url: "native", so the platform runs its own implementation by name and
calls no webhook. Use it to describe a platform function in your own words, or so
that a step’s function list can name it.
A tool from define_tool() always gets the agent’s webhook URL, so it
can’t be a native function. To turn on the platform’s built-in functions without
your own description, use set_native_functions().
Parameters
name
The function’s name, one the platform implements.
description
The description the model reads.
parameters
The JSON Schema of its arguments, as the platform’s implementation reads them.
None sends an empty object schema.
**swaig_fields
Other SWAIG function fields, such as fillers.
Returns
AgentBase — Self for method chaining.
Example
The rendered function: