ChatHook
PluginLicenseRef-All-Rights-Reserved

ChatHook

Sending Chat Messages to an External Server

44
Downloads
0
Followers
1 years ago
Updated
📦
1
Versions

📖About ChatHook

A simple plugin that allows you to send a player's chat message to an external server. It is well suited for creating a chat on a website or for Discord web hooks.

WARNING

FOR THE PLUGIN, YOU NEED A BACKEND SERVER TO ACCEPT REQUESTS FROM THE PLUGIN

Required dependencies

Commands

  • /chathook reload - reload plugin config

Permissions

  • chathook.use - Permission to use plugin commands

Config example

config.yml
# Author: Kredwi
# Issues: https://github.com/kredwi/chathook/issues
debug: false # Enable debug mode (true - enabled, false - disabled).
async: true # Use asynchronous requests, if disabled, chat messages can be sent with a significant delay
timeout: 5000 # Timeout in milliseconds, after which the connection will be closed.
request_url: "http://localhost:8439" # The address of the server to which requests will be sent.
authorization: "" # Authorization token, if not needed, leave the field empty
config-version: 1 # Config version

# Message sector
message_sector:
 error_invalid_command: "§cThis command does not exist"
 config_is_reloaded: "§aConfiguration successfully reloaded"
 no_arguments: "§cNot enough arguments"
 no_permissions: "§cYou do not have enough permissions"

# List of player nicknames whose messages will not be sent to the server
disabled_players:
- Kredwi
- igor

# Other information that will be sent in the request
other_information:
 key_1: "%player_ip%"
 key_2: "%player_name%"