osrs-json-hiscores 2.5.2 → 2.8.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/LICENSE +4 -4
- package/README.md +221 -217
- package/lib/hiscores.d.ts +43 -43
- package/lib/hiscores.js +388 -384
- package/lib/index.d.ts +5 -5
- package/lib/index.js +17 -17
- package/lib/types.d.ts +55 -54
- package/lib/types.js +2 -2
- package/lib/utils/constants.d.ts +35 -33
- package/lib/utils/constants.js +224 -217
- package/lib/utils/helpers.d.ts +56 -56
- package/lib/utils/helpers.js +92 -92
- package/lib/utils/index.d.ts +2 -2
- package/lib/utils/index.js +14 -14
- package/package.json +114 -114
package/lib/utils/constants.js
CHANGED
@@ -1,217 +1,224 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
3
|
-
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
4
|
-
to[j] = from[i];
|
5
|
-
return to;
|
6
|
-
};
|
7
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
8
|
-
exports.FORMATTED_LEAGUE_POINTS = exports.FORMATTED_SOUL_WARS = exports.FORMATTED_LMS = exports.FORMATTED_BH_NAMES = exports.FORMATTED_CLUE_NAMES = exports.FORMATTED_SKILL_NAMES = exports.FORMATTED_BOSS_NAMES = exports.ACTIVITIES = exports.BOSSES = exports.GAMEMODES = exports.BH_MODES = exports.CLUES = exports.SKILLS = exports.GAMEMODE_URL = exports.SCORES_URL = exports.STATS_URL = exports.BASE_URL = void 0;
|
9
|
-
exports.BASE_URL = 'https://secure.runescape.com/m=hiscore_oldschool';
|
10
|
-
exports.STATS_URL = 'index_lite.ws?player=';
|
11
|
-
exports.SCORES_URL = 'overall.ws?';
|
12
|
-
exports.GAMEMODE_URL = {
|
13
|
-
main: exports.BASE_URL + "/",
|
14
|
-
ironman: exports.BASE_URL + "_ironman/",
|
15
|
-
hardcore: exports.BASE_URL + "_hardcore_ironman/",
|
16
|
-
ultimate: exports.BASE_URL + "_ultimate/",
|
17
|
-
deadman: exports.BASE_URL + "_deadman/",
|
18
|
-
seasonal: exports.BASE_URL + "_seasonal/",
|
19
|
-
tournament: exports.BASE_URL + "_tournament/"
|
20
|
-
};
|
21
|
-
exports.SKILLS = [
|
22
|
-
'overall',
|
23
|
-
'attack',
|
24
|
-
'defence',
|
25
|
-
'strength',
|
26
|
-
'hitpoints',
|
27
|
-
'ranged',
|
28
|
-
'prayer',
|
29
|
-
'magic',
|
30
|
-
'cooking',
|
31
|
-
'woodcutting',
|
32
|
-
'fletching',
|
33
|
-
'fishing',
|
34
|
-
'firemaking',
|
35
|
-
'crafting',
|
36
|
-
'smithing',
|
37
|
-
'mining',
|
38
|
-
'herblore',
|
39
|
-
'agility',
|
40
|
-
'thieving',
|
41
|
-
'slayer',
|
42
|
-
'farming',
|
43
|
-
'runecraft',
|
44
|
-
'hunter',
|
45
|
-
'construction'
|
46
|
-
];
|
47
|
-
exports.CLUES = [
|
48
|
-
'all',
|
49
|
-
'beginner',
|
50
|
-
'easy',
|
51
|
-
'medium',
|
52
|
-
'hard',
|
53
|
-
'elite',
|
54
|
-
'master'
|
55
|
-
];
|
56
|
-
exports.BH_MODES = ['hunter', 'rogue'];
|
57
|
-
exports.GAMEMODES = [
|
58
|
-
'main',
|
59
|
-
'ironman',
|
60
|
-
'hardcore',
|
61
|
-
'ultimate',
|
62
|
-
'deadman',
|
63
|
-
'seasonal',
|
64
|
-
'tournament'
|
65
|
-
];
|
66
|
-
exports.BOSSES = [
|
67
|
-
'abyssalSire',
|
68
|
-
'alchemicalHydra',
|
69
|
-
'barrows',
|
70
|
-
'bryophyta',
|
71
|
-
'callisto',
|
72
|
-
'cerberus',
|
73
|
-
'chambersOfXeric',
|
74
|
-
'chambersOfXericChallengeMode',
|
75
|
-
'chaosElemental',
|
76
|
-
'chaosFanatic',
|
77
|
-
'commanderZilyana',
|
78
|
-
'corporealBeast',
|
79
|
-
'crazyArchaeologist',
|
80
|
-
'dagannothPrime',
|
81
|
-
'dagannothRex',
|
82
|
-
'dagannothSupreme',
|
83
|
-
'derangedArchaeologist',
|
84
|
-
'generalGraardor',
|
85
|
-
'giantMole',
|
86
|
-
'grotesqueGuardians',
|
87
|
-
'hespori',
|
88
|
-
'kalphiteQueen',
|
89
|
-
'kingBlackDragon',
|
90
|
-
'kraken',
|
91
|
-
'kreeArra',
|
92
|
-
'krilTsutsaroth',
|
93
|
-
'mimic',
|
94
|
-
'
|
95
|
-
'
|
96
|
-
'
|
97
|
-
'
|
98
|
-
'
|
99
|
-
'
|
100
|
-
'
|
101
|
-
'
|
102
|
-
'
|
103
|
-
'
|
104
|
-
'
|
105
|
-
'
|
106
|
-
'
|
107
|
-
'
|
108
|
-
'
|
109
|
-
'
|
110
|
-
'
|
111
|
-
'
|
112
|
-
'
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
'
|
118
|
-
'
|
119
|
-
'
|
120
|
-
'
|
121
|
-
'
|
122
|
-
'
|
123
|
-
'
|
124
|
-
'
|
125
|
-
'
|
126
|
-
'
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
exports.
|
217
|
-
|
1
|
+
"use strict";
|
2
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
3
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
4
|
+
to[j] = from[i];
|
5
|
+
return to;
|
6
|
+
};
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
8
|
+
exports.INVALID_FORMAT_ERROR = exports.FORMATTED_RIFTS_CLOSED = exports.FORMATTED_LEAGUE_POINTS = exports.FORMATTED_SOUL_WARS = exports.FORMATTED_LMS = exports.FORMATTED_BH_NAMES = exports.FORMATTED_CLUE_NAMES = exports.FORMATTED_SKILL_NAMES = exports.FORMATTED_BOSS_NAMES = exports.ACTIVITIES = exports.BOSSES = exports.GAMEMODES = exports.BH_MODES = exports.CLUES = exports.SKILLS = exports.GAMEMODE_URL = exports.SCORES_URL = exports.STATS_URL = exports.BASE_URL = void 0;
|
9
|
+
exports.BASE_URL = 'https://secure.runescape.com/m=hiscore_oldschool';
|
10
|
+
exports.STATS_URL = 'index_lite.ws?player=';
|
11
|
+
exports.SCORES_URL = 'overall.ws?';
|
12
|
+
exports.GAMEMODE_URL = {
|
13
|
+
main: exports.BASE_URL + "/",
|
14
|
+
ironman: exports.BASE_URL + "_ironman/",
|
15
|
+
hardcore: exports.BASE_URL + "_hardcore_ironman/",
|
16
|
+
ultimate: exports.BASE_URL + "_ultimate/",
|
17
|
+
deadman: exports.BASE_URL + "_deadman/",
|
18
|
+
seasonal: exports.BASE_URL + "_seasonal/",
|
19
|
+
tournament: exports.BASE_URL + "_tournament/"
|
20
|
+
};
|
21
|
+
exports.SKILLS = [
|
22
|
+
'overall',
|
23
|
+
'attack',
|
24
|
+
'defence',
|
25
|
+
'strength',
|
26
|
+
'hitpoints',
|
27
|
+
'ranged',
|
28
|
+
'prayer',
|
29
|
+
'magic',
|
30
|
+
'cooking',
|
31
|
+
'woodcutting',
|
32
|
+
'fletching',
|
33
|
+
'fishing',
|
34
|
+
'firemaking',
|
35
|
+
'crafting',
|
36
|
+
'smithing',
|
37
|
+
'mining',
|
38
|
+
'herblore',
|
39
|
+
'agility',
|
40
|
+
'thieving',
|
41
|
+
'slayer',
|
42
|
+
'farming',
|
43
|
+
'runecraft',
|
44
|
+
'hunter',
|
45
|
+
'construction'
|
46
|
+
];
|
47
|
+
exports.CLUES = [
|
48
|
+
'all',
|
49
|
+
'beginner',
|
50
|
+
'easy',
|
51
|
+
'medium',
|
52
|
+
'hard',
|
53
|
+
'elite',
|
54
|
+
'master'
|
55
|
+
];
|
56
|
+
exports.BH_MODES = ['hunter', 'rogue'];
|
57
|
+
exports.GAMEMODES = [
|
58
|
+
'main',
|
59
|
+
'ironman',
|
60
|
+
'hardcore',
|
61
|
+
'ultimate',
|
62
|
+
'deadman',
|
63
|
+
'seasonal',
|
64
|
+
'tournament'
|
65
|
+
];
|
66
|
+
exports.BOSSES = [
|
67
|
+
'abyssalSire',
|
68
|
+
'alchemicalHydra',
|
69
|
+
'barrows',
|
70
|
+
'bryophyta',
|
71
|
+
'callisto',
|
72
|
+
'cerberus',
|
73
|
+
'chambersOfXeric',
|
74
|
+
'chambersOfXericChallengeMode',
|
75
|
+
'chaosElemental',
|
76
|
+
'chaosFanatic',
|
77
|
+
'commanderZilyana',
|
78
|
+
'corporealBeast',
|
79
|
+
'crazyArchaeologist',
|
80
|
+
'dagannothPrime',
|
81
|
+
'dagannothRex',
|
82
|
+
'dagannothSupreme',
|
83
|
+
'derangedArchaeologist',
|
84
|
+
'generalGraardor',
|
85
|
+
'giantMole',
|
86
|
+
'grotesqueGuardians',
|
87
|
+
'hespori',
|
88
|
+
'kalphiteQueen',
|
89
|
+
'kingBlackDragon',
|
90
|
+
'kraken',
|
91
|
+
'kreeArra',
|
92
|
+
'krilTsutsaroth',
|
93
|
+
'mimic',
|
94
|
+
'nex',
|
95
|
+
'nightmare',
|
96
|
+
'phosanisNightmare',
|
97
|
+
'obor',
|
98
|
+
'sarachnis',
|
99
|
+
'scorpia',
|
100
|
+
'skotizo',
|
101
|
+
'tempoross',
|
102
|
+
'gauntlet',
|
103
|
+
'corruptedGauntlet',
|
104
|
+
'theatreOfBlood',
|
105
|
+
'theatreOfBloodHardMode',
|
106
|
+
'thermonuclearSmokeDevil',
|
107
|
+
'tzKalZuk',
|
108
|
+
'tzTokJad',
|
109
|
+
'venenatis',
|
110
|
+
'vetion',
|
111
|
+
'vorkath',
|
112
|
+
'wintertodt',
|
113
|
+
'zalcano',
|
114
|
+
'zulrah'
|
115
|
+
];
|
116
|
+
exports.ACTIVITIES = __spreadArray([
|
117
|
+
'leaguePoints',
|
118
|
+
'hunterBH',
|
119
|
+
'rogueBH',
|
120
|
+
'allClues',
|
121
|
+
'beginnerClues',
|
122
|
+
'easyClues',
|
123
|
+
'mediumClues',
|
124
|
+
'hardClues',
|
125
|
+
'eliteClues',
|
126
|
+
'masterClues',
|
127
|
+
'lastManStanding',
|
128
|
+
'soulWarsZeal',
|
129
|
+
'riftsClosed'
|
130
|
+
], exports.BOSSES);
|
131
|
+
exports.FORMATTED_BOSS_NAMES = {
|
132
|
+
abyssalSire: 'Abyssal Sire',
|
133
|
+
alchemicalHydra: 'Alchemical Hydra',
|
134
|
+
barrows: 'Barrows Chests',
|
135
|
+
bryophyta: 'Bryophyta',
|
136
|
+
callisto: 'Callisto',
|
137
|
+
cerberus: 'Cerberus',
|
138
|
+
chambersOfXeric: 'Chambers of Xeric',
|
139
|
+
chambersOfXericChallengeMode: 'Chambers of Xeric: Challenge Mode',
|
140
|
+
chaosElemental: 'Chaos Elemental',
|
141
|
+
chaosFanatic: 'Chaos Fanatic',
|
142
|
+
commanderZilyana: 'Commander Zilyana',
|
143
|
+
corporealBeast: 'Corporeal Beast',
|
144
|
+
crazyArchaeologist: 'Crazy Archaeologist',
|
145
|
+
dagannothPrime: 'Dagannoth Prime',
|
146
|
+
dagannothRex: 'Dagannoth Rex',
|
147
|
+
dagannothSupreme: 'Dagannoth Supreme',
|
148
|
+
derangedArchaeologist: 'Deranged Archaeologist',
|
149
|
+
generalGraardor: 'General Graardor',
|
150
|
+
giantMole: 'Giant Mole',
|
151
|
+
grotesqueGuardians: 'Grotesque Guardians',
|
152
|
+
hespori: 'Hespori',
|
153
|
+
kalphiteQueen: 'Kalphite Queen',
|
154
|
+
kingBlackDragon: 'King Black Dragon',
|
155
|
+
kraken: 'Kraken',
|
156
|
+
kreeArra: "Kree'Arra",
|
157
|
+
krilTsutsaroth: "K'ril Tsutsaroth",
|
158
|
+
mimic: 'Mimic',
|
159
|
+
nex: 'Nex',
|
160
|
+
nightmare: 'The Nightmare of Ashihama',
|
161
|
+
phosanisNightmare: "Phosani's Nightmare",
|
162
|
+
obor: 'Obor',
|
163
|
+
sarachnis: 'Sarachnis',
|
164
|
+
scorpia: 'Scorpia',
|
165
|
+
skotizo: 'Skotizo',
|
166
|
+
tempoross: 'Tempoross',
|
167
|
+
gauntlet: 'The Gauntlet',
|
168
|
+
corruptedGauntlet: 'The Corrupted Gauntlet',
|
169
|
+
theatreOfBlood: 'Theatre of Blood',
|
170
|
+
theatreOfBloodHardMode: 'Theatre of Blood: Hard Mode',
|
171
|
+
thermonuclearSmokeDevil: 'Thermonuclear Smoke Devil',
|
172
|
+
tzKalZuk: 'TzKal-Zuk',
|
173
|
+
tzTokJad: 'TzTok-Jad',
|
174
|
+
venenatis: 'Venenatis',
|
175
|
+
vetion: "Vet'ion",
|
176
|
+
vorkath: 'Vorkath',
|
177
|
+
wintertodt: 'Wintertodt',
|
178
|
+
zalcano: 'Zalcano',
|
179
|
+
zulrah: 'Zulrah'
|
180
|
+
};
|
181
|
+
exports.FORMATTED_SKILL_NAMES = {
|
182
|
+
overall: 'Overall',
|
183
|
+
attack: 'Attack',
|
184
|
+
defence: 'Defence',
|
185
|
+
strength: 'Strength',
|
186
|
+
hitpoints: 'Hitpoints',
|
187
|
+
ranged: 'Ranged',
|
188
|
+
prayer: 'Prayer',
|
189
|
+
magic: 'Magic',
|
190
|
+
cooking: 'Cooking',
|
191
|
+
woodcutting: 'Woodcutting',
|
192
|
+
fletching: 'Fletching',
|
193
|
+
fishing: 'Fishing',
|
194
|
+
firemaking: 'Firemaking',
|
195
|
+
crafting: 'Crafting',
|
196
|
+
smithing: 'Smithing',
|
197
|
+
mining: 'Mining',
|
198
|
+
herblore: 'Herblore',
|
199
|
+
agility: 'Agility',
|
200
|
+
thieving: 'Thieving',
|
201
|
+
slayer: 'Slayer',
|
202
|
+
farming: 'Farming',
|
203
|
+
runecraft: 'Runecraft',
|
204
|
+
hunter: 'Hunter',
|
205
|
+
construction: 'Construction'
|
206
|
+
};
|
207
|
+
exports.FORMATTED_CLUE_NAMES = {
|
208
|
+
all: 'Clue Scrolls (all)',
|
209
|
+
beginner: 'Clue Scrolls (beginner)',
|
210
|
+
easy: 'Clue Scrolls (easy)',
|
211
|
+
medium: 'Clue Scrolls (medium)',
|
212
|
+
hard: 'Clue Scrolls (hard)',
|
213
|
+
elite: 'Clue Scrolls (elite)',
|
214
|
+
master: 'Clue Scrolls (master)'
|
215
|
+
};
|
216
|
+
exports.FORMATTED_BH_NAMES = {
|
217
|
+
rogue: 'Bounty Hunter - Rogue',
|
218
|
+
hunter: 'Bounty Hunter - Hunter'
|
219
|
+
};
|
220
|
+
exports.FORMATTED_LMS = 'Last Man Standing';
|
221
|
+
exports.FORMATTED_SOUL_WARS = 'Soul Wars Zeal';
|
222
|
+
exports.FORMATTED_LEAGUE_POINTS = 'League Points';
|
223
|
+
exports.FORMATTED_RIFTS_CLOSED = 'Rifts Closed';
|
224
|
+
exports.INVALID_FORMAT_ERROR = 'Invalid hiscores format';
|
package/lib/utils/helpers.d.ts
CHANGED
@@ -1,56 +1,56 @@
|
|
1
|
-
import { Gamemode, SkillName, ActivityName } from '../types';
|
2
|
-
/**
|
3
|
-
* Will generate a stats URL for the official OSRS API.
|
4
|
-
*
|
5
|
-
* @param gamemode Gamemode to fetch ranks for.
|
6
|
-
* @param rsn Username of the player.
|
7
|
-
* @returns Encoded stats URL.
|
8
|
-
*/
|
9
|
-
export declare const getStatsURL: (gamemode: Gamemode, rsn: string) => string;
|
10
|
-
/**
|
11
|
-
* Will generate a player table URL for the official OSRS hiscores website.
|
12
|
-
*
|
13
|
-
* @param gamemode Gamemode to fetch ranks for.
|
14
|
-
* @param rsn Username of the player.
|
15
|
-
* @returns Encoded player table URL.
|
16
|
-
*/
|
17
|
-
export declare const getPlayerTableURL: (gamemode: Gamemode, rsn: string) => string;
|
18
|
-
/**
|
19
|
-
* Will generate a skill table URL for the official OSRS hiscores website.
|
20
|
-
*
|
21
|
-
* @param gamemode Gamemode to fetch ranks for.
|
22
|
-
* @param skill Skill to fetch ranks for.
|
23
|
-
* @param page Page number.
|
24
|
-
* @returns
|
25
|
-
*/
|
26
|
-
export declare const getSkillPageURL: (gamemode: Gamemode, skill: SkillName, page: number) => string;
|
27
|
-
/**
|
28
|
-
* Will generate an activity table URL for the official OSRS hiscores website.
|
29
|
-
*
|
30
|
-
* @param gamemode Gamemode to fetch ranks for.
|
31
|
-
* @param activity Activity or boss to fetch ranks for.
|
32
|
-
* @param page Page number.
|
33
|
-
* @returns
|
34
|
-
*/
|
35
|
-
export declare const getActivityPageURL: (gamemode: Gamemode, activity: ActivityName, page: number) => string;
|
36
|
-
/**
|
37
|
-
* Extracts a number from an OSRS hiscores table cell element.
|
38
|
-
*
|
39
|
-
* @param el OSRS hiscores table cell element.
|
40
|
-
* @returns Number parsed from cell text.
|
41
|
-
*/
|
42
|
-
export declare const numberFromElement: (el: Element | null) => number;
|
43
|
-
/**
|
44
|
-
* Extracts a RSN from an OSRS hiscores table cell element.
|
45
|
-
*
|
46
|
-
* @param el OSRS hiscores table cell element.
|
47
|
-
* @returns RSN parsed from cell text.
|
48
|
-
*/
|
49
|
-
export declare const rsnFromElement: (el: Element | null) => string;
|
50
|
-
/**
|
51
|
-
* Will run an Axios `GET` request against a given URL after injecting a `User-Agent` header.
|
52
|
-
*
|
53
|
-
* @param url URL to run a `GET` request against.
|
54
|
-
* @returns Axios response.
|
55
|
-
*/
|
56
|
-
export declare const httpGet: (url: string) => Promise<import("axios").AxiosResponse<any>>;
|
1
|
+
import { Gamemode, SkillName, ActivityName } from '../types';
|
2
|
+
/**
|
3
|
+
* Will generate a stats URL for the official OSRS API.
|
4
|
+
*
|
5
|
+
* @param gamemode Gamemode to fetch ranks for.
|
6
|
+
* @param rsn Username of the player.
|
7
|
+
* @returns Encoded stats URL.
|
8
|
+
*/
|
9
|
+
export declare const getStatsURL: (gamemode: Gamemode, rsn: string) => string;
|
10
|
+
/**
|
11
|
+
* Will generate a player table URL for the official OSRS hiscores website.
|
12
|
+
*
|
13
|
+
* @param gamemode Gamemode to fetch ranks for.
|
14
|
+
* @param rsn Username of the player.
|
15
|
+
* @returns Encoded player table URL.
|
16
|
+
*/
|
17
|
+
export declare const getPlayerTableURL: (gamemode: Gamemode, rsn: string) => string;
|
18
|
+
/**
|
19
|
+
* Will generate a skill table URL for the official OSRS hiscores website.
|
20
|
+
*
|
21
|
+
* @param gamemode Gamemode to fetch ranks for.
|
22
|
+
* @param skill Skill to fetch ranks for.
|
23
|
+
* @param page Page number.
|
24
|
+
* @returns
|
25
|
+
*/
|
26
|
+
export declare const getSkillPageURL: (gamemode: Gamemode, skill: SkillName, page: number) => string;
|
27
|
+
/**
|
28
|
+
* Will generate an activity table URL for the official OSRS hiscores website.
|
29
|
+
*
|
30
|
+
* @param gamemode Gamemode to fetch ranks for.
|
31
|
+
* @param activity Activity or boss to fetch ranks for.
|
32
|
+
* @param page Page number.
|
33
|
+
* @returns
|
34
|
+
*/
|
35
|
+
export declare const getActivityPageURL: (gamemode: Gamemode, activity: ActivityName, page: number) => string;
|
36
|
+
/**
|
37
|
+
* Extracts a number from an OSRS hiscores table cell element.
|
38
|
+
*
|
39
|
+
* @param el OSRS hiscores table cell element.
|
40
|
+
* @returns Number parsed from cell text.
|
41
|
+
*/
|
42
|
+
export declare const numberFromElement: (el: Element | null) => number;
|
43
|
+
/**
|
44
|
+
* Extracts a RSN from an OSRS hiscores table cell element.
|
45
|
+
*
|
46
|
+
* @param el OSRS hiscores table cell element.
|
47
|
+
* @returns RSN parsed from cell text.
|
48
|
+
*/
|
49
|
+
export declare const rsnFromElement: (el: Element | null) => string;
|
50
|
+
/**
|
51
|
+
* Will run an Axios `GET` request against a given URL after injecting a `User-Agent` header.
|
52
|
+
*
|
53
|
+
* @param url URL to run a `GET` request against.
|
54
|
+
* @returns Axios response.
|
55
|
+
*/
|
56
|
+
export declare const httpGet: (url: string) => Promise<import("axios").AxiosResponse<any>>;
|