Wallu - Developer API

Wallubot provides a easy-to-use API for developers to integrate Wallu into other platforms and projects.


Example Usage


const axios = require('axios')
// or import axios from 'axios'

const API_URL = 'https://api.wallubot.com/v1'

async function showExample() {

  const response = await axios.post(`${API_URL}/on-message`, {
    addon: {
      name: 'my-addon',
      version: '0.1.0',
    channel: {
      // You can generate one, for example, using the current group chat name/ID or generate a random one. The bot may use this to keep track of previous messages.
      id: '123456789',
    user: {
      // Some kind of identifier for this user. The bot may use this to keep track of previous messages.
      id: '123456789',
      // The username of the user (the bot may use this to personalize the response)
      username: 'John Doe',
      // Whether the user is a staff member. You can also just leave this false. (This mainly just affects some settings like the "avoid answering staff members unless mentioned")
      is_staff_member: false,
    message: {
      // ID of the message, or just generate a random ID for this.
      id: '123456789',
      // If true, the bot is forced to answer, otherwise it may not answer.
      is_bot_mentioned: true,
      // The message content
      content: 'how do I reset my password??'
    configuration: {
      // The emoji type to use. If set to 'none', the bot will not use any emojis.
      emoji_type: 'unicode',
      // Whether to include the sources links in the response.
      include_sources: false,
  }, {
    headers: {
      // You would use your own key here (or from env var)
      // It's recommended to use a different key for each addon
      // Find your API key here: https://panel.wallubot.com/addons
      "X-API-Key": process.env.WALLU_API_KEY,
  // {
  //   response: {
  //     message: 'Click "forgot my password" on the login page. For more information, you can visit the following link: <https://example.com>.'
  //   }
  // }

showExample().then(() => console.log("DONE!"))

Example Projects