@playcademy/sdk 0.0.1-beta.4 → 0.0.1-beta.6
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/dist/core/client.d.ts +14 -14
- package/dist/core/request.d.ts +1 -1
- package/dist/runtime.js +1 -7065
- package/dist/types.d.ts +1 -1
- package/package.json +5 -4
package/dist/core/client.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Method } from './request';
|
|
2
|
-
import {
|
|
2
|
+
import type { Game, GameWithManifest, UpsertGameMetadataInput, InsertReward, UpdateReward } from '@playcademy/types';
|
|
3
3
|
import type { GameState, InventoryItemWithReward, ClientConfig, ClientEvents, LoginResponse, GameTokenResponse, StartSessionResponse, InventoryMutationResponse, DeveloperStatusValue } from '../types';
|
|
4
4
|
export declare class PlaycademyClient {
|
|
5
5
|
private baseUrl;
|
|
@@ -36,6 +36,8 @@ export declare class PlaycademyClient {
|
|
|
36
36
|
users: {
|
|
37
37
|
me: () => Promise<{
|
|
38
38
|
id: string;
|
|
39
|
+
createdAt: Date;
|
|
40
|
+
updatedAt: Date;
|
|
39
41
|
name: string;
|
|
40
42
|
username: string | null;
|
|
41
43
|
email: string;
|
|
@@ -43,8 +45,6 @@ export declare class PlaycademyClient {
|
|
|
43
45
|
image: string | null;
|
|
44
46
|
role: "admin" | "player" | "developer";
|
|
45
47
|
developerStatus: "none" | "pending" | "approved";
|
|
46
|
-
createdAt: Date;
|
|
47
|
-
updatedAt: Date;
|
|
48
48
|
}>;
|
|
49
49
|
inventory: {
|
|
50
50
|
get: () => Promise<InventoryItemWithReward[]>;
|
|
@@ -83,15 +83,15 @@ export declare class PlaycademyClient {
|
|
|
83
83
|
maps: {
|
|
84
84
|
elements: (mapId: string) => Promise<{
|
|
85
85
|
id: string;
|
|
86
|
-
mapId: string | null;
|
|
87
|
-
elementSlug: string;
|
|
88
|
-
interactionType: "game_entry" | "game_registry" | "info" | "teleport" | "door_in" | "door_out" | "npc_interaction" | "quest_trigger";
|
|
89
86
|
metadata: ({
|
|
90
87
|
description?: string | undefined;
|
|
91
88
|
sourceTiledObjects?: Record<string, unknown>[] | undefined;
|
|
92
89
|
} & {
|
|
93
90
|
[k: string]: unknown;
|
|
94
91
|
}) | null;
|
|
92
|
+
mapId: string | null;
|
|
93
|
+
elementSlug: string;
|
|
94
|
+
interactionType: "game_entry" | "game_registry" | "info" | "teleport" | "door_in" | "door_out" | "npc_interaction" | "quest_trigger";
|
|
95
95
|
gameId: string | null;
|
|
96
96
|
}[]>;
|
|
97
97
|
};
|
|
@@ -103,35 +103,35 @@ export declare class PlaycademyClient {
|
|
|
103
103
|
rewards: {
|
|
104
104
|
createReward: (props: InsertReward) => Promise<{
|
|
105
105
|
id: string;
|
|
106
|
-
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
107
106
|
displayName: string;
|
|
108
|
-
description: string | null;
|
|
109
107
|
metadata: unknown;
|
|
110
108
|
internalName: string;
|
|
109
|
+
description: string | null;
|
|
110
|
+
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
111
111
|
}>;
|
|
112
112
|
getReward: (rewardId: string) => Promise<{
|
|
113
113
|
id: string;
|
|
114
|
-
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
115
114
|
displayName: string;
|
|
116
|
-
description: string | null;
|
|
117
115
|
metadata: unknown;
|
|
118
116
|
internalName: string;
|
|
117
|
+
description: string | null;
|
|
118
|
+
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
119
119
|
}>;
|
|
120
120
|
listRewards: () => Promise<{
|
|
121
121
|
id: string;
|
|
122
|
-
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
123
122
|
displayName: string;
|
|
124
|
-
description: string | null;
|
|
125
123
|
metadata: unknown;
|
|
126
124
|
internalName: string;
|
|
125
|
+
description: string | null;
|
|
126
|
+
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
127
127
|
}[]>;
|
|
128
128
|
updateReward: (rewardId: string, props: UpdateReward) => Promise<{
|
|
129
129
|
id: string;
|
|
130
|
-
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
131
130
|
displayName: string;
|
|
132
|
-
description: string | null;
|
|
133
131
|
metadata: unknown;
|
|
134
132
|
internalName: string;
|
|
133
|
+
description: string | null;
|
|
134
|
+
type: "currency" | "badge" | "trophy" | "unlock" | "upgrade" | "other";
|
|
135
135
|
}>;
|
|
136
136
|
deleteReward: (rewardId: string) => Promise<void>;
|
|
137
137
|
};
|
package/dist/core/request.d.ts
CHANGED