This repository has been archived by the owner on Jun 1, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Schema challengeoverview
thomaskipar edited this page Dec 28, 2012
·
4 revisions
Get List of Current and past challenges
rest/challenges
- token
- onlyRunning = true/false (optional, default = false)
{
"type": "array",
"$schema": "http://json-schema.org/draft-03/schema",
"items": {
"type": "object",
"properties": {
"challengeDuration": {
"type": "string",
"required": true
},
"challengeFinished": {
"type": "string",
"required": true
},
"challengeId": {
"type": "string",
"required": true
},
"challengeImage": {
"type": "string",
"required": true
},
"challengeType": {
"type": "string",
"required": true
},
"startDate": {
"type": "string",
"required": true
},
"team1": {
"type": "array",
"required": true,
"items": {
"type": "object",
"required": true,
"properties": {
"amount": {
"type": "number",
"required": true
},
"userImage": {
"type": "string",
"required": true
},
"userName": {
"type": "string",
"required": true
},
"userId": {
"type": "string",
"required": true
},
"won": {
"type": "string",
"required": true
}
}
}
},
"team2": {
"type": "array",
"required": true,
"items": {
"type": "object",
"required": true,
"properties": {
"amount": {
"type": "number",
"required": true
},
"userImage": {
"type": "string",
"required": true
},
"userName": {
"type": "string",
"required": true
},
"userId": {
"type": "string",
"required": true
},
"won": {
"type": "string",
"required": true
}
}
}
}
}
}
}
[
{
"challengeType": "1v1",
"challengeDuration": "30",
"startDate": "1346459019",
"challengeId": "9",
"challengeFinished": "1",
"challengeImage": "images/others/1v1.jpg",
"team1": [
{
"userId": "6",
"userName": "Thomas",
"userImage": "images/avatars/43981527934208.jpg",
"amount": 0.41851239669421,
"won": "1"
}
],
"team2": [
{
"userId": "2",
"userName": "Winni",
"userImage": "images/avatars/43981527934208.jpg",
"amount": 0.32851239669421,
"won": "0"
}
]
}
]