- Bot Inputs: these are inputs provided by the user every time they run the bot. The lil’bots platform provides multiple input types that can be used to pass information - read more about them in the Bot Inputs document.
- Bot Parameters: these are parameters that are set when the bot is installed, and are used to configure the bot. They are set by the user when they install the bot, and can be used to customize the bot’s behavior. They support all the same types as inputs, but unlike inputs are not meant to be customzied on every run.
- Bot Outputs: these are the results of the bot’s work, and are displayed to the user. The lil’bots platform supports a wide variety of output types that can be used to display information to the user - read more about them in the Bot Outputs document.
- Accounts: these are external accounts that the bot can use to access external services. They are set by the user when they install the bot, and can be used to access external services like APIs, databases, and more. You can read more about them in the User Accounts document.
- Botspec File: The botspec file is a JSON file that defines the bot’s inputs, outputs, and runtime environment. It is used to configure the bot and provide the necessary information for the lil’bots platform to run the bot.
- Bot Script: The bot script is the code that defines the bot’s behavior. It is written in JavaScript or TypeScript and contains the logic that the bot uses to perform its task.
The Botspec File
Here is an example of a botspec file:Runtime
This specifies the runtime environment that the bot will run in. The lil’bots platform supports the following runtimes:deno
: Deno runtime - read more about the runtimepython
: Python runtime (Python 3.11) - read more about the runtime
Main
This specifies the main script file that the bot will run. This file contains the bot’s logic and defines how the bot will behave. It must expose amain
function that takes inputs, parameters, and accounts as arguments.
In the Deno runtime, that function may return a promise (async function).