discord_luau/builders
v0.0.1 ·
Discord-Luau Builders - Builders used to generate payloads that the discord API can parse.
Builders used to generate payloads that the Discord API can parse. If you are unfamiliar with what the Discord API expects, builders provide a simple and discoverable interface for constructing embeds, messages, components, interactions, and more without needing to know the raw payload structure.
Source: packages/builders
Installation
pesde add discord_luau/builders
Example
local Builders = require("./luau_packages/builders")
local embed = Builders.embed.embed.new()
:setTitle("Hello, world!")
:setDescription("Built with discord-luau.")
:setColor(0x5865F2)
:build()
local button = Builders.message.components.button.new()
:setStyle("Primary")
:setLabel("Click me")
:setCustomId("my_button")
:build()
local actionRow = Builders.message.components.actionRow.new()
:addComponent(button)
:build()
Full documentation at discordluau-docs.devcomp.workers.dev.
Contributing
Contributions are welcome via the repository at github.com/DiscordLuau/discord-luau.
License
This package is licensed under the MIT License.