<!--
 ⚠️  AUTO-GENERATED FILE - DO NOT EDIT MANUALLY
 This file is automatically generated by scripts/docs-generator.js
 To make changes, edit the source TypeScript files or update the generator script
-->

[agents](../../) / [Exports](../modules) / IToolFactory

# Interface: IToolFactory

Tool factory interface

## Table of contents

### Methods

- [createFunctionTool](IToolFactory#createfunctiontool)
- [createOpenAPITool](IToolFactory#createopenapitool)
- [createMCPTool](IToolFactory#createmcptool)

## Methods

### createFunctionTool

▸ **createFunctionTool**(`schema`, `fn`): [`IFunctionTool`](IFunctionTool)

Create function tool from schema and function

#### Parameters

| Name     | Type                                                                                                                                            |
| :------- | :---------------------------------------------------------------------------------------------------------------------------------------------- |
| `schema` | [`IToolSchema`](IToolSchema)                                                                                                                    |
| `fn`     | [`TToolExecutor`](../modules#ttoolexecutor)\<[`TToolParameters`](../modules#ttoolparameters), [`TUniversalValue`](../modules#tuniversalvalue)\> |

#### Returns

[`IFunctionTool`](IFunctionTool)

#### Defined in

[packages/agents/src/interfaces/tool.ts:285](https://github.com/woojubb/robota/blob/4f4c8a3197e92ddd43d12dc9186b0771983054c9/packages/agents/src/interfaces/tool.ts#L285)

---

### createOpenAPITool

▸ **createOpenAPITool**(`config`): [`IToolInterface`](IToolInterface)

Create tool from OpenAPI specification

#### Parameters

| Name     | Type                                       |
| :------- | :----------------------------------------- |
| `config` | [`IOpenAPIToolConfig`](IOpenAPIToolConfig) |

#### Returns

[`IToolInterface`](IToolInterface)

#### Defined in

[packages/agents/src/interfaces/tool.ts:290](https://github.com/woojubb/robota/blob/4f4c8a3197e92ddd43d12dc9186b0771983054c9/packages/agents/src/interfaces/tool.ts#L290)

---

### createMCPTool

▸ **createMCPTool**(`config`): [`IToolInterface`](IToolInterface)

Create MCP tool

#### Parameters

| Name     | Type                               |
| :------- | :--------------------------------- |
| `config` | [`IMCPToolConfig`](IMCPToolConfig) |

#### Returns

[`IToolInterface`](IToolInterface)

#### Defined in

[packages/agents/src/interfaces/tool.ts:295](https://github.com/woojubb/robota/blob/4f4c8a3197e92ddd43d12dc9186b0771983054c9/packages/agents/src/interfaces/tool.ts#L295)
