Overview
The Custom Tool node lets you use tools that you’ve created in Flowise’s built-in tool builder. These tools can execute custom JavaScript/TypeScript code with defined inputs and outputs, giving your agents access to virtually any functionality you can program.Custom Tools are created separately in Flowise’s Tool Builder interface and then referenced in your workflows using the Custom Tool node.
Creating a Custom Tool
Define Tool Metadata
Provide basic information about your tool:
- Name: A unique identifier for the tool (e.g.,
weatherAPI) - Description: Clear description of what the tool does (helps the agent decide when to use it)
Using Custom Tools in Workflows
Configuration
Select the custom tool you want to use from the dropdown list.This list is populated from all tools you’ve created in the Tool Builder.
When enabled, the tool’s output is returned directly to the user without further agent processing.Use cases:
- Tool already returns a well-formatted response
- You want to bypass additional LLM processing for speed
- Tool output doesn’t need further interpretation
Adding to an Agent
Custom Tool Examples
Example 1: Weather API Tool
- Tool Definition
- Implementation
Name: Schema:
getWeatherDescription:Example 2: Database Query Tool
- Tool Definition
- Implementation
Name: Schema:
queryUserDatabaseDescription:Example 3: CRM Integration Tool
- Tool Definition
- Implementation
Name: Schema:
createCRMTicketDescription:Advanced Features
Using Variables
Custom tools can access Flowise variables (API keys, configuration) stored in the system:Accessing Flow Information
Tools can access information about the current chatflow:Error Handling
Schema Definition Guide
The schema defines what inputs your tool accepts. It follows JSON Schema format:- String Input
- Number Input
- Enum/Options
- Boolean Input
- Array Input
Best Practices
Tool Design Guidelines
- Single Responsibility: Each tool should do one thing well
- Clear Naming: Use descriptive names that indicate the tool’s purpose
- Detailed Descriptions: Help the agent understand when to use the tool
- Input Validation: Validate inputs before processing
- Error Handling: Always return meaningful error messages
- Return Strings: Tools should return string responses for the agent to interpret
- Keep It Simple: Complex tools are harder for agents to use correctly
Debugging Custom Tools
Security Considerations
Performance Optimization
Common Use Cases
API Integration
Connect to third-party APIs (weather, payments, CRM, etc.)
Database Operations
Query, insert, or update records in your database
Business Logic
Implement custom business rules and calculations
File Operations
Read, write, or process files and documents
Notifications
Send emails, SMS, or push notifications
Data Transformation
Format, convert, or process data in custom ways
Related Resources
Tool Agent
Build agents that use custom tools effectively
Agent Overview
Learn about agent fundamentals
Calculator Tool
See built-in tool examples
Variables & Secrets
Manage API keys and configuration