Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I add a footer to a discord webhook embed?

Asked by 3 years ago
Edited 3 years ago

I've searched all over the internet for this, and could not find it anywhere. How would I add a footer to my discord embed? Here's the script I already have.

local url = "Webhook not here for privacy purposes"
local http = game:GetService("HttpService")

game.Players.PlayerAdded:Connect(function(plr)
    local data = {
        ['embeds'] = {{
                ['title'] = "**A Player has joined the game.**",
                ['description'] = plr.Name.." has joined the game.",
                ['color'] = 1043474,
                ['url'] = "https://www.roblox.com/users/"..plr.UserId.."/profile"
                }}
    }

    local finaldata = http:JSONEncode(data)
    http:PostAsync(url, finaldata)

end)

game.Players.PlayerRemoving:Connect(function(plr)
    local data = {
        ['embeds'] = {{
                ['title'] = "**A Player has left the game.**",
                ['description'] = plr.Name.." has left the game.",
                ['color'] = 16711680,
                ['url'] = "https://www.roblox.com/users/"..plr.UserId.."/profile",
                }}
    }

    local finaldata = http:JSONEncode(data)
    http:PostAsync(url, finaldata)

end)

Answer this question