Script Error 400 Bad Request

Hello,

I’m currently creating a script that allows you to control Emerson LiteLeaf 2 via a UI panel using the liteleaf API and it also logs it in Discord using an embed.

I created the system and it was working fine and it randomly stopped working overnight however I’m unsure if I made a change that’s stopped it from working or if it’s a roblox error.

The POST function using httpservice is wrapped in a pcall, and this is the error I’m receving:
image

Does anyone have any guidance/help to solve this?


	data = HttpService:JSONEncode(data)
		local success, errormsg = pcall(function()
			HttpService:PostAsync(webhook, data)
		end)
		if success then
			print("Success")
		else
			warn("Error: "..errormsg)
		end

Thanks,

Kaden