1.2.1 • Published 7 years ago

osu-call v1.2.1

Weekly downloads
3
License
ISC
Repository
-
Last release
7 years ago

osu-call

An easy way to use the osu api. For questions, bug reports or general help please join my discord. https://discord.gg/HGKf4Yh

To use it simply:

const osu = require('osu-call');

Next you must give your api key:

osu.give_key('your key here');

Now you can finaly use it, for commands please look at: https://github.com/ppy/osu-api/wiki You can call any command listed here, with the parameters listed there as well. Please read the wiki page in order to learn what to enter as parameters. The wiki also shows what your output will look like, handy for using it.

You enter the parameters in an object. There is no order that you must use.

An example of a command would be:

osu.get_beatmaps({u: "4FCG",m: "0",limit: "100"})
.then(result => {
  console.log(result);
});

Now with an extra command map_info to get the map data from each map outputted by get_user_best and get_user_recent. It is very easy to use, simply put the output of either get_user_best or get_user_recent in the command, and get an object containing each map with its map id as key.

An example would be:

osu.get_user_best({u:'4FCG', limit:'5'})
.then(r => {
	osu.map_info(r)
	.then(results => {
		for (let i = 0; i < 5; i++) {
			console.log(results[r[i].beatmap_id].title);
		}
	});
});
1.2.1

7 years ago

1.2.0

7 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.0

7 years ago