Skip to main content

How to Use Tools(formerly called "plugins")?

Enhance your chat experience by integrating external capabilities through tools (formerly called "plugins").

Christopher Varner avatar
Written by Christopher Varner
Updated over a week ago

Overview

Build custom tools (formerly "plugins") that extend your agents' capabilities by connecting to external APIs and services. This tutorial walks through creating a tool from scratch, configuring API endpoints, defining variables, and testing functionality using a real-world math calculation example.

Important Note: Tools have replaced plugins in the TeamAI interface. All functionality previously available through plugins is now accessed through the tools system with enhanced configuration options and testing capabilities.

Learning Objectives:

  • Access the tool creation interface from the left panel

  • Understand the four tool type options and when to use each

  • Configure API endpoints with dynamic variables

  • Define and map variables for user input extraction

  • Handle special character encoding in URL parameters

  • Test tools before launching to verify functionality

Prerequisites

You'll Need:

  • Access to a workspace with tool creation privileges (Professional or Enterprise plan)

  • Understanding of REST APIs, endpoints, and HTTP methods (GET/POST)

  • A target API to connect to (we'll use math.js as an open-source example)

  • Basic knowledge of URL encoding for special characters

  • At least one folder created if you want to organize your tool

Important: Tool creation requires API configuration skills. If you're not comfortable with endpoints and variables, consider using pre-built tools or consulting with a developer.


Creating a New Tool

Access the Tool Creation Interface

  1. Navigate to the left panel to view your workspace navigation menu

  2. Click the "Tools" icon (represented by a πŸ”§ wrench) in the left panel navigation

  3. Click the "+ Create a Tool" button at the top-right of the tools list
    ​

  4. Enter a Tool Name in the "Name" field (e.g., "Math Calculator")
    ​

  5. Select Tool Type - Click the dropdown and choose from these options:
    ​

Tool Type

When to Use

Best For

API Tool

Connecting to any REST API endpoint

External services, data lookup, calculations

MCP Server

Connecting to Model Context Protocol servers

Advanced AI model integrations

Form Collection

Gathering structured user input

Surveys, data collection, user forms

MCP Studio

Building complex multi-step tool workflows

Advanced automation sequences


​Result: The "New Tool" creation modal appears with configuration options.


Configure Tool Type and Visibility

  1. Write a description explaining what the tool does (e.g., "Performs mathematical calculations using math.js API")
    ​

  2. Select an avatar for your tool. You can upload a custom image or click "Generate with AI" to create one automatically
    ​

Note: You can change the tool's group assignment later, but the tool type cannot be changed once you advance to the main wizard interface
​


Navigate to API Setup

  1. Click the "API Setup" tab in the left panel (below Details)
    ​

  2. Observe the completion tracker showing "0% complete" with sections for:

    • Basic Info (βœ“ should be complete from creation step)

    • API Setup

    • Variables


Configure Endpoint and Method

  1. Enter the API Endpoint URL in the "API Connection" field

    • For our math.js example: https://api.mathjs.org/v4/?expr={{a}}{{operation}}{{b}}.
      To determine your API's endpoint URL:
      1) Visit the API provider's documentation, in our example is https://api.mathjs.org/
      2) Find the GET request examples,


    • 3) Identify the base URL and parameter structure,
      ​

      Where base URL is http://api.mathjs.org/v4/?expr=
      and the parameters are 2%2B8 a=2 %2b is the "+" sign for operation and b=8
      ​

    • Replace with your target API URL
      ​https://api.mathjs.org/v4/?expr={{a}}{{operation}}{{b}}

  2. Select the Request Method:

    • GET: For retrieving data (most common for queries and calculations)

    • POST: For sending data to create or update resources

Example for math.js: Select "GET" since we're requesting a calculation result

Result: The request preview at the bottom updates to show your configured endpoint.



Add Variables

  1. Click "Add Variable" in the "Variables" section

  2. Configure each variable by completing these fields:

For our math example, add these three variables:

Variable 1: a

  • Variable Name: a

  • Description: First Number to be used in the operation

  • Type: Number

  • Required: Yes (toggle on)

  • Description: "First number (higher number for division)"

Variable 2: b

  • Name: b

  • Description: Second Number to be used in the operation

  • Type: Number

  • Required: Yes (toggle on)

  • Description: "Second number (lower number for division)"

Variable 3: operation

  • Name: operation

  • Type: String

  • Required: Yes (toggle on)

  • Description: "Math operator (%2B for add, %2F for divide, %2D for subtract, %2A for multiply)"

Result: The variables appear in your list and the request preview updates to show {{a}} {{operation}} {{b}} placeholders.

Tip: Variable names in double curly braces {{variableName}} must match exactly what you used in the endpoint URL.

Variable Type Reference

Type

Use For

Example

UI Prompt

Text Input

Strings, names, messages

city, name, query

Text field

Number Value

Numeric data

limit, count, id

Number input

Boolean Flag

True/false toggles

enabled, verbose

Checkbox

List of Strings

Multiple text values

tags, categories

Multi-select text

List of Numbers

Multiple numeric values

ratings, scores

Multi-select numbers


Configuring Headers and Parameters

Add Authentication Headers (If Required)

  1. Click "Add Header" in the "Headers" section

  2. Configure common headers or add custom ones:

Common headers you may need:

  • Authorization: Bearer YOUR_API_TOKEN

  • Content-Type: application/json

  • Accept: application/json

  • User-Agent: TeamAI-Tool/1.0

For math.js (public API): No headers required

Result: Headers are added to your API request configuration.

Note: Never commit API keys or tokens directly in tool configurations for shared tools. Use workspace secrets management if available.


Configure Query Parameters

  1. Click "Add Parameter" in the "Query Parameters" section

  2. Add URL parameters (these append to your endpoint as ?key=value&key=value)

For math.js: The expression parameter is already included in the main URL (?expr=...), so no additional parameters needed.

Result: The "Request Preview" section at the bottom shows your complete API call structure.


Testing Your Tool

Navigate to Test & Launch

  1. Click the "Test & Launch" tab in the left panel

  2. Fill in test values in the test fields that appear:

    • a: 10

    • b: 5

    • operation: %2B (remember: %2B for addition, %2F for division, %2D for subtraction, %2A for multiplication)

  3. Click "Run Test" to execute the API call

Result: The test executes and shows a loading indicator while contacting the API.


Review Response Data

  1. Check the "Response Data" section that appears below the test button

  2. Verify you receive the expected result: For 10%2B5, you should see 15

Successful Response Example:

{   "status": 200,   "data": "15",   "responseTime": "124ms" }

Result: Your tool is working correctly and ready to launch.

Troubleshooting: If you get an error:

  • Check URL encoding: Verify operators use %2B, %2F, etc., not raw symbols

  • Validate variable values: Ensure numbers don't contain letters or spaces

  • Review API limits: Some public APIs have rate limits; wait and retry

  • Check endpoint: Confirm the URL is accessible in your browser


Launching and Using Your Tool

Finalize and Enable

  1. Click "Save Changes" at the top-right of the screen

  2. Click the "Tools" button and check if your tool exists

Result: Your tool is now active and ready for use.


Common Questions

Q: Can I edit a tool after launching it?
A: Yes. Return to the Tools section, click your tool name, and edit any configuration. Changes take effect immediately without requiring reactivation.

Q: Why do I need to URL encode special characters?
A: URLs interpret special characters as control syntax. Encoding (e.g., %2B for +) ensures the character is treated as literal data, not URL structure.

Q: What variable types should I use?
A: Use "Text Input" for strings, "Number Value" for numeric data, "Boolean Flag" for true/false, and "List" options for multiple values. Required variables must be provided for the tool to execute.

Q: Can I see the tool's API calls in the chat?
A: No. The API calls happen in the background. Only the final result appears in the chat. Use the Test & Launch tab to debug API behavior.

Q: How do I handle APIs that require POST instead of GET?
A: Select "POST" as the request method, then configure the request body payload using the "Request Configuration" section that appears. Define JSON structure with your variables.

Best Practices

  1. Test with multiple scenarios: Run tests with different variable values (positive numbers, negative numbers, zero) to ensure your tool handles edge cases gracefully.

  2. Document your variables: Write clear descriptions for each variable explaining expected format and any special requirements (like URL encoding for operators).

  3. Use public APIs for testing: Practice with open APIs like math.js, JSONPlaceholder, or public weather APIs before configuring production or paid services.
    ​
    ​

Did this answer your question?