Part of imacodr OSS Pack
fetchu (You are here!) • rss • Roarn
[Documentation] | [ Source Code]
Inspired by Node.js’ node-fetch. fetchu is a lightweight module created to simplify Roblox’s HttpService for faster and efficient requests. Our goal is to minimize all the work you do for one request in a single line of code.
Using a tool like fetchu can simplify all Http requests out of Roblox to a single line of code while fetchu handles all errors. Its as easy as doing this:
local fetchu = require(path/to/fetchu)
local response = fetchu.get("https://pokeapi.co/api/v2/pokemon?limit=1", {headers = {
["Authorization"] = "my token for authorization!"
}, nocache = true})
print(response)
--[[
Returns:
{"count":1118,"next":"https://pokeapi.co/api/v2/pokemon?offset=1&limit=1","previous":null,"name":"bulbasaur","url":"https://pokeapi.co/api/v2/pokemon/1/"}
--]]
with Roarn
To install fetchu with Roarn you can simply do the following command:
roarn install fetchu
Learn more on how Roarn, a Roblox package manager helps your workspace.
with Wally
Add this line to your wally.toml
fetchu = "imacodr/fetchu@1.0.3"
with Roblox
If you are preferably using Roblox Studio to develop code you can also install our module through the Roblox marketplace.
with GitHub
You can also install our package from GitHub releases easily. We have ZIP files available for Rojo users although we would prefer you using Roarn for a more organized workspace.
Questions?
If you have any questions on how fetchu works, please reply on this post! I’ll be answering all questions here.
If you have more concerns or need help with fetchu we have community servers!
Made with by imacodr