HttpService Error

At line 62, the line with [“urlSource”] = nil, I’m getting an HTTP 400 error, and I’m not entirely sure why. I haven’t had this issue before, and it just started appearing. HTTP Service is on, and this code is inside of a ServerScript.

Error:

20:11:30.405 - HTTP 400 (Bad Request)

20:11:30.407 - Stack Begin

20:11:30.410 - Script ‘Players.SS4PPHIRE.PlayerGui.ScreenGui.TrelloFunctions’, Line 62 - function addBan

20:11:30.412 - Script ‘Players.SS4PPHIRE.PlayerGui.ScreenGui.TrelloFunctions’, Line 70

20:11:30.414 - Stack End

Code:

function addBan(username, userid, bantype, reason, evidence)
    local get =
        http:GetAsync(
        "https://api.trello.com/1/boards/" .. module.Trello .. "/lists?key=" .. module.Key .. "&token=" .. module.Token,
        true
    )
    local tab = http:JSONDecode(get)
    for _, v in pairs(tab) do
        if v.name:match("^".. bantype .."?$") then
            boardid = v.id
            local musget =
                http:GetAsync(
                "https://api.trello.com/1/lists/" .. v.id .. "/cards?key=" .. module.Key .. "&token=" .. module.Token,
                true
            )
            local mustab = http:JSONDecode(musget)
        end
    end

    local musget =
        http:PostAsync(
        "https://api.trello.com/1/cards/?key=" .. (module.Key) .. "&token=" .. (module.Token),
        http:JSONEncode(
            {
                ["name"] = (username .. " | " .. tostring(userid)),
                ["desc"] = "Username: " .. username .. "\n\nBan Type: " .. bantype .. "\n\nReason for Ban: " .. reason .. "\n\nEvidence: " .. evidence,
                ["due"] = nil,
                ["idList"] = boardid,
                ["urlSource"] = nil
            }
        )
    )
end

game.ReplicatedStorage.AdminPanelEvent.OnServerEvent:Connect(function(requestedfunction, username, userid, bantype, reason, evidence)
        if requestedfunction == "AddBan" then
		addBan(username, userid, bantype, reason, evidence)
        end
end)
1 Like

Roblox Engineers are working to solve this problem, this bug happens for some days.

2 Likes

Alright. Can you send me the post where they announced this? Just wanted to read some more on it.

1 Like

They don’t announce it, but there are many people saying the same bug (including me).

This is a topic: HttpService and character API failing

2 Likes