glitch-javascript-sdk 1.9.8 → 1.9.9
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 +33 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Communities.d.ts +24 -0
- package/dist/esm/index.js +33 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +24 -0
- package/package.json +1 -1
- package/src/api/Communities.ts +33 -0
- package/src/routes/CommunitiesRoute.ts +11 -6
package/dist/index.d.ts
CHANGED
|
@@ -1706,6 +1706,30 @@ declare class Communities {
|
|
|
1706
1706
|
static importGameInstalls<T>(community_id: string, newsletter_id: string, data: {
|
|
1707
1707
|
format: 'csv' | 'xlsx';
|
|
1708
1708
|
}, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
1709
|
+
/**
|
|
1710
|
+
* Retrieve the current user's pending community invitations across all communities.
|
|
1711
|
+
*
|
|
1712
|
+
* @returns promise
|
|
1713
|
+
*/
|
|
1714
|
+
static myInvites<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
1715
|
+
/**
|
|
1716
|
+
* Resends an invitation to a user.
|
|
1717
|
+
*
|
|
1718
|
+
* @param community_id The id of the community.
|
|
1719
|
+
* @param invite_id The id of the invite to resend.
|
|
1720
|
+
*
|
|
1721
|
+
* @returns promise
|
|
1722
|
+
*/
|
|
1723
|
+
static resendInvite<T>(community_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
1724
|
+
/**
|
|
1725
|
+
* Revokes/deletes a community invitation.
|
|
1726
|
+
*
|
|
1727
|
+
* @param community_id The id of the community.
|
|
1728
|
+
* @param invite_id The id of the invite to delete.
|
|
1729
|
+
*
|
|
1730
|
+
* @returns promise
|
|
1731
|
+
*/
|
|
1732
|
+
static deleteInvite<T>(community_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
1709
1733
|
}
|
|
1710
1734
|
|
|
1711
1735
|
declare class Users {
|
package/package.json
CHANGED
package/src/api/Communities.ts
CHANGED
|
@@ -896,6 +896,39 @@ class Communities {
|
|
|
896
896
|
);
|
|
897
897
|
}
|
|
898
898
|
|
|
899
|
+
/**
|
|
900
|
+
* Retrieve the current user's pending community invitations across all communities.
|
|
901
|
+
*
|
|
902
|
+
* @returns promise
|
|
903
|
+
*/
|
|
904
|
+
public static myInvites<T>(params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
905
|
+
return Requests.processRoute(CommunitiesRoute.routes.myInvites, {}, undefined, params);
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
/**
|
|
909
|
+
* Resends an invitation to a user.
|
|
910
|
+
*
|
|
911
|
+
* @param community_id The id of the community.
|
|
912
|
+
* @param invite_id The id of the invite to resend.
|
|
913
|
+
*
|
|
914
|
+
* @returns promise
|
|
915
|
+
*/
|
|
916
|
+
public static resendInvite<T>(community_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
917
|
+
return Requests.processRoute(CommunitiesRoute.routes.resendInvite, {}, { community_id: community_id, invite_id: invite_id }, params);
|
|
918
|
+
}
|
|
919
|
+
|
|
920
|
+
/**
|
|
921
|
+
* Revokes/deletes a community invitation.
|
|
922
|
+
*
|
|
923
|
+
* @param community_id The id of the community.
|
|
924
|
+
* @param invite_id The id of the invite to delete.
|
|
925
|
+
*
|
|
926
|
+
* @returns promise
|
|
927
|
+
*/
|
|
928
|
+
public static deleteInvite<T>(community_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
929
|
+
return Requests.processRoute(CommunitiesRoute.routes.deleteInvite, {}, { community_id: community_id, invite_id: invite_id }, params);
|
|
930
|
+
}
|
|
931
|
+
|
|
899
932
|
|
|
900
933
|
}
|
|
901
934
|
|
|
@@ -17,6 +17,9 @@ class CommunitiesRoute {
|
|
|
17
17
|
acceptInvite: { url: '/communities/{community_id}/acceptInvite', method: HTTP_METHODS.POST },
|
|
18
18
|
retrieveInvite: { url: '/communities/{community_id}/invites/{token}', method: HTTP_METHODS.GET },
|
|
19
19
|
listUsers: { url: '/communities/{community_id}/users', method: HTTP_METHODS.GET },
|
|
20
|
+
myInvites: { url: '/communities/invites/mine', method: HTTP_METHODS.GET },
|
|
21
|
+
resendInvite: { url: '/communities/{community_id}/invites/{invite_id}/resend', method: HTTP_METHODS.POST },
|
|
22
|
+
deleteInvite: { url: '/communities/{community_id}/invites/{invite_id}', method: HTTP_METHODS.DELETE },
|
|
20
23
|
addUser: { url: '/communities/{community_id}/users', method: HTTP_METHODS.POST },
|
|
21
24
|
showUser: { url: '/communities/{community_id}/users/{user_id}', method: HTTP_METHODS.GET },
|
|
22
25
|
updateUser: { url: '/communities/{community_id}/users/{user_id}', method: HTTP_METHODS.PUT },
|
|
@@ -59,13 +62,13 @@ class CommunitiesRoute {
|
|
|
59
62
|
method: HTTP_METHODS.GET
|
|
60
63
|
},
|
|
61
64
|
|
|
62
|
-
exportNewsletterSubscribers: {
|
|
63
|
-
url: '/communities/{community_id}/newsletters/{newsletter_id}/subscribers/export',
|
|
64
|
-
method: HTTP_METHODS.POST
|
|
65
|
+
exportNewsletterSubscribers: {
|
|
66
|
+
url: '/communities/{community_id}/newsletters/{newsletter_id}/subscribers/export',
|
|
67
|
+
method: HTTP_METHODS.POST
|
|
65
68
|
},
|
|
66
|
-
importGameInstalls: {
|
|
67
|
-
url: '/communities/{community_id}/newsletters/{newsletter_id}/import_game_installs',
|
|
68
|
-
method: HTTP_METHODS.POST
|
|
69
|
+
importGameInstalls: {
|
|
70
|
+
url: '/communities/{community_id}/newsletters/{newsletter_id}/import_game_installs',
|
|
71
|
+
method: HTTP_METHODS.POST
|
|
69
72
|
},
|
|
70
73
|
|
|
71
74
|
// Campaigns
|
|
@@ -92,6 +95,8 @@ class CommunitiesRoute {
|
|
|
92
95
|
registerNewsletterSubscriber: { url: '/communities/{community_id}/newsletters/{newsletter_id}/subscribers', method: HTTP_METHODS.POST },
|
|
93
96
|
};
|
|
94
97
|
|
|
98
|
+
|
|
99
|
+
|
|
95
100
|
}
|
|
96
101
|
|
|
97
102
|
export default CommunitiesRoute;
|