@retroachievements/api 1.2.1 → 1.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 +38 -49
- package/dist/__playground.d.ts +8 -8
- package/dist/achievement/getAchievementUnlocks.d.ts +46 -46
- package/dist/achievement/getAchievementUnlocks.test.d.ts +1 -1
- package/dist/achievement/index.d.ts +2 -2
- package/dist/achievement/models/achievement-unlock-entity.model.d.ts +29 -29
- package/dist/achievement/models/get-achievement-unlocks-response.model.d.ts +30 -30
- package/dist/achievement/models/index.d.ts +2 -2
- package/dist/api.cjs +1 -1
- package/dist/api.cjs.map +1 -1
- package/dist/api.modern.js +1 -1
- package/dist/api.modern.js.map +1 -1
- package/dist/api.module.js +1 -1
- package/dist/api.module.js.map +1 -1
- package/dist/api.umd.js +1 -1
- package/dist/api.umd.js.map +1 -1
- package/dist/console/getConsoleIds.d.ts +22 -22
- package/dist/console/getConsoleIds.test.d.ts +1 -1
- package/dist/console/getGameList.d.ts +53 -53
- package/dist/console/getGameList.test.d.ts +1 -1
- package/dist/console/index.d.ts +3 -3
- package/dist/console/models/console-id.model.d.ts +4 -4
- package/dist/console/models/game-list.model.d.ts +15 -15
- package/dist/console/models/get-console-ids-response.model.d.ts +4 -4
- package/dist/console/models/get-game-list-response.model.d.ts +15 -15
- package/dist/console/models/index.d.ts +4 -4
- package/dist/feed/getAchievementOfTheWeek.d.ts +48 -48
- package/dist/feed/getAchievementOfTheWeek.test.d.ts +1 -1
- package/dist/feed/getActiveClaims.d.ts +40 -40
- package/dist/feed/getActiveClaims.test.d.ts +1 -1
- package/dist/feed/getClaims.d.ts +7 -7
- package/dist/feed/getClaims.test.d.ts +1 -1
- package/dist/feed/getTopTenUsers.d.ts +24 -24
- package/dist/feed/getTopTenUsers.test.d.ts +1 -1
- package/dist/feed/index.d.ts +5 -5
- package/dist/feed/models/achievement-of-the-week.model.d.ts +32 -32
- package/dist/feed/models/claim-set-type.enum.d.ts +4 -4
- package/dist/feed/models/claim-status.enum.d.ts +5 -5
- package/dist/feed/models/claim-type.enum.d.ts +4 -4
- package/dist/feed/models/get-achievement-of-the-week-response.model.d.ts +32 -32
- package/dist/feed/models/get-set-claims-response.model.d.ts +21 -21
- package/dist/feed/models/get-top-ten-users-response.model.d.ts +10 -10
- package/dist/feed/models/index.d.ts +10 -10
- package/dist/feed/models/set-claim.model.d.ts +43 -43
- package/dist/feed/models/top-ten-users-entity.model.d.ts +5 -5
- package/dist/feed/models/top-ten-users.model.d.ts +2 -2
- package/dist/game/getAchievementCount.d.ts +32 -32
- package/dist/game/getAchievementCount.test.d.ts +1 -1
- package/dist/game/getAchievementDistribution.d.ts +58 -58
- package/dist/game/getAchievementDistribution.test.d.ts +1 -1
- package/dist/game/getGame.d.ts +49 -49
- package/dist/game/getGame.test.d.ts +1 -1
- package/dist/game/getGameExtended.d.ts +70 -69
- package/dist/game/getGameExtended.test.d.ts +1 -1
- package/dist/game/getGameRankAndScore.d.ts +39 -39
- package/dist/game/getGameRankAndScore.test.d.ts +1 -1
- package/dist/game/getGameRating.d.ts +39 -39
- package/dist/game/getGameRating.test.d.ts +1 -1
- package/dist/game/index.d.ts +7 -7
- package/dist/game/models/achievement-count.model.d.ts +4 -4
- package/dist/game/models/achievement-distribution-flags.enum.d.ts +4 -4
- package/dist/game/models/game-extended-achievement-entity.model.d.ts +15 -15
- package/dist/game/models/game-extended-claim-entity.model.d.ts +7 -7
- package/dist/game/models/game-extended.model.d.ts +25 -25
- package/dist/game/models/game-rank-and-score-entity.model.d.ts +6 -6
- package/dist/game/models/game-rating.model.d.ts +9 -9
- package/dist/game/models/game.model.d.ts +19 -19
- package/dist/game/models/get-achievement-count-response.model.d.ts +4 -4
- package/dist/game/models/get-achievement-distribution-response.model.d.ts +1 -1
- package/dist/game/models/get-game-extended-response.model.d.ts +50 -50
- package/dist/game/models/get-game-rank-and-score-response.model.d.ts +8 -8
- package/dist/game/models/get-game-rating-response.model.d.ts +9 -9
- package/dist/game/models/get-game-response.model.d.ts +19 -19
- package/dist/game/models/index.d.ts +14 -14
- package/dist/index.d.ts +7 -7
- package/dist/ticket/getTicketData.d.ts +159 -159
- package/dist/ticket/getTicketData.test.d.ts +1 -1
- package/dist/ticket/index.d.ts +2 -2
- package/dist/ticket/models/achievement-ticket-stats-response.model.d.ts +7 -7
- package/dist/ticket/models/achievement-ticket-stats.model.d.ts +7 -7
- package/dist/ticket/models/game-ticket-stats.model.d.ts +9 -9
- package/dist/ticket/models/game-tickets-response.model.d.ts +7 -7
- package/dist/ticket/models/index.d.ts +12 -12
- package/dist/ticket/models/most-ticketed-games-response.model.d.ts +12 -12
- package/dist/ticket/models/most-ticketed-games.model.d.ts +11 -11
- package/dist/ticket/models/recent-tickets-response.model.d.ts +6 -6
- package/dist/ticket/models/recent-tickets.model.d.ts +6 -6
- package/dist/ticket/models/response-ticket-entity.model.d.ts +24 -24
- package/dist/ticket/models/ticket-entity.model.d.ts +24 -24
- package/dist/ticket/models/tickets-by-user-response.model.d.ts +8 -8
- package/dist/ticket/models/user-ticket-stats.model.d.ts +8 -8
- package/dist/user/getAchievementsEarnedBetween.d.ts +59 -59
- package/dist/user/getAchievementsEarnedBetween.test.d.ts +1 -1
- package/dist/user/getAchievementsEarnedOnDay.d.ts +57 -57
- package/dist/user/getAchievementsEarnedOnDay.test.d.ts +1 -1
- package/dist/user/getGameInfoAndUserProgress.d.ts +81 -81
- package/dist/user/getGameInfoAndUserProgress.test.d.ts +1 -1
- package/dist/user/getUserAwards.d.ts +49 -47
- package/dist/user/getUserAwards.test.d.ts +1 -1
- package/dist/user/getUserClaims.d.ts +27 -27
- package/dist/user/getUserClaims.test.d.ts +1 -1
- package/dist/user/getUserCompletedGames.d.ts +56 -56
- package/dist/user/getUserCompletedGames.test.d.ts +1 -1
- package/dist/user/getUserCompletionProgress.d.ts +51 -0
- package/dist/user/getUserCompletionProgress.test.d.ts +1 -0
- package/dist/user/getUserGameRankAndScore.d.ts +45 -45
- package/dist/user/getUserGameRankAndScore.test.d.ts +1 -1
- package/dist/user/getUserPoints.d.ts +30 -30
- package/dist/user/getUserPoints.test.d.ts +1 -1
- package/dist/user/getUserProfile.d.ts +24 -0
- package/dist/user/getUserProfile.test.d.ts +1 -0
- package/dist/user/getUserProgress.d.ts +50 -50
- package/dist/user/getUserProgress.test.d.ts +1 -1
- package/dist/user/getUserRecentAchievements.d.ts +49 -49
- package/dist/user/getUserRecentAchievements.test.d.ts +1 -1
- package/dist/user/getUserRecentlyPlayedGames.d.ts +50 -50
- package/dist/user/getUserRecentlyPlayedGames.test.d.ts +1 -1
- package/dist/user/getUserSummary.d.ts +32 -32
- package/dist/user/getUserSummary.test.d.ts +1 -1
- package/dist/user/index.d.ts +15 -13
- package/dist/user/models/award-type.model.d.ts +1 -1
- package/dist/user/models/dated-user-achievement.model.d.ts +17 -17
- package/dist/user/models/dated-user-achievements-response.model.d.ts +19 -19
- package/dist/user/models/game-info-and-user-progress.model.d.ts +12 -12
- package/dist/user/models/get-game-info-and-user-progress-response.model.d.ts +14 -14
- package/dist/user/models/get-user-awards-response.model.d.ts +24 -22
- package/dist/user/models/get-user-completed-games-response.model.d.ts +13 -13
- package/dist/user/models/get-user-completion-progress-response.model.d.ts +19 -0
- package/dist/user/models/get-user-game-rank-and-score-response.model.d.ts +8 -8
- package/dist/user/models/get-user-points-response.model.d.ts +4 -4
- package/dist/user/models/get-user-profile-response.model.d.ts +17 -0
- package/dist/user/models/get-user-progress-response.model.d.ts +10 -10
- package/dist/user/models/get-user-recent-achievements-response.model.d.ts +18 -18
- package/dist/user/models/get-user-recently-played-games-response.model.d.ts +17 -17
- package/dist/user/models/get-user-summary-response.model.d.ts +82 -82
- package/dist/user/models/index.d.ts +28 -23
- package/dist/user/models/user-awards.model.d.ts +24 -22
- package/dist/user/models/user-claims-response.model.d.ts +19 -19
- package/dist/user/models/user-claims.model.d.ts +19 -19
- package/dist/user/models/user-completed-games.model.d.ts +12 -12
- package/dist/user/models/user-completion-progress-entity.model.d.ts +13 -0
- package/dist/user/models/user-completion-progress.model.d.ts +6 -0
- package/dist/user/models/user-game-rank-and-score.model.d.ts +7 -7
- package/dist/user/models/user-points.model.d.ts +4 -4
- package/dist/user/models/user-profile.model.d.ts +17 -0
- package/dist/user/models/user-progress.model.d.ts +9 -9
- package/dist/user/models/user-recent-achievement.model.d.ts +16 -16
- package/dist/user/models/user-recently-played-games.model.d.ts +16 -16
- package/dist/user/models/user-summary.model.d.ts +82 -82
- package/dist/utils/internal/apiBaseUrl.d.ts +1 -1
- package/dist/utils/internal/buildRequestUrl.d.ts +2 -2
- package/dist/utils/internal/buildRequestUrl.test.d.ts +1 -1
- package/dist/utils/internal/call.d.ts +11 -20
- package/dist/utils/internal/call.test.d.ts +1 -1
- package/dist/utils/internal/id.model.d.ts +1 -1
- package/dist/utils/internal/index.d.ts +5 -5
- package/dist/utils/internal/serializeProperties.d.ts +4 -4
- package/dist/utils/internal/serializeProperties.test.d.ts +1 -1
- package/dist/utils/public/buildAuthorization.d.ts +22 -22
- package/dist/utils/public/buildAuthorization.test.d.ts +1 -1
- package/dist/utils/public/index.d.ts +3 -3
- package/dist/utils/public/models/auth-object.model.d.ts +19 -19
- package/dist/utils/public/models/index.d.ts +1 -1
- package/package.json +24 -31
- package/src/achievement/getAchievementUnlocks.test.ts +9 -12
- package/src/console/getConsoleIds.test.ts +3 -3
- package/src/console/getGameList.test.ts +3 -3
- package/src/feed/getAchievementOfTheWeek.test.ts +5 -5
- package/src/feed/getActiveClaims.test.ts +3 -3
- package/src/feed/getClaims.test.ts +3 -3
- package/src/feed/getTopTenUsers.test.ts +3 -3
- package/src/game/getAchievementCount.test.ts +3 -3
- package/src/game/getAchievementDistribution.test.ts +33 -44
- package/src/game/getGame.test.ts +4 -4
- package/src/game/getGame.ts +2 -8
- package/src/game/getGameExtended.test.ts +4 -4
- package/src/game/getGameExtended.ts +13 -8
- package/src/game/getGameRankAndScore.test.ts +3 -3
- package/src/game/getGameRating.test.ts +3 -3
- package/src/game/models/game-extended.model.ts +1 -1
- package/src/game/models/game.model.ts +1 -1
- package/src/ticket/getTicketData.test.ts +13 -13
- package/src/user/getAchievementsEarnedBetween.test.ts +3 -4
- package/src/user/getAchievementsEarnedOnDay.test.ts +3 -4
- package/src/user/getGameInfoAndUserProgress.test.ts +3 -4
- package/src/user/getUserAwards.test.ts +7 -3
- package/src/user/getUserAwards.ts +2 -0
- package/src/user/getUserClaims.test.ts +3 -3
- package/src/user/getUserCompletedGames.test.ts +3 -3
- package/src/user/getUserCompletionProgress.test.ts +81 -0
- package/src/user/getUserCompletionProgress.ts +83 -0
- package/src/user/getUserGameRankAndScore.test.ts +3 -3
- package/src/user/getUserPoints.test.ts +3 -3
- package/src/user/getUserProfile.test.ts +79 -0
- package/src/user/getUserProfile.ts +55 -0
- package/src/user/getUserProgress.test.ts +3 -3
- package/src/user/getUserRecentAchievements.test.ts +3 -4
- package/src/user/getUserRecentlyPlayedGames.test.ts +3 -4
- package/src/user/getUserSummary.test.ts +5 -5
- package/src/user/getUserSummary.ts +1 -3
- package/src/user/index.ts +2 -0
- package/src/user/models/award-type.model.ts +5 -4
- package/src/user/models/get-user-awards-response.model.ts +2 -0
- package/src/user/models/get-user-completion-progress-response.model.ts +25 -0
- package/src/user/models/get-user-profile-response.model.ts +17 -0
- package/src/user/models/index.ts +5 -0
- package/src/user/models/user-awards.model.ts +2 -0
- package/src/user/models/user-completion-progress-entity.model.ts +19 -0
- package/src/user/models/user-completion-progress.model.ts +7 -0
- package/src/user/models/user-profile.model.ts +17 -0
- package/src/utils/internal/buildRequestUrl.ts +1 -1
- package/src/utils/internal/call.test.ts +9 -10
- package/src/utils/internal/call.ts +1 -12
- package/src/utils/internal/serializeProperties.ts +4 -4
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
import type { AuthObject } from "../utils/public";
|
|
2
|
-
import type { DatedUserAchievement } from "./models";
|
|
3
|
-
/**
|
|
4
|
-
* A call to this function will retrieve a list of achievements
|
|
5
|
-
* earned by a given user between two provided dates.
|
|
6
|
-
*
|
|
7
|
-
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
-
* This can be constructed with `buildAuthorization()`.
|
|
9
|
-
*
|
|
10
|
-
* @param payload.userName The user for which to retrieve the
|
|
11
|
-
* list of achievements for.
|
|
12
|
-
*
|
|
13
|
-
* @param payload.fromDate A Date object specifying when
|
|
14
|
-
* the list itself should begin.
|
|
15
|
-
*
|
|
16
|
-
* @param payload.toDate A Date object specifying when
|
|
17
|
-
* the list itself should end.
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* ```
|
|
21
|
-
* const achievementsEarnedBetween = await getAchievementsEarnedBetween(
|
|
22
|
-
* authorization,
|
|
23
|
-
* {
|
|
24
|
-
* userName: "xelnia",
|
|
25
|
-
* fromDate: new Date("2022-10-12"),
|
|
26
|
-
* toDate: new Date("2022-10-13")
|
|
27
|
-
* }
|
|
28
|
-
* );
|
|
29
|
-
* ```
|
|
30
|
-
*
|
|
31
|
-
* @returns An array containing metadata about the user
|
|
32
|
-
* achievements earned during the specified date range.
|
|
33
|
-
* ```
|
|
34
|
-
* [
|
|
35
|
-
* {
|
|
36
|
-
* date: '2022-10-12 07:58:05',
|
|
37
|
-
* hardcoreMode: true,
|
|
38
|
-
* achievementId: 173315,
|
|
39
|
-
* title: 'Your Puny Human Weapons',
|
|
40
|
-
* description: 'Collect all objects in the Weapons Category.',
|
|
41
|
-
* badgeName: '193756',
|
|
42
|
-
* points: 10,
|
|
43
|
-
* author: 'blendedsea',
|
|
44
|
-
* gameTitle: 'Me & My Katamari',
|
|
45
|
-
* gameIcon: '/Images/047357.png',
|
|
46
|
-
* gameId: 3571,
|
|
47
|
-
* consoleName: 'PlayStation Portable',
|
|
48
|
-
* cumulScore: 120,
|
|
49
|
-
* badgeUrl: '/Badge/193756.png',
|
|
50
|
-
* gameUrl: '/game/3571'
|
|
51
|
-
* }
|
|
52
|
-
* ]
|
|
53
|
-
* ```
|
|
54
|
-
*/
|
|
55
|
-
export declare const getAchievementsEarnedBetween: (authorization: AuthObject, payload: {
|
|
56
|
-
userName: string;
|
|
57
|
-
fromDate: Date;
|
|
58
|
-
toDate: Date;
|
|
59
|
-
}) => Promise<DatedUserAchievement[]>;
|
|
1
|
+
import type { AuthObject } from "../utils/public";
|
|
2
|
+
import type { DatedUserAchievement } from "./models";
|
|
3
|
+
/**
|
|
4
|
+
* A call to this function will retrieve a list of achievements
|
|
5
|
+
* earned by a given user between two provided dates.
|
|
6
|
+
*
|
|
7
|
+
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
+
* This can be constructed with `buildAuthorization()`.
|
|
9
|
+
*
|
|
10
|
+
* @param payload.userName The user for which to retrieve the
|
|
11
|
+
* list of achievements for.
|
|
12
|
+
*
|
|
13
|
+
* @param payload.fromDate A Date object specifying when
|
|
14
|
+
* the list itself should begin.
|
|
15
|
+
*
|
|
16
|
+
* @param payload.toDate A Date object specifying when
|
|
17
|
+
* the list itself should end.
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* ```
|
|
21
|
+
* const achievementsEarnedBetween = await getAchievementsEarnedBetween(
|
|
22
|
+
* authorization,
|
|
23
|
+
* {
|
|
24
|
+
* userName: "xelnia",
|
|
25
|
+
* fromDate: new Date("2022-10-12"),
|
|
26
|
+
* toDate: new Date("2022-10-13")
|
|
27
|
+
* }
|
|
28
|
+
* );
|
|
29
|
+
* ```
|
|
30
|
+
*
|
|
31
|
+
* @returns An array containing metadata about the user
|
|
32
|
+
* achievements earned during the specified date range.
|
|
33
|
+
* ```
|
|
34
|
+
* [
|
|
35
|
+
* {
|
|
36
|
+
* date: '2022-10-12 07:58:05',
|
|
37
|
+
* hardcoreMode: true,
|
|
38
|
+
* achievementId: 173315,
|
|
39
|
+
* title: 'Your Puny Human Weapons',
|
|
40
|
+
* description: 'Collect all objects in the Weapons Category.',
|
|
41
|
+
* badgeName: '193756',
|
|
42
|
+
* points: 10,
|
|
43
|
+
* author: 'blendedsea',
|
|
44
|
+
* gameTitle: 'Me & My Katamari',
|
|
45
|
+
* gameIcon: '/Images/047357.png',
|
|
46
|
+
* gameId: 3571,
|
|
47
|
+
* consoleName: 'PlayStation Portable',
|
|
48
|
+
* cumulScore: 120,
|
|
49
|
+
* badgeUrl: '/Badge/193756.png',
|
|
50
|
+
* gameUrl: '/game/3571'
|
|
51
|
+
* }
|
|
52
|
+
* ]
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
export declare const getAchievementsEarnedBetween: (authorization: AuthObject, payload: {
|
|
56
|
+
userName: string;
|
|
57
|
+
fromDate: Date;
|
|
58
|
+
toDate: Date;
|
|
59
|
+
}) => Promise<DatedUserAchievement[]>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import type { AuthObject } from "../utils/public";
|
|
2
|
-
import type { DatedUserAchievement } from "./models";
|
|
3
|
-
/**
|
|
4
|
-
* A call to this function will retrieve a list of achievements
|
|
5
|
-
* earned by a given user on a specified date.
|
|
6
|
-
*
|
|
7
|
-
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
-
* This can be constructed with `buildAuthorization()`.
|
|
9
|
-
*
|
|
10
|
-
* @param payload.userName The user for which to retrieve the
|
|
11
|
-
* list of achievements for.
|
|
12
|
-
*
|
|
13
|
-
* @param payload.fromDate A Date object specifying when
|
|
14
|
-
* the list itself should begin.
|
|
15
|
-
*
|
|
16
|
-
* @param payload.onDate A Date object specifying the day
|
|
17
|
-
* to query for a user's earned achievements.
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* ```
|
|
21
|
-
* const achievementsEarnedOnDay = await getAchievementsEarnedOnDay(
|
|
22
|
-
* authorization,
|
|
23
|
-
* {
|
|
24
|
-
* userName: "xelnia",
|
|
25
|
-
* onDate: new Date("2022-10-13")
|
|
26
|
-
* }
|
|
27
|
-
* );
|
|
28
|
-
* ```
|
|
29
|
-
*
|
|
30
|
-
* @returns An array containing metadata about the user
|
|
31
|
-
* achievements earned on the specified day.
|
|
32
|
-
* ```
|
|
33
|
-
* [
|
|
34
|
-
* {
|
|
35
|
-
* date: '2022-10-12 07:58:05',
|
|
36
|
-
* hardcoreMode: true,
|
|
37
|
-
* achievementId: 173315,
|
|
38
|
-
* title: 'Your Puny Human Weapons',
|
|
39
|
-
* description: 'Collect all objects in the Weapons Category.',
|
|
40
|
-
* badgeName: '193756',
|
|
41
|
-
* points: 10,
|
|
42
|
-
* author: 'blendedsea',
|
|
43
|
-
* gameTitle: 'Me & My Katamari',
|
|
44
|
-
* gameIcon: '/Images/047357.png',
|
|
45
|
-
* gameId: 3571,
|
|
46
|
-
* consoleName: 'PlayStation Portable',
|
|
47
|
-
* cumulScore: 120,
|
|
48
|
-
* badgeUrl: '/Badge/193756.png',
|
|
49
|
-
* gameUrl: '/game/3571'
|
|
50
|
-
* }
|
|
51
|
-
* ]
|
|
52
|
-
* ```
|
|
53
|
-
*/
|
|
54
|
-
export declare const getAchievementsEarnedOnDay: (authorization: AuthObject, payload: {
|
|
55
|
-
userName: string;
|
|
56
|
-
onDate: Date;
|
|
57
|
-
}) => Promise<DatedUserAchievement[]>;
|
|
1
|
+
import type { AuthObject } from "../utils/public";
|
|
2
|
+
import type { DatedUserAchievement } from "./models";
|
|
3
|
+
/**
|
|
4
|
+
* A call to this function will retrieve a list of achievements
|
|
5
|
+
* earned by a given user on a specified date.
|
|
6
|
+
*
|
|
7
|
+
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
+
* This can be constructed with `buildAuthorization()`.
|
|
9
|
+
*
|
|
10
|
+
* @param payload.userName The user for which to retrieve the
|
|
11
|
+
* list of achievements for.
|
|
12
|
+
*
|
|
13
|
+
* @param payload.fromDate A Date object specifying when
|
|
14
|
+
* the list itself should begin.
|
|
15
|
+
*
|
|
16
|
+
* @param payload.onDate A Date object specifying the day
|
|
17
|
+
* to query for a user's earned achievements.
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* ```
|
|
21
|
+
* const achievementsEarnedOnDay = await getAchievementsEarnedOnDay(
|
|
22
|
+
* authorization,
|
|
23
|
+
* {
|
|
24
|
+
* userName: "xelnia",
|
|
25
|
+
* onDate: new Date("2022-10-13")
|
|
26
|
+
* }
|
|
27
|
+
* );
|
|
28
|
+
* ```
|
|
29
|
+
*
|
|
30
|
+
* @returns An array containing metadata about the user
|
|
31
|
+
* achievements earned on the specified day.
|
|
32
|
+
* ```
|
|
33
|
+
* [
|
|
34
|
+
* {
|
|
35
|
+
* date: '2022-10-12 07:58:05',
|
|
36
|
+
* hardcoreMode: true,
|
|
37
|
+
* achievementId: 173315,
|
|
38
|
+
* title: 'Your Puny Human Weapons',
|
|
39
|
+
* description: 'Collect all objects in the Weapons Category.',
|
|
40
|
+
* badgeName: '193756',
|
|
41
|
+
* points: 10,
|
|
42
|
+
* author: 'blendedsea',
|
|
43
|
+
* gameTitle: 'Me & My Katamari',
|
|
44
|
+
* gameIcon: '/Images/047357.png',
|
|
45
|
+
* gameId: 3571,
|
|
46
|
+
* consoleName: 'PlayStation Portable',
|
|
47
|
+
* cumulScore: 120,
|
|
48
|
+
* badgeUrl: '/Badge/193756.png',
|
|
49
|
+
* gameUrl: '/game/3571'
|
|
50
|
+
* }
|
|
51
|
+
* ]
|
|
52
|
+
* ```
|
|
53
|
+
*/
|
|
54
|
+
export declare const getAchievementsEarnedOnDay: (authorization: AuthObject, payload: {
|
|
55
|
+
userName: string;
|
|
56
|
+
onDate: Date;
|
|
57
|
+
}) => Promise<DatedUserAchievement[]>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,81 +1,81 @@
|
|
|
1
|
-
import type { ID } from "../utils/internal";
|
|
2
|
-
import type { AuthObject } from "../utils/public";
|
|
3
|
-
import type { GameInfoAndUserProgress } from "./models";
|
|
4
|
-
/**
|
|
5
|
-
* A call to this function will retrieve extended metadata
|
|
6
|
-
* about a game, in addition to a user's progress about a game.
|
|
7
|
-
* This is targeted via a game's unique ID and a given username.
|
|
8
|
-
*
|
|
9
|
-
* @param authorization An object containing your userName and webApiKey.
|
|
10
|
-
* This can be constructed with `buildAuthorization()`.
|
|
11
|
-
*
|
|
12
|
-
* @param payload.gameId The unique game ID. If you are unsure, open the
|
|
13
|
-
* game's page on the RetroAchievements.org website. For example, Dragster's
|
|
14
|
-
* URL is https://retroachievements.org/game/14402. We can see from the
|
|
15
|
-
* URL that the game ID is "14402".
|
|
16
|
-
*
|
|
17
|
-
* @param payload.userName The user for which to retrieve the
|
|
18
|
-
* game progress for.
|
|
19
|
-
*
|
|
20
|
-
* @example
|
|
21
|
-
* ```
|
|
22
|
-
* const gameInfoAndUserProgress = await getGameInfoAndUserProgress(
|
|
23
|
-
* authorization,
|
|
24
|
-
* { gameId: 14402, userName: "wv_pinball" }
|
|
25
|
-
* );
|
|
26
|
-
* ```
|
|
27
|
-
*
|
|
28
|
-
* @returns An object containing extended metadata about a target game,
|
|
29
|
-
* with attached progress for a target username.
|
|
30
|
-
* ```json
|
|
31
|
-
* {
|
|
32
|
-
* id: 14402,
|
|
33
|
-
* title: "Dragster",
|
|
34
|
-
* consoleId: 25,
|
|
35
|
-
* forumTopicId: 9145,
|
|
36
|
-
* flags: 0,
|
|
37
|
-
* imageIcon: "/Images/026368.png",
|
|
38
|
-
* imageTitle: "/Images/026366.png",
|
|
39
|
-
* imageIngame: "/Images/026367.png",
|
|
40
|
-
* imageBoxArt: "/Images/026365.png",
|
|
41
|
-
* publisher: "Activision",
|
|
42
|
-
* developer: "David Crane",
|
|
43
|
-
* genre: "Racing",
|
|
44
|
-
* released: 1980,
|
|
45
|
-
* isFinal: false,
|
|
46
|
-
* consoleName: "Atari 2600",
|
|
47
|
-
* richPresencePatch: "2b92fa1bf9635c303b3b7f8feea3ed3c",
|
|
48
|
-
* numAchievements: 12,
|
|
49
|
-
* numDistinctPlayersCasual: 454,
|
|
50
|
-
* numDistinctPlayersHardcore, 323
|
|
51
|
-
* claims: [],
|
|
52
|
-
* achievements: {
|
|
53
|
-
* '79434': {
|
|
54
|
-
* id: 79434,
|
|
55
|
-
* numAwarded: 338,
|
|
56
|
-
* numAwardedHardcore: 253,
|
|
57
|
-
* title: "Novice Dragster Driver 1",
|
|
58
|
-
* description: "Complete your very first race in game 1.",
|
|
59
|
-
* points: 1,
|
|
60
|
-
* trueRatio: 1,
|
|
61
|
-
* author: "Boldewin",
|
|
62
|
-
* dateModified: "2019-08-01 19:03:46",
|
|
63
|
-
* dateCreated: "2019-07-31 18:49:57",
|
|
64
|
-
* badgeName: "85541",
|
|
65
|
-
* displayOrder: 0,
|
|
66
|
-
* memAddr: "f5c41fa0b5fa0d5fbb8a74c598f18582",
|
|
67
|
-
* dateEarned: '2022-08-23 22:56:38',
|
|
68
|
-
* dateEarnedHardcore: '2022-08-23 22:56:38'
|
|
69
|
-
* }
|
|
70
|
-
* },
|
|
71
|
-
* numAwardedToUser: 12,
|
|
72
|
-
* numAwardedToUserHardcore: 12,
|
|
73
|
-
* userCompletion: "100.00%",
|
|
74
|
-
* userCompletionHardcore: "100.00%"
|
|
75
|
-
* }
|
|
76
|
-
* ```
|
|
77
|
-
*/
|
|
78
|
-
export declare const getGameInfoAndUserProgress: (authorization: AuthObject, payload: {
|
|
79
|
-
gameId: ID;
|
|
80
|
-
userName: string;
|
|
81
|
-
}) => Promise<GameInfoAndUserProgress>;
|
|
1
|
+
import type { ID } from "../utils/internal";
|
|
2
|
+
import type { AuthObject } from "../utils/public";
|
|
3
|
+
import type { GameInfoAndUserProgress } from "./models";
|
|
4
|
+
/**
|
|
5
|
+
* A call to this function will retrieve extended metadata
|
|
6
|
+
* about a game, in addition to a user's progress about a game.
|
|
7
|
+
* This is targeted via a game's unique ID and a given username.
|
|
8
|
+
*
|
|
9
|
+
* @param authorization An object containing your userName and webApiKey.
|
|
10
|
+
* This can be constructed with `buildAuthorization()`.
|
|
11
|
+
*
|
|
12
|
+
* @param payload.gameId The unique game ID. If you are unsure, open the
|
|
13
|
+
* game's page on the RetroAchievements.org website. For example, Dragster's
|
|
14
|
+
* URL is https://retroachievements.org/game/14402. We can see from the
|
|
15
|
+
* URL that the game ID is "14402".
|
|
16
|
+
*
|
|
17
|
+
* @param payload.userName The user for which to retrieve the
|
|
18
|
+
* game progress for.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```
|
|
22
|
+
* const gameInfoAndUserProgress = await getGameInfoAndUserProgress(
|
|
23
|
+
* authorization,
|
|
24
|
+
* { gameId: 14402, userName: "wv_pinball" }
|
|
25
|
+
* );
|
|
26
|
+
* ```
|
|
27
|
+
*
|
|
28
|
+
* @returns An object containing extended metadata about a target game,
|
|
29
|
+
* with attached progress for a target username.
|
|
30
|
+
* ```json
|
|
31
|
+
* {
|
|
32
|
+
* id: 14402,
|
|
33
|
+
* title: "Dragster",
|
|
34
|
+
* consoleId: 25,
|
|
35
|
+
* forumTopicId: 9145,
|
|
36
|
+
* flags: 0,
|
|
37
|
+
* imageIcon: "/Images/026368.png",
|
|
38
|
+
* imageTitle: "/Images/026366.png",
|
|
39
|
+
* imageIngame: "/Images/026367.png",
|
|
40
|
+
* imageBoxArt: "/Images/026365.png",
|
|
41
|
+
* publisher: "Activision",
|
|
42
|
+
* developer: "David Crane",
|
|
43
|
+
* genre: "Racing",
|
|
44
|
+
* released: 1980,
|
|
45
|
+
* isFinal: false,
|
|
46
|
+
* consoleName: "Atari 2600",
|
|
47
|
+
* richPresencePatch: "2b92fa1bf9635c303b3b7f8feea3ed3c",
|
|
48
|
+
* numAchievements: 12,
|
|
49
|
+
* numDistinctPlayersCasual: 454,
|
|
50
|
+
* numDistinctPlayersHardcore, 323
|
|
51
|
+
* claims: [],
|
|
52
|
+
* achievements: {
|
|
53
|
+
* '79434': {
|
|
54
|
+
* id: 79434,
|
|
55
|
+
* numAwarded: 338,
|
|
56
|
+
* numAwardedHardcore: 253,
|
|
57
|
+
* title: "Novice Dragster Driver 1",
|
|
58
|
+
* description: "Complete your very first race in game 1.",
|
|
59
|
+
* points: 1,
|
|
60
|
+
* trueRatio: 1,
|
|
61
|
+
* author: "Boldewin",
|
|
62
|
+
* dateModified: "2019-08-01 19:03:46",
|
|
63
|
+
* dateCreated: "2019-07-31 18:49:57",
|
|
64
|
+
* badgeName: "85541",
|
|
65
|
+
* displayOrder: 0,
|
|
66
|
+
* memAddr: "f5c41fa0b5fa0d5fbb8a74c598f18582",
|
|
67
|
+
* dateEarned: '2022-08-23 22:56:38',
|
|
68
|
+
* dateEarnedHardcore: '2022-08-23 22:56:38'
|
|
69
|
+
* }
|
|
70
|
+
* },
|
|
71
|
+
* numAwardedToUser: 12,
|
|
72
|
+
* numAwardedToUserHardcore: 12,
|
|
73
|
+
* userCompletion: "100.00%",
|
|
74
|
+
* userCompletionHardcore: "100.00%"
|
|
75
|
+
* }
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
78
|
+
export declare const getGameInfoAndUserProgress: (authorization: AuthObject, payload: {
|
|
79
|
+
gameId: ID;
|
|
80
|
+
userName: string;
|
|
81
|
+
}) => Promise<GameInfoAndUserProgress>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,47 +1,49 @@
|
|
|
1
|
-
import type { AuthObject } from "../utils/public";
|
|
2
|
-
import type { UserAwards } from "./models";
|
|
3
|
-
/**
|
|
4
|
-
* A call to this function will retrieve metadata about the target user's
|
|
5
|
-
* site awards, via their username.
|
|
6
|
-
*
|
|
7
|
-
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
-
* This can be constructed with `buildAuthorization()`.
|
|
9
|
-
*
|
|
10
|
-
* @param payload.userName The user for which to retrieve the site awards for.
|
|
11
|
-
*
|
|
12
|
-
* @example
|
|
13
|
-
* ```
|
|
14
|
-
* const userAwards = await getUserAwards(
|
|
15
|
-
* authorization,
|
|
16
|
-
* { userName: "xelnia" }
|
|
17
|
-
* )
|
|
18
|
-
* ```
|
|
19
|
-
*
|
|
20
|
-
* @returns
|
|
21
|
-
* ```json
|
|
22
|
-
* {
|
|
23
|
-
* totalAwardsCount: 10,
|
|
24
|
-
* hiddenAwardsCount: 2,
|
|
25
|
-
* masteryAwardsCount: 6,
|
|
26
|
-
* completionAwardsCount: 0,
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
1
|
+
import type { AuthObject } from "../utils/public";
|
|
2
|
+
import type { UserAwards } from "./models";
|
|
3
|
+
/**
|
|
4
|
+
* A call to this function will retrieve metadata about the target user's
|
|
5
|
+
* site awards, via their username.
|
|
6
|
+
*
|
|
7
|
+
* @param authorization An object containing your userName and webApiKey.
|
|
8
|
+
* This can be constructed with `buildAuthorization()`.
|
|
9
|
+
*
|
|
10
|
+
* @param payload.userName The user for which to retrieve the site awards for.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```
|
|
14
|
+
* const userAwards = await getUserAwards(
|
|
15
|
+
* authorization,
|
|
16
|
+
* { userName: "xelnia" }
|
|
17
|
+
* )
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* @returns
|
|
21
|
+
* ```json
|
|
22
|
+
* {
|
|
23
|
+
* totalAwardsCount: 10,
|
|
24
|
+
* hiddenAwardsCount: 2,
|
|
25
|
+
* masteryAwardsCount: 6,
|
|
26
|
+
* completionAwardsCount: 0,
|
|
27
|
+
* beatenHardcoreAwardsCount: 24,
|
|
28
|
+
* beatenSoftcoreAwardsCount: 7,
|
|
29
|
+
* eventAwardsCount: 0,
|
|
30
|
+
* siteAwardsCount: 2,
|
|
31
|
+
* visibleUserAwards: [
|
|
32
|
+
* {
|
|
33
|
+
* awardedAt: "2022-08-26T19:34:43+00:00",
|
|
34
|
+
* awardType: "Mastery/Completion",
|
|
35
|
+
* awardData: 802,
|
|
36
|
+
* awardDataExtra: 1,
|
|
37
|
+
* displayOrder: 114,
|
|
38
|
+
* title: "WarioWare, Inc.: Mega Microgames!",
|
|
39
|
+
* consoleName: "Game Boy Advance",
|
|
40
|
+
* flags: null,
|
|
41
|
+
* imageIcon: "/Images/034678.png"
|
|
42
|
+
* }
|
|
43
|
+
* ]
|
|
44
|
+
* }
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
export declare const getUserAwards: (authorization: AuthObject, payload: {
|
|
48
|
+
userName: string;
|
|
49
|
+
}) => Promise<UserAwards>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import type { AuthObject } from "../utils/public";
|
|
2
|
-
import type { UserClaims } from "./models";
|
|
3
|
-
/**
|
|
4
|
-
* A call to this function will retrieve a list of
|
|
5
|
-
* achievement set claims made over the lifetime of a given
|
|
6
|
-
* user, targeted by their username.
|
|
7
|
-
*
|
|
8
|
-
* @param authorization An object containing your userName and webApiKey.
|
|
9
|
-
* This can be constructed with `buildAuthorization()`.
|
|
10
|
-
*
|
|
11
|
-
* @param payload.userName The user for which to retrieve the historical
|
|
12
|
-
* achievement set claims list for.
|
|
13
|
-
*
|
|
14
|
-
* @example
|
|
15
|
-
* ```
|
|
16
|
-
* const userClaims = await getUserClaims(
|
|
17
|
-
* authorization,
|
|
18
|
-
* { userName: "Jamiras" }
|
|
19
|
-
* );
|
|
20
|
-
* ```
|
|
21
|
-
*
|
|
22
|
-
* @returns An array containing all the achievement set claims
|
|
23
|
-
* made over the lifetime of the given user.
|
|
24
|
-
*/
|
|
25
|
-
export declare const getUserClaims: (authorization: AuthObject, payload: {
|
|
26
|
-
userName: string;
|
|
27
|
-
}) => Promise<UserClaims>;
|
|
1
|
+
import type { AuthObject } from "../utils/public";
|
|
2
|
+
import type { UserClaims } from "./models";
|
|
3
|
+
/**
|
|
4
|
+
* A call to this function will retrieve a list of
|
|
5
|
+
* achievement set claims made over the lifetime of a given
|
|
6
|
+
* user, targeted by their username.
|
|
7
|
+
*
|
|
8
|
+
* @param authorization An object containing your userName and webApiKey.
|
|
9
|
+
* This can be constructed with `buildAuthorization()`.
|
|
10
|
+
*
|
|
11
|
+
* @param payload.userName The user for which to retrieve the historical
|
|
12
|
+
* achievement set claims list for.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```
|
|
16
|
+
* const userClaims = await getUserClaims(
|
|
17
|
+
* authorization,
|
|
18
|
+
* { userName: "Jamiras" }
|
|
19
|
+
* );
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
* @returns An array containing all the achievement set claims
|
|
23
|
+
* made over the lifetime of the given user.
|
|
24
|
+
*/
|
|
25
|
+
export declare const getUserClaims: (authorization: AuthObject, payload: {
|
|
26
|
+
userName: string;
|
|
27
|
+
}) => Promise<UserClaims>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|