External API

Learn how to integrate and configure the External API feature to enable your characters to access real-time information, create tasks, and interact with third-party platforms.

Introduction

The External API feature empowers your characters to interact intelligently with real-time data sources and third-party services. Whether it’s retrieving live weather updates, tracking sports scores, or creating tickets in platforms like Jira and Trello, this feature allows seamless API-based integration. With just a few configuration steps, your characters can fetch data, trigger workflows, and execute automated actions, making them significantly more capable.


Configuration and Usage

1. Accessing the External API Page

Navigate to the External API section in your dashboard. Here you can view existing API methods, activate or deactivate them, and create new methods. To add a new API method, click Add API Method.


2. Creating an API Method

Method Fields Overview

  • Method Name – Select an existing template or enter a unique name for your method.

  • Method Description – Provide a concise explanation of the method’s functionality.

  • Input Description (JSON Format) – Define required input parameters and their descriptions.

  • Implementation Code – Write the Python implementation for your API logic.

  • Inputs – Enter test parameters for validating your method.

  • Output – Displays the result when you click Test API.


Example 1 – Get Weather Data

Method Name Get Weather

Method Description Fetches current weather data for a given city

Input Description

Implementation Code

Setup Notes

  1. Sign up at OpenWeatherMap and get your API key.

  2. Replace <your-api-key> in the code with your key.

Test Input

Click Test API.

A successful Output Example:

Activate the method

If the test passes, click Save Changes, return to the main API list, and enable the method by toggling Connect to green.

Test with a character

Once activated, test the method in a conversation with your character. As seen in the screenshot below, the character correctly returned the current weather for Roma and Wrangell.


Example 2 – Create Jira Support Ticket

Method Name Creating Support Tickets

Method Description Creates a support ticket on Jira

Input Description

Implementation Code

Where to Find Required Values

  • JIRA_DOMAIN – Found in your Jira account URL. Example: https://mycompany.atlassian.net → JIRA_DOMAIN = "mycompany.atlassian.net"

  • EMAIL – Your Atlassian login email.

  • API_TOKEN – Create from Atlassian API Tokens.

  • JIRA_PROJECT_KEY – Found in your project URL or next to the project name.

  • ISSUE_TYPE – Must be valid in your Jira project (Story, Task, Bug).

Test Input

Click Test API.

A successful Output Example:

Activate the method If the test passes, click Save Changes, return to the main API list, and enable the method by toggling Connect to green.

Test with a character Once activated, test the method in a conversation with your character. As seen in the screenshot below, the character successfully created a Jira ticket and returned the ticket key.


Limitations and Supported Environment


Conclusion

By configuring the External API feature, you can transform your characters into powerful, data-driven assistants. From retrieving real-time weather information to creating Jira tickets directly from a conversation, the possibilities are vast. This integration capability enables highly interactive, automated, and intelligent workflows.

Last updated

Was this helpful?