gj-boomlings-api 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -44
- package/config.json +1 -1
- package/docs/dlLevel.md +52 -0
- package/docs/getAccountPosts.md +71 -0
- package/docs/getCommentHistory.md +123 -0
- package/docs/getComments.md +113 -0
- package/docs/getDailyLevel.md +17 -0
- package/docs/getGauntlets.md +81 -0
- package/docs/getOfficialSongInfo.md +25 -0
- package/docs/getProfile.md +36 -0
- package/docs/getSongInfo.md +26 -0
- package/docs/getWeeklyDemon.md +17 -0
- package/docs/objects/acc_comment.md +19 -0
- package/docs/objects/comment.md +34 -0
- package/docs/objects/level.md +95 -0
- package/docs/objects/song.md +28 -0
- package/docs/objects/user.md +61 -0
- package/docs/reportLevel.md +19 -0
- package/docs/uploadAccountPost.md +27 -0
- package/functions/decURLSafeBase64.js +1 -1
- package/functions/dlLevel.js +7 -7
- package/functions/encURLSafeBase64.js +2 -2
- package/functions/getAccountPosts.js +147 -0
- package/functions/getCommentHistory.js +146 -0
- package/functions/getComments.js +106 -14
- package/functions/getGauntlets.js +55 -0
- package/functions/getOfficialSongInfo.js +1 -1
- package/functions/getProfile.js +4 -4
- package/functions/getSongInfo.js +3 -3
- package/functions/reportLevel.js +4 -4
- package/functions/uploadAccountPost.js +53 -0
- package/index.js +9 -3
- package/misc/decCommentFromHistory.js +31 -0
- package/misc/decodeAccountPost.js +18 -0
- package/misc/decodeGJComment.js +2 -8
- package/misc/decodeGJGauntlet.js +45 -0
- package/misc/officialsongs.json +0 -39
- package/package.json +1 -2
- package/functions/getLevelData.js +0 -30
package/README.md
CHANGED
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
# gj-boomlings-api
|
|
2
|
+
<div align="center">
|
|
3
|
+
<a href="https://www.npmjs.com/package/gj-boomlings-api"><img src="https://img.shields.io/npm/v/gj-boomlings-api.svg?maxAge=3600" alt="npm version" /></a>
|
|
4
|
+
<a href="https://www.npmjs.com/package/gj-boomlings-api"><img src="https://img.shields.io/npm/dt/gj-boomlings-api.svg?maxAge=3600" alt="npm downloads" /></a>
|
|
5
|
+
<a href="https://snyk.io/test/github/shikoshib/gj-boomlings-api"><img src="https://snyk.io/test/github/shikoshib/gj-boomlings-api/badge.svg" alt="Known Vulnerabilities" /></a>
|
|
6
|
+
</div>
|
|
2
7
|
|
|
3
8
|
This package gets info from RobTop's servers (boomlings.com) and converts it into pure and beautiful JSON.
|
|
4
9
|
|
|
@@ -10,7 +15,7 @@ So basically this function downloads the entire level and converts the response
|
|
|
10
15
|
|
|
11
16
|
```js
|
|
12
17
|
const gd = require("gj-boomlings-api");
|
|
13
|
-
gd.dlLevel(58825144).then(console.log);
|
|
18
|
+
gd.dlLevel(58825144).then(console.log); // returns "xo"
|
|
14
19
|
```
|
|
15
20
|
|
|
16
21
|
Returns:
|
|
@@ -59,7 +64,7 @@ With this function, you can get somebody's profile info. You can use a player ID
|
|
|
59
64
|
|
|
60
65
|
```js
|
|
61
66
|
const gd = require("gj-boomlings-api");
|
|
62
|
-
gd.getProfile(16).then(console.log);
|
|
67
|
+
gd.getProfile(16).then(console.log); // returns RobTop's info
|
|
63
68
|
```
|
|
64
69
|
|
|
65
70
|
Returns:
|
|
@@ -86,48 +91,8 @@ Returns:
|
|
|
86
91
|
}
|
|
87
92
|
```
|
|
88
93
|
|
|
89
|
-
|
|
94
|
+
Check out [docs](./docs/) for more info.
|
|
90
95
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
```js
|
|
94
|
-
const gd = require("gj-boomlings-api");
|
|
95
|
-
gd.getSongInfo(1099128).then(console.log);
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
Returns:
|
|
99
|
-
|
|
100
|
-
```
|
|
101
|
-
{
|
|
102
|
-
name: 'Dynamics',
|
|
103
|
-
id: 1099128,
|
|
104
|
-
artist: 'shikoshib',
|
|
105
|
-
artistId: 10001037,
|
|
106
|
-
fileSize: '5.74 MB',
|
|
107
|
-
link: 'https://audio.ngfiles.com/1099000/1099128_Dynamics.mp3?f1640426773'
|
|
108
|
-
}
|
|
109
|
-
```
|
|
110
|
-
|
|
111
|
-
### getOfficialSongInfo(song)
|
|
112
|
-
|
|
113
|
-
Basically the same thing as ```getSongInfo()```, but for official songs.
|
|
114
|
-
|
|
115
|
-
```js
|
|
116
|
-
const gd = require("gj-boomlings-api");
|
|
117
|
-
const song = gd.getOfficialSongInfo(14);
|
|
118
|
-
console.log(song);
|
|
119
|
-
```
|
|
120
|
-
|
|
121
|
-
Returns:
|
|
122
|
-
|
|
123
|
-
```
|
|
124
|
-
{
|
|
125
|
-
name: 'Clubstep',
|
|
126
|
-
id: 'Level 14',
|
|
127
|
-
artist: 'DJ-Nate',
|
|
128
|
-
fileSize: '0 MB',
|
|
129
|
-
link: 'https://www.newgrounds.com/audio/listen/396093'
|
|
130
|
-
}
|
|
131
|
-
```
|
|
96
|
+
---
|
|
132
97
|
|
|
133
98
|
Inspired by [GDBrowser](https://github.com/GDColon/GDBrowser/). Thanks to [Wireshark](https://www.wireshark.org/) and [GDDocs](https://github.com/gd-programming/gd.docs/) for helping me in creating this package.
|
package/config.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"headers":{"Content-Type":"application/x-www-form-urlencoded","user-agent":""}}
|
|
1
|
+
{"headers":{"Content-Type":"application/x-www-form-urlencoded","user-agent":"","Accept-Encoding":"*","Accept":"*/*"},"server":"http://www.boomlings.com/database/"}
|
package/docs/dlLevel.md
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# dlLevel()
|
|
2
|
+
|
|
3
|
+
Downloads a level and decodes it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`level` - the level ID.
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.dlLevel(58825144).then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
```
|
|
16
|
+
{
|
|
17
|
+
id: 58825144,
|
|
18
|
+
name: 'xo',
|
|
19
|
+
description: 'stream vertigo',
|
|
20
|
+
creator: 'KrmaL',
|
|
21
|
+
level_version: 2,
|
|
22
|
+
difficulty: 'Extreme Demon',
|
|
23
|
+
stars: 10,
|
|
24
|
+
downloads: 2587512,
|
|
25
|
+
likes: 106611,
|
|
26
|
+
disliked: false,
|
|
27
|
+
length: 'XL',
|
|
28
|
+
password: '000007',
|
|
29
|
+
demon: true,
|
|
30
|
+
featured: false,
|
|
31
|
+
epic: false,
|
|
32
|
+
objects: 37838,
|
|
33
|
+
uploaded: '2 years',
|
|
34
|
+
updated: '2 years',
|
|
35
|
+
stars_requested: 10,
|
|
36
|
+
game_version: '2.1',
|
|
37
|
+
ldm: false,
|
|
38
|
+
copied: 0,
|
|
39
|
+
two_p: false,
|
|
40
|
+
coins: 0,
|
|
41
|
+
verified_coins: false,
|
|
42
|
+
song: {
|
|
43
|
+
name: 'XO (Eden Cover & Remake)',
|
|
44
|
+
id: 766165,
|
|
45
|
+
artist: 'aaronmusslewhite',
|
|
46
|
+
artistId: 2130,
|
|
47
|
+
fileSize: '6.1 MB',
|
|
48
|
+
link: 'http://audio.ngfiles.com/766000/766165_XO-Eden-Cover-amp-Remake.mp3'
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
Returns a [level object](./objects/level.md).
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# getAccountPosts()
|
|
2
|
+
|
|
3
|
+
Gets the account comments from someone's profile.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`user` - the username or player ID.
|
|
7
|
+
|
|
8
|
+
`page` (optional) - the page of the posts. Defaults to 1.
|
|
9
|
+
|
|
10
|
+
## Example
|
|
11
|
+
```js
|
|
12
|
+
const gd = require("gj-boomlings-api");
|
|
13
|
+
gd.getAccountPosts("robtop").then(console.log);
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Response
|
|
17
|
+
```js
|
|
18
|
+
[
|
|
19
|
+
{
|
|
20
|
+
content: "Thank you everyone for the birthday wishes. You're the best! :)",
|
|
21
|
+
likes: 97911,
|
|
22
|
+
age: '10 months'
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
content: 'Happy New Year everyone! :D',
|
|
26
|
+
likes: 60720,
|
|
27
|
+
age: '11 months'
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
content: 'Thank you all for the birthday wishes :)',
|
|
31
|
+
likes: 144296,
|
|
32
|
+
age: '1 year'
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
content: 'Happy New Year everyone!... Still should post more often xD',
|
|
36
|
+
likes: 86611,
|
|
37
|
+
age: '1 year'
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
content: 'Happy New Year everyone!... I should really post more often than this xD',
|
|
41
|
+
likes: 133553,
|
|
42
|
+
age: '2 years'
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
content: 'Happy New Year everyone! :D',
|
|
46
|
+
likes: 272323,
|
|
47
|
+
age: '3 years'
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
content: 'Its amazing how talented level creators are these days :)',
|
|
51
|
+
likes: 259426,
|
|
52
|
+
age: '5 years'
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
content: 'El pollo ardiente...',
|
|
56
|
+
likes: 240085,
|
|
57
|
+
age: '5 years'
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
content: 'I am eating an apple.',
|
|
61
|
+
likes: 222661,
|
|
62
|
+
age: '5 years'
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
content: 'RubRubRubRubRubRubRubRubRubRubRubRubRubRubRubRubRubRub',
|
|
66
|
+
likes: 241988,
|
|
67
|
+
age: '5 years'
|
|
68
|
+
}
|
|
69
|
+
]
|
|
70
|
+
```
|
|
71
|
+
Returns an array of [account comments](./objects/acc_comment.md).
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# getCommentHistory()
|
|
2
|
+
|
|
3
|
+
Gets a comment history from a specified player.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`user` - the player's username or a player ID.
|
|
7
|
+
|
|
8
|
+
`page` (optional) - the page of the comment history. Defaults to 1.
|
|
9
|
+
|
|
10
|
+
`mode` (optional) - the mode of fetching the comment history. `1` is the most liked and `0` is the most recent. Defaults to 1.
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
```js
|
|
14
|
+
const gd = require("gj-boomlings-api");
|
|
15
|
+
gd.getCommentHistory("robtop").then(console.log);
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Response
|
|
19
|
+
```
|
|
20
|
+
[
|
|
21
|
+
{
|
|
22
|
+
username: 'RobTop',
|
|
23
|
+
content: 'Like or dislike this comment, it will add 10 likes either way. Check. Mate.',
|
|
24
|
+
levelID: 66715392,
|
|
25
|
+
playerID: 16,
|
|
26
|
+
likes: 733980,
|
|
27
|
+
percent: 0,
|
|
28
|
+
id: 11005139,
|
|
29
|
+
age: '1 year'
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
username: 'RobTop',
|
|
33
|
+
content: 'Can you handle the Kappa?',
|
|
34
|
+
levelID: 7485599,
|
|
35
|
+
playerID: 16,
|
|
36
|
+
likes: 115556,
|
|
37
|
+
percent: 0,
|
|
38
|
+
id: 42602304,
|
|
39
|
+
age: '5 years'
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
username: 'RobTop',
|
|
43
|
+
content: 'All demons default to hard when first rated, they get the real rating from votes later :)',
|
|
44
|
+
levelID: 42584142,
|
|
45
|
+
playerID: 16,
|
|
46
|
+
likes: 72069,
|
|
47
|
+
percent: 0,
|
|
48
|
+
id: 12967791,
|
|
49
|
+
age: '4 years'
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
username: 'RobTop',
|
|
53
|
+
content: ':)',
|
|
54
|
+
levelID: 10565740,
|
|
55
|
+
playerID: 16,
|
|
56
|
+
likes: 57919,
|
|
57
|
+
percent: 0,
|
|
58
|
+
id: 53363972,
|
|
59
|
+
age: '5 years'
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
username: 'RobTop',
|
|
63
|
+
content: 'Love it :)',
|
|
64
|
+
levelID: 29424929,
|
|
65
|
+
playerID: 16,
|
|
66
|
+
likes: 55456,
|
|
67
|
+
percent: 0,
|
|
68
|
+
id: 42731804,
|
|
69
|
+
age: '5 years'
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
username: 'RobTop',
|
|
73
|
+
content: 'Good enough for me Kappa',
|
|
74
|
+
levelID: 26681070,
|
|
75
|
+
playerID: 16,
|
|
76
|
+
likes: 51795,
|
|
77
|
+
percent: 1,
|
|
78
|
+
id: 53375227,
|
|
79
|
+
age: '5 years'
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
username: 'RobTop',
|
|
83
|
+
content: 'Getting 7 stars doesnt exclude it from the gauntlet competition dont worry :)',
|
|
84
|
+
levelID: 43908596,
|
|
85
|
+
playerID: 16,
|
|
86
|
+
likes: 43546,
|
|
87
|
+
percent: 0,
|
|
88
|
+
id: 15614671,
|
|
89
|
+
age: '4 years'
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
username: 'RobTop',
|
|
93
|
+
content: 'I like this level, you guys prefer newer ones? Almost felt like putting Nine Circles :D',
|
|
94
|
+
levelID: 17235008,
|
|
95
|
+
playerID: 16,
|
|
96
|
+
likes: 38313,
|
|
97
|
+
percent: 0,
|
|
98
|
+
id: 61915039,
|
|
99
|
+
age: '4 years'
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
username: 'RobTop',
|
|
103
|
+
content: 'Kappa',
|
|
104
|
+
levelID: 19759411,
|
|
105
|
+
playerID: 16,
|
|
106
|
+
likes: 37952,
|
|
107
|
+
percent: 0,
|
|
108
|
+
id: 22802511,
|
|
109
|
+
age: '6 years'
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
username: 'RobTop',
|
|
113
|
+
content: 'You know you are getting old when you can only get 2% on an easy demon',
|
|
114
|
+
levelID: 27690100,
|
|
115
|
+
playerID: 16,
|
|
116
|
+
likes: 37144,
|
|
117
|
+
percent: 2,
|
|
118
|
+
id: 87255259,
|
|
119
|
+
age: '1 year'
|
|
120
|
+
}
|
|
121
|
+
]
|
|
122
|
+
```
|
|
123
|
+
Returns an array of [comment objects](./objects/comment.md).
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
# getComments()
|
|
2
|
+
|
|
3
|
+
Gets a list of comments from a specified level.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`level` - the level whose comments we want to check.
|
|
7
|
+
|
|
8
|
+
`page` (optional) - the page of the comments. Defaults to 1.
|
|
9
|
+
|
|
10
|
+
`mode` (optional) - the mode of fetching the comments. `1` is the most liked and `0` is the most recent. Defaults to 1.
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
```js
|
|
14
|
+
const gd = require("gj-boomlings-api");
|
|
15
|
+
gd.getComments(42584142).then(console.log);
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
## Response
|
|
19
|
+
```
|
|
20
|
+
[
|
|
21
|
+
{
|
|
22
|
+
username: 'RobTop',
|
|
23
|
+
content: 'All demons default to hard when first rated, they get the real rating from votes later :)',
|
|
24
|
+
playerID: 16,
|
|
25
|
+
likes: 72069,
|
|
26
|
+
percent: 0,
|
|
27
|
+
id: 12967791,
|
|
28
|
+
age: '4 years'
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
username: 'Knobbelboy',
|
|
32
|
+
content: 'IT IS FINALLY OVER!!!!!!!!!!!!!! THIS IS IT!!! THANK YOU ALL!!!!',
|
|
33
|
+
playerID: 4214375,
|
|
34
|
+
likes: 71760,
|
|
35
|
+
percent: 0,
|
|
36
|
+
id: 12958654,
|
|
37
|
+
age: '4 years'
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
username: 'shaggy23',
|
|
41
|
+
content: 'Zobros: Easy Insane 9',
|
|
42
|
+
playerID: 1995959,
|
|
43
|
+
likes: 31953,
|
|
44
|
+
percent: 0,
|
|
45
|
+
id: 12968377,
|
|
46
|
+
age: '4 years'
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
username: 'IInfinityy',
|
|
50
|
+
content: "pro tip : don't play bloodlust on phone",
|
|
51
|
+
playerID: 15630652,
|
|
52
|
+
likes: 30194,
|
|
53
|
+
percent: 1,
|
|
54
|
+
id: 12960792,
|
|
55
|
+
age: '4 years'
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
username: 'RobTop',
|
|
59
|
+
content: '1% :O :O :O :O',
|
|
60
|
+
playerID: 16,
|
|
61
|
+
likes: 29497,
|
|
62
|
+
percent: 0,
|
|
63
|
+
id: 16183012,
|
|
64
|
+
age: '4 years'
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
username: 'AdvyStyles',
|
|
68
|
+
content: 'ok',
|
|
69
|
+
playerID: 2434963,
|
|
70
|
+
likes: 16910,
|
|
71
|
+
percent: 0,
|
|
72
|
+
id: 13190982,
|
|
73
|
+
age: '4 years'
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
username: 'SerSerpent',
|
|
77
|
+
content: 'Guess now Knobbelboy evolved to Knobbelman',
|
|
78
|
+
playerID: 19203596,
|
|
79
|
+
likes: 15362,
|
|
80
|
+
percent: 0,
|
|
81
|
+
id: 12962171,
|
|
82
|
+
age: '4 years'
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
username: 'GDWindex',
|
|
86
|
+
content: 'Pass is 121296, now like this comment so others can see',
|
|
87
|
+
playerID: 78434904,
|
|
88
|
+
likes: 14567,
|
|
89
|
+
percent: 0,
|
|
90
|
+
id: 13250862,
|
|
91
|
+
age: '4 years'
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
username: 'Juniper',
|
|
95
|
+
content: 'PRESS F TO RESPECT THE H*CK OUT OF KNOBBELBOY',
|
|
96
|
+
playerID: 2614903,
|
|
97
|
+
likes: 14115,
|
|
98
|
+
percent: 0,
|
|
99
|
+
id: 12970170,
|
|
100
|
+
age: '4 years'
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
username: 'lSunix',
|
|
104
|
+
content: 'aoc',
|
|
105
|
+
playerID: 14251090,
|
|
106
|
+
likes: 6437,
|
|
107
|
+
percent: 100,
|
|
108
|
+
id: 14252314,
|
|
109
|
+
age: '4 years'
|
|
110
|
+
}
|
|
111
|
+
]
|
|
112
|
+
```
|
|
113
|
+
Returns an array of [comment objects](./objects/comment.md).
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# getDailyLevel()
|
|
2
|
+
|
|
3
|
+
Downloads a daily level and decodes it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
No parameters!
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.getDailyLevel().then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
Returns a [level object](./objects/level.md).
|
|
16
|
+
|
|
17
|
+
Basically it's same thing as `dlLevel()`, but for daily levels.
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
# getGauntlets()
|
|
2
|
+
|
|
3
|
+
Gets the list of gauntlets and decodes it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
No parameters!
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.getGauntlets().then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
```
|
|
16
|
+
[
|
|
17
|
+
{
|
|
18
|
+
name: 'Fire Gauntlet',
|
|
19
|
+
levels: [ '27732941', '28200611', '27483789', '28225110', '27448202' ]
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
name: 'Ice Gauntlet',
|
|
23
|
+
levels: [ '20635816', '28151870', '25969464', '24302376', '27399722' ]
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
name: 'Poison Gauntlet',
|
|
27
|
+
levels: [ '28179535', '29094196', '29071134', '26317634', '12107595' ]
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
name: 'Shadow Gauntlet',
|
|
31
|
+
levels: [ '26949498', '26095850', '27973097', '27694897', '26070995' ]
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
name: 'Lava Gauntlet',
|
|
35
|
+
levels: [ '18533341', '28794068', '28127292', '4243988', '28677296' ]
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
name: 'Bonus Gauntlet',
|
|
39
|
+
levels: [ '28255647', '27929950', '16437345', '28270854', '29394058' ]
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
name: 'Chaos Gauntlet',
|
|
43
|
+
levels: [ '25886024', '4259126', '26897899', '7485599', '19862531' ]
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
name: 'Demon Gauntlet',
|
|
47
|
+
levels: [ '18025697', '23189196', '27786218', '27728679', '25706351' ]
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
name: 'Time Gauntlet',
|
|
51
|
+
levels: [ '40638411', '32614529', '31037168', '40937291', '35165900' ]
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
name: 'Crystal Gauntlet',
|
|
55
|
+
levels: [ '37188385', '35280911', '37187779', '36301959', '36792656' ]
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
name: 'Magic Gauntlet',
|
|
59
|
+
levels: [ '37269362', '29416734', '36997718', '39853981', '39853458' ]
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
{
|
|
63
|
+
name: 'Monster Gauntlet',
|
|
64
|
+
levels: [ '43908596', '41736289', '42843431', '44063088', '44131636' ]
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
name: 'Doom Gauntlet',
|
|
68
|
+
levels: [ '38427291', '38514054', '36966088', '38398923', '36745142' ]
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
name: 'Death Gauntlet',
|
|
72
|
+
levels: [ '44121158', '43923301', '43537990', '33244195', '35418014' ]
|
|
73
|
+
}
|
|
74
|
+
]
|
|
75
|
+
```
|
|
76
|
+
This function returns an array of gauntlets.
|
|
77
|
+
|
|
78
|
+
### Properties
|
|
79
|
+
`name` - the gauntlet name.
|
|
80
|
+
|
|
81
|
+
`levels` - the array of levels in a gauntlet.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# getOfficialSongInfo()
|
|
2
|
+
|
|
3
|
+
Gets an info about an official song by its ID.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`song` - the official song ID.
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
const song = gd.getOfficialSongInfo(14);
|
|
12
|
+
console.log(song);
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Response
|
|
16
|
+
```
|
|
17
|
+
{
|
|
18
|
+
name: 'Clubstep',
|
|
19
|
+
id: 'Level 14',
|
|
20
|
+
artist: 'DJ-Nate',
|
|
21
|
+
link: 'https://www.newgrounds.com/audio/listen/396093'
|
|
22
|
+
}
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
Returns a [song object](./objects/song.md), except for the `artistId` and `fileSize` properties.
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# getProfile()
|
|
2
|
+
|
|
3
|
+
Gets someone's profile and decodes it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`user` - the player's username or a player ID.
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.getProfile("robtop").then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
```
|
|
16
|
+
{
|
|
17
|
+
username: 'RobTop',
|
|
18
|
+
playerID: 16,
|
|
19
|
+
accountID: 71,
|
|
20
|
+
rank: 219796,
|
|
21
|
+
stars: 2375,
|
|
22
|
+
diamonds: 2170,
|
|
23
|
+
secretCoins: 3,
|
|
24
|
+
userCoins: 140,
|
|
25
|
+
demons: 5,
|
|
26
|
+
creatorPoints: 0,
|
|
27
|
+
messages: 'none',
|
|
28
|
+
friendRequests: 'none',
|
|
29
|
+
commentHistory: 'all',
|
|
30
|
+
mod: 'elder',
|
|
31
|
+
youtube: 'https://youtube.com/channel/UCz_yk8mDSAnxJq0ar66L4sw',
|
|
32
|
+
twitter: 'https://twitter.com/RobTopGames',
|
|
33
|
+
twitch: 'https://twitch.tv/robtopgames'
|
|
34
|
+
}
|
|
35
|
+
```
|
|
36
|
+
Returns a [user object](./objects/user.md).
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# getSongInfo()
|
|
2
|
+
|
|
3
|
+
Gets a song on Newgrounds by its ID and returns info about it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
`song` - the song ID.
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.getSongInfo(1099128).then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
```
|
|
16
|
+
{
|
|
17
|
+
name: 'Dynamics',
|
|
18
|
+
id: 1099128,
|
|
19
|
+
artist: 'shikoshib',
|
|
20
|
+
artistId: 10001037,
|
|
21
|
+
fileSize: '5.74 MB',
|
|
22
|
+
link: 'https://audio.ngfiles.com/1099000/1099128_Dynamics.mp3?f1640426773'
|
|
23
|
+
}
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
Returns a [song object](./objects/song.md).
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# getWeeklyDemon()
|
|
2
|
+
|
|
3
|
+
Downloads a weekly demon and decodes it.
|
|
4
|
+
|
|
5
|
+
## Parameters
|
|
6
|
+
No parameters!
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
```js
|
|
10
|
+
const gd = require("gj-boomlings-api");
|
|
11
|
+
gd.getWeeklyDemon().then(console.log);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Response
|
|
15
|
+
Returns a [level object](./objects/level.md).
|
|
16
|
+
|
|
17
|
+
Basically it's same thing as `dlLevel()`, but for weekly demons.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Account comment object
|
|
2
|
+
|
|
3
|
+
Used by `getAccountPosts()`.
|
|
4
|
+
|
|
5
|
+
## Example
|
|
6
|
+
```
|
|
7
|
+
{
|
|
8
|
+
content: "Thank you everyone for the birthday wishes. You're the best! :)",
|
|
9
|
+
likes: 97911,
|
|
10
|
+
age: '10 months'
|
|
11
|
+
}
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Properties
|
|
15
|
+
```content``` - the actual content of a comment.
|
|
16
|
+
|
|
17
|
+
```likes``` - the amount of likes on a comment.
|
|
18
|
+
|
|
19
|
+
```age``` - the age of a comment.
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# Comment object
|
|
2
|
+
|
|
3
|
+
Used by `getComments()` and `getCommentHistory()`.
|
|
4
|
+
|
|
5
|
+
## Example
|
|
6
|
+
```
|
|
7
|
+
{
|
|
8
|
+
username: 'RobTop',
|
|
9
|
+
content: ':)',
|
|
10
|
+
levelID: 10565740,
|
|
11
|
+
playerID: 16,
|
|
12
|
+
likes: 57919,
|
|
13
|
+
percent: 0,
|
|
14
|
+
id: 53363972,
|
|
15
|
+
age: '5 years'
|
|
16
|
+
}
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Properties
|
|
20
|
+
```username``` - the comment author's username.
|
|
21
|
+
|
|
22
|
+
```content``` - the actual content of a comment.
|
|
23
|
+
|
|
24
|
+
```levelID``` - the ID of a level, on which the comment was sent.
|
|
25
|
+
|
|
26
|
+
```playerID``` - the comment author's player ID.
|
|
27
|
+
|
|
28
|
+
```likes``` - the amount of likes on a comment.
|
|
29
|
+
|
|
30
|
+
```percent``` - the percentage that has been put on this comment. Returns `0` if the percentage checkbox hadn't been checked.
|
|
31
|
+
|
|
32
|
+
```id``` - the ID of a comment.
|
|
33
|
+
|
|
34
|
+
```age``` - the age of a comment.
|