Logger

The SD.Logger module provides a structured logging system designed to collect and send logs to a Discord webhook, allowing developers to monitor and review events remotely.

Overview

Purpose: Provides a centralized logging mechanism using Discord webhooks, which aggregates logs into a Discord channel to aid in debugging and monitoring.

Parameters

  • name (string): A unique name for the log group.

  • title (string): The title of the log message.

  • color (string): A color code or key from predefined colors for the embed.

  • message (string): The content of the log message.

  • tagEveryone (boolean, optional): If set to true, includes an '@everyone' tag in the message.

Usage Example

SD.Logger("gameplay", "Player Connected", "default", "Player John_Doe has connected.", true)

Configuration

Before using SD.Logger, ensure that a valid webhookURL is set. This URL directs where the logs will be sent and is crucial for the module's operation.

local webhookURL = "https://discord.com/api/webhooks/123456789012345678/abcdefghijklmnoprstuvw

Last updated