Version 2.0 Web API Released!

Today I have completed version two of my Web API which has been designed to make web requests much easier. Over the summer I suffered an issue where my host unfortunately had one of its servers lost a lot of users websites, so I put it back together in version one. Version one is still supported as of today, but I will say that anybody who uses my API (and I know a lot of you do since I track places/people using it.) that you should move over to version two.

The API is located here.

The API works by using a module which you require from in-game scripts, the new module has an ID of 197534978 and can be found here, the reason that the module is not public is so that I can forcefully pass across the PlaceId and CreatorId meaning I can block users who do attempt to abuse the system.

In version two, the main change is in this module. The new module allows you to write much cleaner and nicer looking code. The Get prefix has been moved to go in-front of the method you are using, instead of being a parameter. Post requests are executed by having no prefix in-front of the method. Also, in version one, you used to have to create a table of the url/post parameters, this has been removed and instead you can just have them as direct parameters to the function. Here is a comparison of the old code versus the new code.

Old Code:

local api = require(187548589)
data = api:Search("GET", {category=1, page=1, query="ROBLOX", sort=1})

New Code:

local webAPI = require(197534978)
data = webAPI:GetSearch(category, page, query, sort)

Luckily, this module is fairly easy to switch to, it doesn’t directly support the old code, but does still accept a table as a parameter. All you need to do is transfer the Get prefix to the front of the method.

If you’re having trouble, you can click the generate script button to generate an example of the code in Lua.

If you have any particular requests you want me to add, I can do so.

http://apiroblox.netne.net/

1 Like