TheGamDevStore.com Online API

TGDSO Formats

TGDSO Formats

JSON

If no format is specified or not recognized, data is returned in this format by default.

Outputs data as a JSON string.

Example

{
  "response":
  {
    "success":"true",
    "trophies":
    [
      {
        "id":"3",
        "title":"Cookie Magnet",
        "description":"Eat 10 points worth of cookies."
      },
      {
        "id":"4",
        "title":"I like this job!",
        "description":"Eat 20 points worth of cookies."
      }
    ]
  }
}

TGDSO JSON

TGDSO JSON is our own flavor of JSON. The main difference is Key names. Key names only use Alphanumeric and Underscore Characters. Key names don’t require quotes. A Datatype can be optionally defined in front of the Key name. All data is assumed to be of the String Datatype by default.

Outputs data as a JSON string.

Example

{
  blob response:
  {
    bool success:"true",
    arr trophies:
    [
      {
        int ID:"3",
        title:"Cookie Magnet",
        description:"Eat 10 points worth of cookies."
      },
      {
        int ID:"4",
        title:"I like this job!",
        description:"Eat 20 points worth of cookies."
      }
    ]
  }
}

XML

Outputs data as an XML string.

Example

<?xml version="1.0" encoding="UTF-8"?>
<response>
  <success>
    <![CDATA[true]]>
  </success>
  <trophies>
    <trophy>
      <id>3</id>
      <title><![CDATA[Cookie Magnet]]></title>
      <description><![CDATA[Eat 10 points worth of cookies.]]></description>
    </trophy>
    <trophy>
      <id>4</id>
      <title><![CDATA[I like this job!]]></title>
      <description><![CDATA[Eat 20 points worth of cookies.]]></description>
    </trophy>
  </trophies>
</response>

Key|Value Pair

The key is the plain text of the key. The value is a double-quoted string with inside double-quotes escaped with a backslash.

The keys are separated from the values by a colon (:).

Each key/value pair is on a new line.

Example

success:"true"
id:"3"
title:"Cookie Magnet"
description:"Eat 10 points worth of cookies."
difficulty:"Bronze"
image_url:"https://localhost:8080/ArcadeKomodo/data/games/18/trophies/3_8.jpg"
achieved:"1 month ago"
id:"4"
title:"I like this job!"
description:"Eat 20 points worth of \"cookies\"."
difficulty:"Bronze"
image_url:"https://localhost:8080/ArcadeKomodo/img/trophy-bronze-1.jpg"
achieved:"false"

TournamentBlitz

The TournamentBlitz was the very API developed for Tournament Game Management. TournamentBlitz provides Key and Value separated by carriage return. No Quotes are required for Values. The Client would expect data to be presented in specified order.

Example

success
true
Item
id
3
title
Cookie Magnet
description
Eat 10 points worth of cookies.
difficulty
Bronze
image_url
ArcadeKomodo.com/data/games/18/trophies/3_8.jpg
achieved
1 month ago
Item
id
4
title
I like this job!
description
Eat 20 points worth of \"cookies\".
difficulty:
Bronze
image_url
ArcadeKomodo.com/Achievements/img/gold-1.jpg
achieved
false

RAW

This is a special format used when a certain function has to output a single chunk of data.

The first line says whether or not the request has succeeded. Any lines after that is the actual data (or a message on failure).

Example

SUCCESS
data goes here
Blah, more data
sdfsdf

Failure Example

FAILURE
The game ID you passed in does not point to a valid game.

Submit a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Pin It on Pinterest