Bot Integration

Telegram Bot

  1. Create a Telegram bot and paste the bot token in the .env file:

# Telegram Bot Token
TELEGRAM_BOT_TOKEN=xxxxxxxx
  1. Uncomment the following lines in the docker-compose.yml file:

telegram-bot:
  build: zhenghaoz/midsearch
  environment:
    MIDSEARCH_ENDPOINT: http://midsearch:8080/api/
    MIDSEARCH_API_KEY: ${MIDSEARCH_API_KEY}
    TELEGRAM_BOT_TOKEN: ${TELEGRAM_BOT_TOKEN}
  command: python3 midsearch/client telegram
  1. Start the Telegram bot:

docker-compose up -d

Discord Bot

  1. Create a Discord bot and paste the bot token in the .env file:

# Discord Bot Token
DISCORD_BOT_TOKEN=xxxxxxxx
  1. Uncomment the following lines in the docker-compose.yml file:

discord-bot:
  build: zhenghaoz/midsearch
  environment:
    MIDSEARCH_ENDPOINT: http://midsearch:8080/api/
    MIDSEARCH_API_KEY: ${MIDSEARCH_API_KEY}
    DISCORD_BOT_TOKEN: ${DISCORD_BOT_TOKEN}
  command: python3 midsearch/client discord
  1. Start the Discord bot:

docker-compose up -d

Slack Bot

  1. Create a Slack bot and paste the bot token in the .env file:

# Slack Bot Token
SLACK_BOT_TOKEN=xxxxxxxx
  1. Uncomment the following lines in the docker-compose.yml file:

discord-bot:
  build: zhenghaoz/midsearch
  environment:
    MIDSEARCH_ENDPOINT: http://midsearch:8080/api/
    MIDSEARCH_API_KEY: ${MIDSEARCH_API_KEY}
    SLACK_BOT_TOKEN: ${SLACK_BOT_TOKEN}
  command: python3 midsearch/client slack
  1. Start the Slack bot:

docker-compose up -d

Wechat Bot (Wechaty)

QQ Bot (Mirai)