Help with HttpService

oh ok thanks! also for some reason it prints this
image

this is the code

local HTTPService = game:GetService("HttpService")
local access_token = "key"
local url = "https://api.genius.com/search?access_token="..access_token.."&q="
local getsong = "https://synitx.glitch.me/api/genius/%s/%s"

game.ReplicatedStorage.GetLyrics.OnServerEvent:Connect(function(plr,songname)
	local name = string.gsub(songname," ","%%20")
	local response = HTTPService:JSONDecode(HTTPService:GetAsync(url..name)).response.hits[1] -- herei i get the id
	local releasedate = response.result.release_date_for_display
	local id = response.result.id
	game.ReplicatedStorage.SendLyrics:FireClient(plr,releasedate)
	local suc,res = pcall(function()
		return HTTPService:GetAsync(url:format(id,access_token))
	end)
	if suc and res then
		local res2 = HTTPService:JSONDecode(res)
		print(res2,id)
	end
end)

1 Like

oh… LMAO i am kinda wobbly rn idk why. feel drunk fsr

1 Like

YOOOOOOO it works!!! thank you soo much bro this really helps me!

1 Like