Entirely theoretical here.
If one were to use a webhook, could anyone explain why this script might provide an HTTP 400 error? (It is not because it uses discord dot com as a webhook URL.)
Just another very strict clarification, completely all theoretical, I’d like to know why my script isn’t working.
local GradeNew = tostring("Grade"..Grade.."Ping")
local Data = {
{
["content"] = tostring(Settings[GradeNew]),
["embeds"] = {{
["thumbnail"] = "https://www.roblox.com/headshot-thumbnail/image?userId="..tostring(Player.UserId).."&width=420&height=420&format=png",
["author"] = "Grade-"..Grade.." Log",
["type"] = "rich",
["color"] = tonumber(0xffffff),
["fields"] = {
{
["name"] = "**User Information**";
["value"] = '['..Player.Name .. '](https://www.roblox.com/users/'.. Player.UserId ..'/profile)' .. " | " .. Player.UserId;
["inline"] = true
},
{
["name"] = "**Game Data**";
["value"] = "ID:"..tostring(game.GameId).."\nPrivate Server: "..tostring(game.PrivateServerId);
["inline"] = true
},
{
["name"] = "**Rank**";
["value"] = tostring(Rank.Value);
["inline"] = true
},
{
["name"] = "**Command**";
["value"] = "[<t:"..os.time(os.date("!*t"))..":T>] - `".. Command .."`";
["inline"] = false
},
}
}
}}}
return Data
later on…
local GradeHTTP = Settings[tostring("Grade"..Grade)]
local finaldata = HttpService:JSONEncode(Queery(Player,Rank,cmd,Grade))
HttpService:PostAsync(GradeHTTP, finaldata)
Yet again, purely theoretical.