#I tried to make a chat logs system with webhook

106 messages · Page 1 of 1 (latest)

glossy juniper
#

But it didnt work

#

local URL = "https://hooks.hyra.io/api/webhooks/"
local Players = game:GetService("Players")
local HttpService = game:GetService("HttpService")

local function postMessage(player, index)
    local teamValue
    pcall(function()
        if not player.Team then
            teamValue = "-"
        else
            teamValue = player.Team.Name
        end
    end)
    
    local data = {
        
        ["content"] = "";
        ["embeds"] = {{
            ["author"] = {
                ["name"] = player.Name;
                ["icon_url"] = "https://www.roblox.com/headshot-thumbnail/image?userId="..player.UserId.."&width=150&height=150&format=png"
            };
            
            ["description"] = "Message: **"..index.."**",
            ["color"] = tonumber(0xffffff);
            ["fields"] = {
                {
                    ["name"] = "User ID";
                    ["value"] = player.UserId;
                    ["inline"] = true;
                    
                };
                {
                    ["name"] = "Account Age";
                    ["value"] = player.AccountAge.."days";
                    ["inline"] = true;
                };
                {
                    ["name"] = "Team";
                    ["value"] = teamValue;
                    ["inline"] = true;
                };
                
            };
            ["footer"] = {
                ["icon_url"] = "";
                ["text"] = "Programmed by madmonkeyfoot";
            }
        }}    
    }
    local finalizedData = HttpService:JSONEncode(data)
    HttpService:PostAsync(URL, finalizedData)
end

local function PlayerAdded(Player)
    Players.Chatted:Connect(function(Message)
        postMessage(Player, Message)
    end)
end

for _, Player in ipairs(Players:GetPlayers()) do
    PlayerAdded(Player)
end

Players.PlayerAdded:Connect(PlayerAdded)
indigo ore
#

the proxy could also be down

#

make sure you put the other webhook info in correctly next to the link as well

glossy juniper
#

its working in studio

#

but not working in-game

#

@indigo ore

#

http request is on

indigo ore
#

roblox must have blocked it then

glossy juniper
#
local URL = "https://discord.com/api/webhooks/"
local Players = game:GetService("Players")
local HttpService = game:GetService("HttpService")

local function postMessage(player, index)
    local teamValue
    pcall(function()
        if not player.Team then
            teamValue = "-"
        else
            teamValue = player.Team.Name
        end
    end)
    local data = {
        ["content"] = "";
        ["embeds"] = {{
            ["author"] = {
                ["name"] = player.Name;
                ["icon_url"] = "https://www.roblox.com/headshot-thumbnail/image?userId="..player.UserId.."&width=150&height=150&format=png"
            };
            ["description"] = "Message: **"..index.."**",
            ["color"] = tonumber(0xffffff);
            ["fields"] = {
                {
                    ["name"] = "User ID";
                    ["value"] = player.UserId;
                    ["inline"] = true;
                };
                {
                    ["name"] = "Account Age";
                    ["value"] = player.AccountAge.." days";
                    ["inline"] = true;
                };
                {
                    ["name"] = "Team";
                    ["value"] = teamValue;
                    ["inline"] = true;
                };
            };
            ["footer"] = {
                ["icon_url"] = "";
                ["text"] = "Area Zero" 
            }
        }}
    }
    local finalizedData = HttpService:JSONEncode(data)
    HttpService:PostAsync(URL, finalizedData)
end

local function PlayerAdded(Player)
    Player.Chatted:Connect(function(Message)
        postMessage(Player, Message)
    end)
end

for _, Player in ipairs(Players:GetPlayers()) do
    PlayerAdded(Player)
end

Players.PlayerAdded:Connect(PlayerAdded)

I changed it with that ^^

indigo ore
#

did you publish with the proxy?

#

;-;

glossy juniper
#

wdym proxy

indigo ore
#

Roblox banned discord webhooks

#

so you need to use the proxy

glossy juniper
#

how

#

help me

indigo ore
#

just go to the proxy page my guy

glossy juniper
#

alr

indigo ore
#

if u scroll down

maiden wadiBOT
#

studio** You are now Level 19! **studio

indigo ore
#

there is a conversion thing

glossy juniper
#

Oh damn

#

thanks bro

#

wait lemme try

indigo ore
#

these proxies always have the most sus links ever i swear

glossy juniper
#

ok

#

@indigo orei changed script to first one i sent in here

#

and put that proxy in it

#

and published

#

now joining game

indigo ore
#

did work?

glossy juniper
#

we will see

indigo ore
#

now these proxies sometimes go down so

glossy juniper
#

oh

#

alr

indigo ore
#

good to have multiple id say

#

there is a way to detect if it's down but i forgor

glossy juniper
#

didnt work

#

@indigo ore

indigo ore
#

did you change the link correctly

#

stop pinging me

glossy juniper
#

yes i did

indigo ore
#

make the game public not private

glossy juniper
#

its public

indigo ore
#

then you didn't put the proxy in correctly

glossy juniper
#

i did

#

look

#

i didnt took all of webhook's ss

indigo ore
#

remove api

glossy juniper
#

wdym api

#

how to remove api*

indigo ore
#

;-;

#

the link

glossy juniper
#

oh

#

in it

indigo ore
#

make sure to remove the extra "/" to

glossy juniper
#

ok did

#

yep

indigo ore
#

ok

#

now test

#

and

#

delete that image

#

it is giving away ur link

glossy juniper
#

damn

#

alr

#

no problem

#

i can change webhook

#

so its ok

indigo ore
#

ok

glossy juniper
#

i accidently closed studio but its opening rn

#

i will test

#

shall i test in studio or in game

indigo ore
#

only studio

#

well

#

ig both

glossy juniper
#

alr

#

Gave me that error

#

@indigo ore

indigo ore
#

hm

#

let me test give seec

#

ok

#

turns out

#

i had wrong error

#

the script wont work

#

bc of a typo

#
local function PlayerAdded(Player)
    Players.Chatted:Connect(function(Message)
        postMessage(Player, Message)
    end)
end
#

this function here

#

Remove the "s" from "Players"

#

oh and

#

add "api" back to the link

#

@glossy juniper

high raven
#

discord robloxtan webhook https isteklerini blokladı artık webhook kullanamassın roblox üzeründen

#

belki eğer bir discord botu hostlayıp ona gönderirsen o çalışır başka bir yolu yok

#

yada proxy ayarlayabilirsin

vernal pelican
#

i dont believe the url

"https://www.roblox.com/headshot-thumbnail/image?userId="..player.UserId.."&width=150&height=150&format=png"

works anymore

#

it used to, but now it sends nothing in webhooks

#

all my webhooks that have been sent in my server have been nullified as a result of the change

#

so you would need two proxies, one for the webhook itself, and one to get the headshot thumbnail. i know a few webhook proxies, however i am unaware of any alternatives for headshot thumbnail

glossy juniper
glossy juniper
high raven