AccueilDocumentation API Rest

GET tournament/:tournament/competitions/:competition_id

Renvoie la totalité des informations d'un match.

URL du service

http://api.tournikoti.com/tournament/:tournament/competitions/:competition_id.format

Paramètres

tournament

requis

Identifiant unique du tournoi sous forme d'une chaîne de caractère basée sur le nom du tournoi.

Exemple de valeur : my-tournament

competition_id

optionnel

Identifiant du match.

Exemple de valeur : 789

Exemple de requête

GET http://api.tournikoti.com/tournament/my-tournament/competitions/789.json
{
  "competition":
  {
    "id": 789,
    "group_id": 5678,
    "started_at": "2012-04-06 08:30:00",
    "location": "Terrain A",
    "participants": [
      {
        "competitor_id": 1234,
        "competitor": {
          "id": 1234,
          "name": "John Smith",
          "tags": [
            { "name": "runner" },
            { "name": "boy" },
            { "name": "adult" }
          ],
          "color": "eb3737",
          "level": 1,
          "lft": 2,
          "rgt": 7,
          "created_at": "2012-03-07 10:38:23",
          "updated_at": "2012-03-07 10:38:23"
        },
        "winner": false,
        "result": null,
        "created_at": "2012-03-07 10:38:23",
        "updated_at": "2012-03-07 10:38:23"
      },
      {
        "competitor_id": 1237,
        "competitor": {
          "id": 1237,
          "name": "Wendy O'Brien",
          "tags": [
            { "name": "runner" },
            { "name": "girl" },
            { "name": "adult" }
          ],
          "color": "53dfd9",
          "level": 1,
          "lft": 8,
          "rgt": 9,
          "created_at": "2012-03-07 10:39:29",
          "updated_at": "2012-03-07 10:40:29"
        },
        "winner": false,
        "result": null,
        "created_at": "2012-03-07 10:38:23",
        "updated_at": "2012-03-07 10:38:23"
      }
    ],
    "result": null,
    "has_result": false,
    "created_at": "2012-03-07 10:38:23",
    "updated_at": "2012-03-07 10:38:23"
  },
  "status": 200,
  "message": "ok"
}

Informations du service

Authentification requise ? Oui
Format de réponse json
Méthode HTTP GET