glitch-javascript-sdk 2.8.0 → 2.8.2
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/cjs/index.js +35 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Newsletters.d.ts +9 -0
- package/dist/esm/api/Titles.d.ts +13 -0
- package/dist/esm/index.js +35 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +22 -0
- package/package.json +1 -1
- package/src/api/Newsletters.ts +11 -1
- package/src/api/Titles.ts +20 -0
- package/src/routes/NewslettersRoutes.ts +2 -0
- package/src/routes/TitlesRoute.ts +9 -0
package/dist/index.d.ts
CHANGED
|
@@ -4289,6 +4289,19 @@ declare class Titles {
|
|
|
4289
4289
|
* Get the total earnings and playtime summary for a title.
|
|
4290
4290
|
*/
|
|
4291
4291
|
static getDeveloperPayoutSummary<T>(title_id: string): AxiosPromise<Response<T>>;
|
|
4292
|
+
/**
|
|
4293
|
+
* The Aegis Handshake: Verify if a player is allowed to play.
|
|
4294
|
+
*
|
|
4295
|
+
* This is used by the game engine (Unity/Unreal) to confirm that the
|
|
4296
|
+
* current session is valid and the user has a proper license.
|
|
4297
|
+
*
|
|
4298
|
+
* @see https://api.glitch.fun/api/documentation#/Aegis%20Security/validateGameSession
|
|
4299
|
+
*
|
|
4300
|
+
* @param title_id The UUID of the game title.
|
|
4301
|
+
* @param install_id The UUID of the specific install/session.
|
|
4302
|
+
* @returns AxiosPromise containing { valid: boolean, user_name: string, license_type: string }
|
|
4303
|
+
*/
|
|
4304
|
+
static validateInstall<T>(title_id: string, install_id: string): AxiosPromise<Response<T>>;
|
|
4292
4305
|
}
|
|
4293
4306
|
|
|
4294
4307
|
declare class Campaigns {
|
|
@@ -5666,6 +5679,15 @@ declare class Newsletters {
|
|
|
5666
5679
|
* Permanently delete a subscriber from the system (Admin only).
|
|
5667
5680
|
*/
|
|
5668
5681
|
static deleteSubscriber<T>(id: string): AxiosPromise<Response<T>>;
|
|
5682
|
+
/**
|
|
5683
|
+
* Join the distribution platform waitlist for indie developers.
|
|
5684
|
+
*
|
|
5685
|
+
* @see https://api.glitch.fun/api/documentation#/Newsletters/joinDistributionWaitlist
|
|
5686
|
+
*
|
|
5687
|
+
* @param data { name: string, email: string, game: string, team_size: string, revenue_goal: string }
|
|
5688
|
+
* @returns Promise
|
|
5689
|
+
*/
|
|
5690
|
+
static joinDistributionWaitlist<T>(data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
5669
5691
|
}
|
|
5670
5692
|
|
|
5671
5693
|
declare class PlayTests {
|
package/package.json
CHANGED
package/src/api/Newsletters.ts
CHANGED
|
@@ -161,7 +161,17 @@ class Newsletters {
|
|
|
161
161
|
return Requests.processRoute(NewslettersRoutes.routes.deleteSubscriber, undefined, { id });
|
|
162
162
|
}
|
|
163
163
|
|
|
164
|
-
|
|
164
|
+
/**
|
|
165
|
+
* Join the distribution platform waitlist for indie developers.
|
|
166
|
+
*
|
|
167
|
+
* @see https://api.glitch.fun/api/documentation#/Newsletters/joinDistributionWaitlist
|
|
168
|
+
*
|
|
169
|
+
* @param data { name: string, email: string, game: string, team_size: string, revenue_goal: string }
|
|
170
|
+
* @returns Promise
|
|
171
|
+
*/
|
|
172
|
+
public static joinDistributionWaitlist<T>(data: object, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
173
|
+
return Requests.processRoute(NewslettersRoutes.routes.joinDistributionWaitlist, data, undefined, params);
|
|
174
|
+
}
|
|
165
175
|
|
|
166
176
|
}
|
|
167
177
|
|
package/src/api/Titles.ts
CHANGED
|
@@ -976,6 +976,26 @@ class Titles {
|
|
|
976
976
|
public static getDeveloperPayoutSummary<T>(title_id: string): AxiosPromise<Response<T>> {
|
|
977
977
|
return Requests.processRoute(TitlesRoute.routes.developerPayoutSummary, {}, { title_id });
|
|
978
978
|
}
|
|
979
|
+
|
|
980
|
+
/**
|
|
981
|
+
* The Aegis Handshake: Verify if a player is allowed to play.
|
|
982
|
+
*
|
|
983
|
+
* This is used by the game engine (Unity/Unreal) to confirm that the
|
|
984
|
+
* current session is valid and the user has a proper license.
|
|
985
|
+
*
|
|
986
|
+
* @see https://api.glitch.fun/api/documentation#/Aegis%20Security/validateGameSession
|
|
987
|
+
*
|
|
988
|
+
* @param title_id The UUID of the game title.
|
|
989
|
+
* @param install_id The UUID of the specific install/session.
|
|
990
|
+
* @returns AxiosPromise containing { valid: boolean, user_name: string, license_type: string }
|
|
991
|
+
*/
|
|
992
|
+
public static validateInstall<T>(title_id: string, install_id: string): AxiosPromise<Response<T>> {
|
|
993
|
+
return Requests.processRoute(
|
|
994
|
+
TitlesRoute.routes.validateInstall,
|
|
995
|
+
{},
|
|
996
|
+
{ title_id: title_id, install_id: install_id }
|
|
997
|
+
);
|
|
998
|
+
}
|
|
979
999
|
}
|
|
980
1000
|
|
|
981
1001
|
export default Titles;
|
|
@@ -29,6 +29,8 @@ class NewslettersRoutes {
|
|
|
29
29
|
viewSubscriber: { url: '/admin/newsletters/subscribers/{id}', method: HTTP_METHODS.GET },
|
|
30
30
|
updateSubscriber: { url: '/admin/newsletters/subscribers/{id}', method: HTTP_METHODS.PUT },
|
|
31
31
|
deleteSubscriber: { url: '/admin/newsletters/subscribers/{id}', method: HTTP_METHODS.DELETE },
|
|
32
|
+
joinDistributionWaitlist: { url: '/newsletters/joinDistributionWaitlist', method: HTTP_METHODS.POST },
|
|
33
|
+
|
|
32
34
|
};
|
|
33
35
|
|
|
34
36
|
}
|
|
@@ -190,6 +190,15 @@ class TitlesRoute {
|
|
|
190
190
|
viewDeveloperPayout: { url: '/titles/{title_id}/payouts/{payout_id}', method: HTTP_METHODS.GET },
|
|
191
191
|
developerPayoutSummary: { url: '/titles/{title_id}/payouts/summary', method: HTTP_METHODS.GET },
|
|
192
192
|
|
|
193
|
+
/**
|
|
194
|
+
* The Aegis Handshake: Validates if a specific install/session is authorized to play.
|
|
195
|
+
* POST /titles/{title_id}/installs/{install_id}/validate
|
|
196
|
+
*/
|
|
197
|
+
validateInstall: {
|
|
198
|
+
url: '/titles/{title_id}/installs/{install_id}/validate',
|
|
199
|
+
method: HTTP_METHODS.POST
|
|
200
|
+
},
|
|
201
|
+
|
|
193
202
|
};
|
|
194
203
|
|
|
195
204
|
}
|