Replay API

Note: the contents or subject of this page may change dramatically without warning in the future

Given a match's replay code, you can access all the stored data about that Prismata match, including players, winner, units, time controls, and more.

To access the replay data, access the following URL, replacing  with the replay code of the match. Special character  will need to replaced by.

http://saved-games-alpha.s3-website-us-east-1.amazonaws.com/REPLA-YCODE.json.gz

The page will return a gzipped JSON file called. Sample JSON can be viewed here.

Replay Codes
The regex  exactly matches valid replay codes. This does not mean the given replay actually exists; you'll need to examine the response from the URL above to determine that. All valid replay codes will match that regex, though. Check it out here.

Units
The units available for purchase in a game are in the  array under the top-level   hash.

Nivo Charge unit information {   "targetAmount": 5, "toughness": 1, "name": "Volatile Blast", "assignedBlocking": 0, "lifespan": 1, "defaultBlocking": 0, "buyCost": "2G", "score": "0", "targetAction": "disrupt", "abilityScript": { "selfsac": true },   "rarity": "normal", "UIName": "Nivo Charge" },

Terminology
Some of the terminology used in the JSON reflects the history of Prismata, and are not the terms we use today. The most noticeable perhaps is the name of the units; they are universally referred to by their "name" attribute apart from their entry in the "mergedDeck" array, which you can use to pair them up to their better known "UIName".

Game results

Game end conditions