Acknwoledgements, I am making a panel for my commission group for my staff members;
Although, when I attempted to script the webhook system, it does not worked. Even though, I made sure that everything was correct, correctly scripted and put together. Still no luck, any help! Thank you!
Local script:
script.Parent.StaffPanel.AnnounceCommsOpen.MouseButton1Click:Connect(function()
game.ReplicatedStorage.events.secondaary:FireServer()
end)
Serverscript:
local httpservice = game:GetService("HttpService")
local announcer = "webhook"
game.ReplicatedStorage.events.secondaary.OnServerEvent:Connect(function(plr, commission)
if commission == "AnnounceCommissionsOpen" then
local Data = {
['embeds'] = {
["tiitle"] = "sam's commission notifier",
["description"] = "Ahoy, commissions are now open, if you are interested in ordering from Sam, goto #tickets!"
}
}
Data = httpservice:JSONEncode(Data)
httpservice:PostAsync(announcer, Data)
end
end)
It looks fine. It should get to this line if commission == "AnnounceCommissionsOpen" then
and then stop because commission is nil, but otherwise it looks good.