Get beatmaps
The getBeatmaps
method on a LegacyClient
instance makes a GET
request to the get_beatmaps
endpoint and returns an array of beatmaps.
Example
const beatmaps = await legacyApi.getBeatmaps({
b: 1031991
});
Parameters
Parameter | Type | Optional | Description |
---|---|---|---|
params | GetBeatmapsParams | The request’s URL parameters | |
params.since | Date | ✓ | Beatmaps ranked or loved since this date (in UTC) |
params.s | number | ✓ | Beatmaps with a specific beatmapset ID |
params.b | number | ✓ | Beatmap with a specific beatmap ID |
params.u | string | number | ✓ | Beatmaps created by user with a specific user ID or username |
params.type | UserType | ✓ | Specify if u is a user ID (id ) or a username (string ) |
params.m | GameMode | ✓ | Beatmaps from a specific gamemode |
params.a | boolean | ✓ | Include converted beatmaps? |
params.h | string | ✓ | Beatmap with a specific hash |
params.limit | number | ✓ | Limit amount of beatmaps to return (500 max.) |
params.mods | Mod[] | ✓ | Mods to apply |
Returns
Promise<LegacyBeatmap[]>;
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 .