# Scores

## Description

Scores are used to rank players against one another. Scores are generated automatically for standard leaderboards whenever achievements with points are earned. Scores are to be submitted manually for custom leaderboards. When a leaderboard ranking is requested, a score is a simple number. A score is unique to a player, leaderboard, and time span.

Once a score is submitted for a custom leaderboard, r4nkt will make sure that it is represented for each time span. If a player already has a score for a leaderboard and time-span combination, then r4nkt will determine whether or not the new score is better. If so, then it will be updated. If not, then it will be ignored. You will be informed of the time spans for which the submitted score was an improvement.

## Properties

When submitting a score for a custom leaderboard, it can have following properties:

| Name                    |   Type  | Default |
| ----------------------- | :-----: | :-----: |
| custom\_leaderboard\_id |  string |    -    |
| custom\_player\_id      |  string |    -    |
| score                   | integer | *empty* |
| date\_time\_utc         |  string | *empty* |

### Leaderboard

A score is submitted for a specific custom leaderboard, which is identified by its `custom_id` property.

{% hint style="warning" %}
Scores submitted to `standard` leaderboards will be rejected.
{% endhint %}

### Player

A score is submitted for a specific player, which is identified by the player's `custom_id` property.

{% hint style="info" %}
When submitting scores, if the `custom_player_id` is not recognized, then a new player will be created.
{% endhint %}

### Score

The score is an integer. Currently, it must be a value between 0 and 9,223,372,036,854,775,807, inclusive.

### Date/time

The `date_time_utc` value is the date/time (UTC) for when the score should be recorded. It defaults to the current date/time. If provided, however, it must be a date/time in the past. Scores may not be submitted for the future.


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.r4nkt.com/concepts/scores.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
