1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Postbot - Automated Replies to Triggers 1.0

Your forum can respond to !trigger commands posted by permitted users.

  1. Bloodcinder
    Compatible XF Versions:
    • 1.3
    • 1.4
    License:
    Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License
    Visible Branding:
    No
    Postbot add-on for XenForo
    by Bloodcinder

    This add-on allows your forum to automatically respond to trigger codes posted by your users in threads using PHP callbacks. This add-on comes with several example triggers, and I will release other triggers in "packs" that you can download. Developers can make your own triggers by defining them in the admin control panel and providing an appropriate PHP callback script.

    For an example, if the user enters:
    The postbot will respond with something like: (see example)
    You may demo this add-on in this thread at my website. Guests can look and post, but you must register and confirm (or ask for manual approval) if you want to try the triggers. There are no screenshots here at XenForo, but check the links to the examples where you can see the triggers in action.

    The postbot will only respond to brand new, unedited posts, and the postbot generates a real post separate from the original user's post. This means that users can't tamper with the results unless they have moderator permissions. This is useful when the result the postbot gives needs to be certifiably original, such as dice results in a game.

    Triggers start with a ! by default and can have any alphanumeric name. They are only recognized at the start of a line anywhere within the post. As soon as a user submits a post, the forum will check to see if there is a trigger in it and respond as expected. It happens instantly, so that the automated response appears right after the user's new post.

    Note that triggers may only be used by users/groups with permission to use triggers in nodes that permit triggers. By default, this will be nobody anywhere. You must at least add trigger permission to the Registered group for anybody to be able to use triggers.

    This add-on adds the following to your XenForo installation...
    • A new [Applications -> Postbot] menu in the admin control panel. Here you can configure each of the triggers available or add new ones. You can import and export triggers using XML.
    • A new admin permission for managing the postbot triggers.
    • A new user/node permission for allowing the user of triggers.
    • A new option [Messages -> Postbot Username] to specify the username that the postbot will post as.
    • A new option [Messages -> Trigger Prefix Format] which lets you pick the default ! for starting the triggers or lets you select from some other options including / and some standard commenting techniques.
    • A new option [Performance -> Defer Postbot Responses] which delays the postbot's responses until XenForo is idle. This is for very large boards to prevent slowdown but means that the postbot's responses don't appear immediately.
    • The username associated with your postbot will have all of its posts "minimized" when viewing threads, to take up less space. The avatar area will be shrunk and can be exposed by hovering over it.
    This add-on includes the following stock triggers...
    • !help displays help information about another trigger (example)
    • !debug allows developers to see data related to the trigger
    • !moon shows the current moon phase
    • !8ball generates a Magic 8-Ball response
    • !shuffle shuffles a list and displays some or all of them (example)
    The following trigger packs are currently available with more triggers for you to import...
    Triggers are designed to respond with messages to the user, but they can be configured to do almost anything that a PHP script can do, including checking permissions or running special automated tasks. For example, the !debug trigger refuses to work for anybody without the administrator permission to manage triggers, and the !moon trigger connects to a REST API to retrieve its data.

    If you need a trigger that you cannot develop on your own, you can contact me about developing it for a negotiable fee. However, the postbot system itself is free to use. You are also welcome to develop trigger packs and distribute them. If you do so, please let me know I can include them in the list of available trigger packs above.

    btn_donateCC_LG.gif

    For support or suggestions, please post in the discussion thread.

Recent Reviews

  1. Glen Anderson
    Glen Anderson
    5/5,
    Version: 1.0
    Xenforo needs more resources like this! I just love bots that can act as real users, like a character in a setting of your forum, it's so entertaining!
  2. Iversia
    Iversia
    5/5,
    Version: 1.0
    Fantastic way to add some fun automated interaction for members with immediate feedback. The examples included barely scratch the surface of what can be done with this add-on.