Skip to content

Latest commit

 

History

History
129 lines (93 loc) · 2.62 KB

DOCS.md

File metadata and controls

129 lines (93 loc) · 2.62 KB

Yue Docs v1.0.3

Credits to Rui, Liane

Table of Contents

Commands

1. ai

  • :ai [question] - Ask the chatbot a question, and it will generate a response using the AI API.
    • Example:
      :ai How does photosynthesis work?
      

2. prefix

Get the bot's current command prefix.

  • Example:
    prefix
    

3. help

View a list of available commands and their descriptions.

  • Example:
    :help
    

Database Commands

1. addUserToDB

  • addUserToDB(api: object, userID: string): void - Add a user to the SQLite database with the provided user ID.
    • Example usage:
      addUserToDB(api, "1234567890");

2. listUsers

  • listUsers(api: object): void - List users in the current SQLite database.
    • Example usage:
      listUsers(api);

3. getThreadInfo

  • getThreadInfo(threadID: string): object | null - Get information about a thread from the SQLite database.
    • Example usage:
      getThreadInfo("987654321");

4. getUserInfo

  • getUserInfo(userID: string): object | null - Get information about a user from the SQLite database.
    • Example usage:
      getUserInfo("1234567890");

Box Functions

1. box.react

  • box.react(emoji: string): void - React to the current message with a specified emoji.
    • Example usage:
      box.react("😊");

2. box.reply

  • box.reply(msg: string): void - Reply to the current message with a specified text.
    • Example usage:
      box.reply("Hello, World!");

3. box.add

  • box.add(uid: string): void - Add a user with the given UID to the current group chat.
    • Example usage:
      box.add("1234567890");

4. box.kick

  • box.kick(uid: string): void - Remove a user with the given UID from the current group chat.
    • Example usage:
      box.kick("1234567890");

5. box.send

  • box.send(msg: string): void - Send a message to the current thread without replying to a specific message.
    • Example usage:
      box.send("Hello, World!");