Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

Commit 9a8325b

Browse files
committed
Add Track Statistics API
1 parent e52997d commit 9a8325b

File tree

1 file changed

+51
-0
lines changed

1 file changed

+51
-0
lines changed

apiary.apib

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -355,6 +355,57 @@ Report APIs
355355
"description":"Unknown server error. Please contact support."
356356
}
357357

358+
+ Response 503 (application/json)
359+
360+
{
361+
"name":"Service Unavailable",
362+
"value":"503",
363+
"description":"Servers are up but overloaded. Try again later."
364+
}
365+
366+
## Track Statistics [/reports/{track}?startDate={startDate}&endDate={endDate}]
367+
### Track Statistics [GET]
368+
369+
+ Parameters
370+
+ track (required, string, `design`) ... Track Name. Only allow "Design", "Develop" and "Data"
371+
+ startDate (optional, string, `2013-01-01`) ... timespan start date
372+
+ endDate (optional, string, `2014-01-01`) ... timespan end date
373+
374+
+ Response 200 (application/json)
375+
376+
{
377+
"numberOfRunningChallenges": 10,
378+
"totalPrizeOfRunningChallenges": 13500,
379+
"totalPrizeInGivenTime": 120000,
380+
"numberOfChallengesInGivenTime": 100,
381+
"numberOfRegisteredUsers": 90,
382+
"numberOfActiveUsers": 50
383+
}
384+
385+
+ Response 400 (application/json)
386+
387+
{
388+
"name":"Bad Request",
389+
"value":"400",
390+
"description":"This message will explain why the request is invalid or cannot be served."
391+
}
392+
393+
+ Response 404 (application/json)
394+
395+
{
396+
"name":"Not Found",
397+
"value":"404",
398+
"description":"This message will explain why the URI requested is invalid or the resource does not exist."
399+
}
400+
401+
+ Response 500 (application/json)
402+
403+
{
404+
"name":"Internal Server Error",
405+
"value":"500",
406+
"description":"Unknown server error. Please contact support."
407+
}
408+
358409
+ Response 503 (application/json)
359410

360411
{

0 commit comments

Comments
 (0)