Unofficial Splinterlands API Documentation
One thing that makes Splinterlands such a great game is the environment that exists around it. There's a whole ecosystem of tools and websites that you can use to enhance your Splinterlands experience. Just to name a few: Splintertalk, Peakmonsters, Monster Market, Splintercards, Reward Cards Stats, etc ...
Next up, you need a way to communicate with the game. This is usually done through an API (Application Programming Interface). This allows a 3th party tool to request and send data to Splinterlands. In the case of Splinterlands, it's also possible to directly extract data from the Hive Blockchain. Now, for most other games or services that provide an API, they also have extensive documentation as to how you can use the API. That must also be the case for Splinterlands, right?
Alas, no. It's nowhere to be found. That's a bummer, because without any documentation it's really hard to figure out how to get things done. After doing some research I found a user who had compilied some information 2 years ago in a Google Sheets and about 1 year ago @Kiokizz bundled some information on Github. That's it. Offcourse, there's also a helpfull channel for developers on the Splinterlands Discord, but information does get lost get quickly in there.
Another possibility is to use the developer tools in your browser to look at what API calls Splinterlands itself and other 3th party websites like Peakmonsters are making. By looking at those websites you can allready learn a lot about how the API works.
Well, let me tell you. I've been through all of this pain and do not wish it upon anyone else. Therefore I've decided to bundle all of the Splinterlands API information that I found in one central place, which can be found here: https://splinterviewer.com/api. For this, I used the Github by Kiokizz as the basis and updated things that are no longer working and added a lot of new stuff as well.
On this website I will try to keep a record of the Unofficial Splinterlands API Documentation, so that developers have an easy one-stop shop for everything related to Splinterlands development. Right now, this documentation is allready a lot more extensive than anything else out there, but I'm still looking to improve it. So if you have any recommendations for the website, don't hesitate to reach out.
The documentation contains an overview of all API endpoints and what JSON response you can expect. This data can be used to build your own tools. In the future I might consider adding some simple tutorials as well.
If this is a project that you would like to support, feel free to donate.
I'm also tagging the lovely people over at @monster-curator (@flauwy, @abrockman, @marianaemilia, @r1s2g3, @homesteadhacker, @RosieW and @CandyRain), so hopefully this documentation can get some attention. That would certainly help a lot of aspiring Splinterlands developers leading to new tools for everyone. I think that's a cause we can all stand behind!
So feel free to head over to https://splinterviewer.com/api and have a look.