@function_tool decorator.
Tool Use & MCP
Tool use with Agentor
Use the @function_tool decorator in Agentor to give an agent access to external APIs — schema is generated from your Python function automatically.
Agentor simplifies the tool use process by automatically
generating the tool schema from the function definition, parsing the function signature, and calling the function when required.
To create an Agent with access to external tools or APIs, you need to define a function and decorate it with the
The result will be the weather in London.
In the next section, we will learn about how to build and use MCP Servers with Agentor.
Last modified on May 5, 2026
