DUXPLIMA Documentation

Discord notifications

Posting build starts, completions and cancellations to a Discord webhook.

uxmBuilders can post a line to a Discord channel, or any service that accepts Discord's webhook format, when a build starts, finishes or is cancelled.

Setting it up

  1. In Discord: channel settings, Integrations, Webhooks, New Webhook, copy its URL.
  2. In config.yml:
notifications:
  webhook:
    enabled: true
    url: 'https://discord.com/api/webhooks/...'
    username: 'uxmBuilders'
    events: [ START, COMPLETE, CANCEL ]
  1. /builders admin reload.

Events

EventPosted whenMessage key
STARTA build has really started, money taken and job queuedwebhookBuildStarted
COMPLETEThe last block is placedwebhookBuildCompleted
CANCELA build is cancelled, for any reasonwebhookBuildCancelled

The text lives in messages.yml, in your language, with its colour tags stripped. Discord markdown and emoji codes work:

webhookBuildCompleted: ':white_check_mark: %player.name% finished **%package.name%** (#%job.id%)'
PlaceholderValue
%player.name%The owner
%package.name%The package's display name
%job.id%, %job.total%, %job.progress%The job
%location.world%, %location.x%, %location.y%, %location.z%Where it is
%economy.refund%, %reason%Cancellations only

Notes

  • Posts go out one at a time on a background thread; a slow or unreachable webhook never touches the main thread.
  • A rate limit from Discord is honoured once with its retry delay. A backlog of more than 100 posts is dropped with a warning rather than held in memory.
  • Mentions are disabled: a player who names a package @everyone pings nobody.
  • An empty or invalid URL logs one warning and posts nothing.

Related: Messages and menus