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

My webhook is saying the https is forbidden. Is there a way around this?

Asked by 5 years ago

I was wondering if there was a way to get this script working?

local url = "https://discordapp.com/api/webhooks/486285105581785089/EC7e13TNSN9LGyWhPHr2a0FXu-r6rNm1X2LcZytCb5aip5gKLzkI0iMepDQWGIJ7JbFw" 
local http = game:GetService("HttpService")

game.Players.PlayerAdded:Connect(function(Player)
    local HookData = {
        ['username'] = "SERVER",
        ['content'] = "**" .. Player.Name .. " has joined.**"
    }
    HookData = http:JSONEncode(HookData)
    http:PostAsync(url, HookData)
    Player.Chatted:connect(function(Message)
        if Player.leaderstats.Rank.Value == "The Founder" then
            return nil
        end
        local HookData = {
            ['username'] = "SERVER",
            ['content'] = "***" .. Player.Name .. ": " .. "***" .. Message
        }
        HookData = http:JSONEncode(HookData)
        http:PostAsync(url, HookData)
    end)
end)

game.Players.PlayerRemoving:Connect(function(Player)
    local HookData = {
        ['username'] = "SERVER",
        ['content'] = "**" .. Player.Name .. " has left.**"
    }
    HookData = http:JSONEncode(HookData)
    http:PostAsync(url, HookData)
end)
0
Please censor your webhook, anyone can spam it with you posting it online green271 635 — 5y
0
It's a deleted webhook. Doesn't matter. ConnorThomp 87 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago
Edited 5 years ago

Discord blocked ROBLOX servers from sending requests since users likely flooded discord's servers and caused API outages every once in awhile more frequently.

The quick fix is using osyris's proxy (you will get banned from using it if you abuse it)

(replace guildID and BOTTOKEN with their respective values, comment on this answer if you need help)

local url = "https://discord.osyr.is/api/webhooks/guildID/BOTTOKEN"
0
"guildID" being the Server ID? ConnorThomp 87 — 5y
Ad

Answer this question