Get beatmap user score
The beatmaps.getBeatmapUserScore
method on a Client
instance makes a GET
request to the beatmaps/{beatmap}/scores/users/{user}
endpoint and returns a user’s score on a beatmap. beatmaps.getBeatmapUserScoreV2
makes a request to the same endpoint, but has the X-API-Version
header set to 20220705
.
Example
const score = await api.beatmaps.getBeatmapUserScore(1816113, 12408961, {
query: {
mode: 'osu'
}
});
Parameters
Parameter | Type | Optional | Description |
---|---|---|---|
beatmap | number | ID of the beatmap to get the score from | |
user | number | ID of the user to get the score from | |
options | GetBeatmapScoresOptions | ✓ |
options.query
Parameter | Type | Optional | Description |
---|---|---|---|
mode | GameMode | ✓ | Gamemode of the score to return |
Returns
If using beatmaps.getBeatmapUserScore
:
Promise<BeatmapUserScore>;
If using beatmaps.getBeatmapUserScoreV2
:
Promise<BeatmapUserScoreV2>;
Types
Possible Exceptions
See the error handling documentation for more information.
invalid_json_syntax
network_error
unexpected_response
Notice that something is missing? Found a typo? Think something's incomplete? Or think that something can be explained better? Feel free to open a pull request or submit an issue on the library's Github repository .