Hackathon Entry - Cartographer API [CAPI]

Application/Web Site title: Cartographer API [CAPI]
Description:

The Cartographer API is an extension of the Halo API. The Halo API currently only gives data based on Players and Games, so the Cartographer API seeks to give data based on Maps, Gametypes, and Forgers. It does this by storing all of the game details for every custom game that it can find in Halo 5. And then when it has those details it generates materialized views to be queried later. So when a game comes in, we tie it to the respective map, and then we can query for a Map ID and find out what games have been played on that map. With that list we can go forth and get more data like all of the weapon statistics for each of those games, or all of the events for each of those games. So Forgers will be able to get a list of every game that has been played on their maps.

CAPI is blocked out by an API key. I’m providing a key for people to play with the endpoints. CAPI will only know about maps and games that it has been given. The system is built to incrementally add data over time so it will get more and more accurate as it discovers new games by adding new players to the system. In the future it will also discover new players by seeing what players have played in each of the games it has in its system. At this current moment I’ve only added 10 player’s games to the system, but this has resulted in XXXXX games added and we can give CAPI a map ID and find out which of those games have been played on that map.

Here is a temporary API key to play with CAPI. I will be removing it on June 15th. And for 343 I’ll be sending a 343 only API key that won’t expire in the respective email for the contest submission. NOTE:Add the API key to the headers with the header of x-api-key. POST endpoints MUST include a Content-Type header with application/json.

Hackathon Temporary API Key: QxQw8w0Yor5dx6HUGpyUj9PRbJyYJtFu9yNIp5lh

URL (if applicable):https://api.cartographer-api.com/
Screenshot links: http://imgur.com/a/15p9a
Gamertag: Ray Benefield


NOTE: CAPI is currently in ALPHA so expect breaking changes over the next month or so, while I work towards a Beta, and eventually release.

This isn’t your standard application Hackathon entry, but it is something I had started working on before the Hackathon was announced, so I used the Hackathon as a deadline for the MVP. :wink: The reason I’ve built an API is to ensure that any of the Halo communities can tap into the data that CAPI provides rather than keeping it in one place. Eventually going to a map on Forge.World or Forgehub will yield many map details for visitors, like how often the map has been tested, how many players have tested it, how often it is played, etc. With this functionality we’ll also be able to do crazy things like verify whether or not a player has played on a map before they gave a review on it to do the equivalent of Amazon’s “Verified Purchaser”. And in the future people will also be able to generate heatmaps for their custom maps… an application can pull a list of MatchIDs for a given Map from CAPI and use that to query all of the events that have happened on that map and generate awesome heatmaps and statistics for custom maps as a whole rather than just individual matches.

Architecturally CAPI runs a Serverless Nanoservices Architecture based on batch data processing. It is built with Java and is backed by a NoSQL database in Dynamo. The entire ecosystem is in AWS using some of the latest services and tech available. I’ve also been live streaming most of my coding for CAPI and plan to continue doing it for anyone interested in keeping up with CAPI’s development and getting a little deeper. The project is open sourced and I plan on bringing in others to help with the feature development and teaching people some high level architecture in the process.

Open Sourced Repository: https://bitbucket.org/RayBenefield/cartographer-api
LiveCoding.tv Stream: https://www.livecoding.tv/godlyperfection/
Twitter: https://twitter.com/RayBenefield

Here are the current endpoints in CAPI (I’ll be working on my API documentation over the next week or so):

> GET https://api.cartographer-api.com/game/{{matchId}}/event
> POST https://api.cartographer-api.com/game/event
>
>
> Get metadata related to a game’s events. Right now it just provides the count of events for a given game. The POST endpoint is the bulk version which accepts an array of MatchIds.
>
> Sample IDs: [ “8752d94d-39ab-4b40-8484-4c3b0ef63157”, “71e1f6a4-1bda-43c7-8d0a-8c3eab0da9a7”, “36baa3f8-7451-4e23-8647-33a3b9023d23” ]
>
> ----------
>
> GET https://api.cartographer-api.com/game/{{matchId}}
>
> POST https://api.cartographer-api.com/game
>
>
> Get bare data for a given game. This currently only includes its MatchID, but I’ll be adding data like the map ID, gametype ID, number of players, number of teams, date completed, and anything else I can think of over time. The POST endpoint is the bulk version which accepts an array of MatchIds.
>
> Sample IDs: [ “7a355215-2f3b-49dc-a22e-06cee590ac8d”, “c7282b0f-c0f5-4929-9101-6bff892447e7”, “36baa3f8-7451-4e23-8647-33a3b9023d23” ]
>
> ----------
>
> GET https://api.cartographer-api.com/map/{{mapId}}/game
>
> POST https://api.cartographer-api.com/map/game
>
>
> Get the games that have been played on the given MapID. This is the core purpose of CAPI. Given a single map ID CAPI will return every game ever played on that map. The POST endpoint is the bulk version which accepts an array of MapIds.
>
> Sample IDs: [ “6915eb85-eb03-4971-88e4-50fdec95b768”, “9bd908fc-4dfa-4ffe-859b-7d28e4147302”, “a7cbc97b-ce5e-42b9-ab6d-52987deda1fb” ]
>
> ----------
>
> GET https://api.cartographer-api.com/player/{{player}}/game/count
>
> POST https://api.cartographer-api.com/player/game/count
>
> Get the counts of the games played by a player. CAPI only tracks custom games. And the Service Record only returns completed games, this endpoint includes TotalGames which is how many games you can get from the matches endpoint for that player. The POST endpoint is the bulk version which accepts an array of Gamertags.
>
> Sample Gamertags: [ “randy 355”, “ray benefield”, “mythicfritz” ]
>
> ----------
>
> GET https://api.cartographer-api.com/player/{{player}}/game/
>
> POST https://api.cartographer-api.com/player/game/
>
>
> Get the summary of all of the games played by a player. Similar to the Matches endpoint, except it returns ALL of the games with a GameNumber tied to it based on chronological play. The POST endpoint is the bulk version which accepts an array of Gamertags.
>
> Sample Gamertags: [ “randy 355”, “ray benefield”, “mythicfritz” ]

Solid work man, I know you’ve put a lot of effort into this and it’s good to see it paying off! Can’t wait to write some applications that use your API. Fantastic stuff.

Awesome work Ray! It’s awesome to see you so close to completing the majority of your original goals, and I can’t wait to see where you go next with this project!

Proud of you dude! This was one heavy task and I believe you did an amazing job with it. Can’t wait to see what becomes of this.

keep it rocking ray, glad to see you get this out there. Cant wait to see it finally in full use!

Awesome work man! This will be a big benefit for the community. Now reward yourself with a little sleep!

Thanks for the awesome support guys. I’ll be adding more raw data and expanding the domain objects returned in the endpoints to make them actually more useful.

I’ve also written an article over at LinkedIn about my decision to go Serverless and with Nanoservices for CAPI: https://www.linkedin.com/pulse/how-i-decided-use-serverlessnanoservices-architecture-benefield