> For the complete documentation index, see [llms.txt](https://docs.racemap.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.racemap.com/api/ranks.md). Agents can also search and read this documentation through its [MCP server](https://docs.racemap.com/~gitbook/mcp).

# \*/ranks, ranking and results

API with live ranking and results corresponding to splits and calculations in the leaderboard

Read all about the data processing in the leaderboard:

{% content-ref url="/pages/-LYXfT2qbHHP6XDl9-g6" %}
[Leaderboard](https://docs.racemap.com/live-tracking/gps-timing.md)
{% endcontent-ref %}

**Live sample** <https://racemap.com/api/data/v1/61a21210e5d45d000199f7d9/ranks>\
corresponding leaderboard <https://racemap.com/timing/100KmDuathlon2018_Repeat>

**Past sample** <https://racemap.com/api/data/v1/60a3b443f096f800018add7c/ranks>\
corresponding leaderboard <https://racemap.com/timing/sample-event-100km-duathlon_2020>

### Reference

### Ranking target

The leaderboard's timing setting decides how participants are ranked.

* **Distance target:** ranked by the time needed for the distance. `progress` is a distance in meters. Results are durations in milliseconds (`type: "duration"`).
* **Duration target:** ranked by the distance covered in the duration. `progress` is a duration in milliseconds. Results are distances in meters (`type: "distance"`).
* Without at least two timekeeping splits, RACEMAP generates virtual splits along the course or the duration. They have stable ids, and intermediate ones have no name.
* `results` has one entry per split in `timekeepings`, in the same order. A split without result is `null`.
* `startSource` tells where the start time comes from: `UPLOADED` (imported times), `DETECTED` (from the geolocations) or `GUN` (mass start at the event start time).

### Ranks and divisions

* `rank` is the overall rank. Participants with the state `DNS`, `DNF` or `DSQ` are not ranked and get `-1`.
* `ranks` lists the rankings of a participant: always an `elapsed` and an `absolute` ranking, and division rankings on demand.
* **Elapsed:** ranks participants by who covered the greatest distance in the shortest amount of time. This is also referred to as *net time*.
* **Absolute:** ranks participants by the total distance covered at the current moment.
* Add `divisions` with up to two [tags](https://docs.racemap.com/api-import-and-export-data/import-basics/metadata-api.md#format-of-import-data), e.g. `?divisions=sex,nationality`. Participants are also ranked within each tag value and each combination of both tags.
* `starters` limits the response to the given participant ids. `rank` still refers to all participants, `ranks` only to the returned ones.

{% hint style="info" %}
A call counts as a [load](https://docs.racemap.com/glossary.md#load) only without `starters` and `from`. The `from` parameter is reserved for RACEMAP's own leaderboard and app.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.racemap.com/api/ranks.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
