Challenge ranking
This service returns the list of all the users registered to the challenge, along with their rankings and ranking details (i.e., number of trips and total distance driven during the challenge).
If the challenge has not yet started, the service will return a HTTP 204 (no body) response, along with a Retry-After
header containing the date at which the response will be available:
The usersRanked
list contains the list of all registered users who have met the requirements for the challenge. These users have a rank, and a score.
The usersNotRanked
list contains the list of registered users who have not yet met the requirements, but who might already have started accumulating challenge data. The users do not have a score yet, but their number of trips and distance driven are returned in order to evaluate their progress.
If the challenge only concerns a specific group (or groups), then the service also accepts a group
request parameter to retrieve the rankings for a single group. If no value is provided, then the global ranking is returned.
If you have your admin API key, you can try the API via this link.
Response
The table below summarizes the elements included in the ChallengeRankingsResponse
object.
Field | Type | Description |
---|---|---|
challengeId |
| Unique identifier of the challenge |
group |
| If present, indicates that the rankings are specific for this group label |
conditions | Conditions that need to be filled for a user to be ranked | |
registeredUsers |
| Total number of users registered to the challenge |
rankedUsers |
| Total number of users ranked in the challenge |
totalDistance |
| Total distance driven by the users for the challenge |
totalNumberTrips |
| Total number of trips made by the users for the challenge |
usersNotRanked |
| List of users not ranked in the challenge (see UserNotRanked) |
usersRanked |
| List of users ranked in the challenge (see UserRanked) |
ChallengeConditions
The table below summarizes the elements included in the ChallengeConditions
object.
Field | Type | Description |
---|---|---|
km |
| Minimum distance required to be ranked (in km) |
nbTrip |
| Minimum number of trips required to be ranked |
UserNotRanked
The table below summarizes the elements included in the UserNotRanked
object.
Field | Type | Description |
---|---|---|
username |
| Unique identifier of the user |
firstname |
| First name of the user |
lastname |
| Last name of the user |
registerDate |
| Date at which the user entered the challenge
Date format: |
numberTrips |
| Number of trips since the user registered to the challenge |
distance |
| Distance since the user registered to the challenge |
UserRanked
The table below summarizes the elements included in the UserRanked
object.
Field | Type | Description |
---|---|---|
username |
| Unique identifier of the user |
firstname |
| First name of the user |
lastname |
| Last name of the user |
registerDate |
| Date at which the user entered the challenge
Date format: |
numberTrips |
| Number of trips since the user registered to the challenge |
distance |
| Distance since the user registered to the challenge |
rank |
| Current rank of the user |
score |
| Score of the user during the challenge |
Last updated