AQ Hub is a API dedicated to AdventureQuest Worlds (AQW). Its main goal is to serve as a wiki-style resource for the game, providing structured and easy-to-access information for players.
Basically, we run a number of scrapers across the wiki, official char pages, and in-game sources. This multi-source process is how we ensure our item data is accurate and dependable.
The flow is pretty simple; we just need the player name to start this process:
- Player Name
- Find the player's CCID on the AQW Charpage
- Call the player's inventory API using the CCID
- Scrape the data for each item from the AQWiki
Easy enough, right?
Basically, if I have access to all player names and all items in the game are in their inventories, I will have all the item data.
But how can I get player names easily?
To achieve this, I first needed to study how the game client connects to its servers. Using this knowledge, I built a library dayvsonspacca/aqw-socket-client that allows connection to an AQW server via PHP. Once connected, I receive logs detailing what players are doing on my screen. This is the BOOM! moment: I simply need to keep an account logged in to continuously capture and save the names, and with those names, I can get the items!
While this is clearly the most complex method, it's just a lot cooler.