glitch-javascript-sdk 1.1.8 → 1.1.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 +74 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Communities.d.ts +48 -0
- package/dist/esm/api/Influencers.d.ts +8 -0
- package/dist/esm/index.js +74 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +56 -0
- package/package.json +1 -1
- package/src/api/Communities.ts +66 -0
- package/src/api/Influencers.ts +11 -0
- package/src/routes/CommunitiesRoute.ts +5 -0
- package/src/routes/InfluencerRoutes.ts +1 -0
|
@@ -290,5 +290,53 @@ declare class Communities {
|
|
|
290
290
|
* @returns promise
|
|
291
291
|
*/
|
|
292
292
|
static clearHellosignAuth<T>(community_id: string): AxiosPromise<Response<T>>;
|
|
293
|
+
/**
|
|
294
|
+
* List all the saved email templates for the community.
|
|
295
|
+
*
|
|
296
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/resourceCommunityList
|
|
297
|
+
*
|
|
298
|
+
* @returns promise
|
|
299
|
+
*/
|
|
300
|
+
static listEmailTemplates<T>(community_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
301
|
+
/**
|
|
302
|
+
* Create a new email template for the community
|
|
303
|
+
*
|
|
304
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/newCommunityResourceStorage
|
|
305
|
+
*
|
|
306
|
+
* @param data The data to be passed when creating a community.
|
|
307
|
+
*
|
|
308
|
+
* @returns Promise
|
|
309
|
+
*/
|
|
310
|
+
static createEmailTemplate<T>(community_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
311
|
+
/**
|
|
312
|
+
* Update an email template for the community.
|
|
313
|
+
*
|
|
314
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/updateCommunityStorage
|
|
315
|
+
*
|
|
316
|
+
* @param community_id The id of the community to update.
|
|
317
|
+
* @param data The data to update.
|
|
318
|
+
*
|
|
319
|
+
* @returns promise
|
|
320
|
+
*/
|
|
321
|
+
static updateEmailTemplate<T>(community_id: string, template_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
322
|
+
/**
|
|
323
|
+
* Retrieve a single email template for the community.
|
|
324
|
+
*
|
|
325
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/showCommunityStorage
|
|
326
|
+
*
|
|
327
|
+
* @param community_id The id fo the community to retrieve.
|
|
328
|
+
*
|
|
329
|
+
* @returns promise
|
|
330
|
+
*/
|
|
331
|
+
static viewEmailTemplate<T>(community_id: string, template_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
332
|
+
/**
|
|
333
|
+
* Deletes an email template for the community.
|
|
334
|
+
*
|
|
335
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/destoryCommunityStorage
|
|
336
|
+
*
|
|
337
|
+
* @param community_id The id of the community to delete.
|
|
338
|
+
* @returns promise
|
|
339
|
+
*/
|
|
340
|
+
static deleteEmailTemplate<T>(community_id: string, template_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
293
341
|
}
|
|
294
342
|
export default Communities;
|
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import Response from "../util/Response";
|
|
2
2
|
import { AxiosPromise } from "axios";
|
|
3
3
|
declare class Influencers {
|
|
4
|
+
/**
|
|
5
|
+
* Add a new influencer to the platform.
|
|
6
|
+
*
|
|
7
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/createInfluencersNotes
|
|
8
|
+
*
|
|
9
|
+
* @returns promise
|
|
10
|
+
*/
|
|
11
|
+
static addInfluencer<T>(data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
4
12
|
/**
|
|
5
13
|
* Get a list of influencers available on he platform.
|
|
6
14
|
*
|
package/dist/esm/index.js
CHANGED
|
@@ -6576,6 +6576,11 @@ var CommunitiesRoute = /** @class */ (function () {
|
|
|
6576
6576
|
clearDocusignAuth: { url: '/communities/{community_id}/clearDocusignAuth', method: HTTP_METHODS.DELETE },
|
|
6577
6577
|
clearHellosignAuth: { url: '/communities/{community_id}/clearHellosignAuth', method: HTTP_METHODS.DELETE },
|
|
6578
6578
|
clearSimplesignAuth: { url: '/communities/{community_id}/clearSimplesignAuth', method: HTTP_METHODS.DELETE },
|
|
6579
|
+
listEmailTemplates: { url: '/communities/{community_id}/emails/templates', method: HTTP_METHODS.GET },
|
|
6580
|
+
createEmailTemplate: { url: '/communities/{community_id}/emails/templates', method: HTTP_METHODS.POST },
|
|
6581
|
+
viewEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.GET },
|
|
6582
|
+
updateEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.PUT },
|
|
6583
|
+
deleteEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.DELETE },
|
|
6579
6584
|
};
|
|
6580
6585
|
return CommunitiesRoute;
|
|
6581
6586
|
}());
|
|
@@ -6936,6 +6941,64 @@ var Communities = /** @class */ (function () {
|
|
|
6936
6941
|
Communities.clearHellosignAuth = function (community_id) {
|
|
6937
6942
|
return Requests.processRoute(CommunitiesRoute.routes.clearHellosignAuth, {}, { community_id: community_id });
|
|
6938
6943
|
};
|
|
6944
|
+
/**
|
|
6945
|
+
* List all the saved email templates for the community.
|
|
6946
|
+
*
|
|
6947
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/resourceCommunityList
|
|
6948
|
+
*
|
|
6949
|
+
* @returns promise
|
|
6950
|
+
*/
|
|
6951
|
+
Communities.listEmailTemplates = function (community_id, params) {
|
|
6952
|
+
return Requests.processRoute(CommunitiesRoute.routes.listEmailTemplates, undefined, { community_id: community_id }, params);
|
|
6953
|
+
};
|
|
6954
|
+
/**
|
|
6955
|
+
* Create a new email template for the community
|
|
6956
|
+
*
|
|
6957
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/newCommunityResourceStorage
|
|
6958
|
+
*
|
|
6959
|
+
* @param data The data to be passed when creating a community.
|
|
6960
|
+
*
|
|
6961
|
+
* @returns Promise
|
|
6962
|
+
*/
|
|
6963
|
+
Communities.createEmailTemplate = function (community_id, data, params) {
|
|
6964
|
+
return Requests.processRoute(CommunitiesRoute.routes.createEmailTemplate, data, { community_id: community_id }, params);
|
|
6965
|
+
};
|
|
6966
|
+
/**
|
|
6967
|
+
* Update an email template for the community.
|
|
6968
|
+
*
|
|
6969
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/updateCommunityStorage
|
|
6970
|
+
*
|
|
6971
|
+
* @param community_id The id of the community to update.
|
|
6972
|
+
* @param data The data to update.
|
|
6973
|
+
*
|
|
6974
|
+
* @returns promise
|
|
6975
|
+
*/
|
|
6976
|
+
Communities.updateEmailTemplate = function (community_id, template_id, data, params) {
|
|
6977
|
+
return Requests.processRoute(CommunitiesRoute.routes.updateEmailTemplate, data, { community_id: community_id, template_id: template_id }, params);
|
|
6978
|
+
};
|
|
6979
|
+
/**
|
|
6980
|
+
* Retrieve a single email template for the community.
|
|
6981
|
+
*
|
|
6982
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/showCommunityStorage
|
|
6983
|
+
*
|
|
6984
|
+
* @param community_id The id fo the community to retrieve.
|
|
6985
|
+
*
|
|
6986
|
+
* @returns promise
|
|
6987
|
+
*/
|
|
6988
|
+
Communities.viewEmailTemplate = function (community_id, template_id, params) {
|
|
6989
|
+
return Requests.processRoute(CommunitiesRoute.routes.viewEmailTemplate, {}, { community_id: community_id, template_id: template_id }, params);
|
|
6990
|
+
};
|
|
6991
|
+
/**
|
|
6992
|
+
* Deletes an email template for the community.
|
|
6993
|
+
*
|
|
6994
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/destoryCommunityStorage
|
|
6995
|
+
*
|
|
6996
|
+
* @param community_id The id of the community to delete.
|
|
6997
|
+
* @returns promise
|
|
6998
|
+
*/
|
|
6999
|
+
Communities.deleteEmailTemplate = function (community_id, template_id, params) {
|
|
7000
|
+
return Requests.processRoute(CommunitiesRoute.routes.deleteEmailTemplate, {}, { community_id: community_id, template_id: template_id });
|
|
7001
|
+
};
|
|
6939
7002
|
return Communities;
|
|
6940
7003
|
}());
|
|
6941
7004
|
|
|
@@ -10111,6 +10174,7 @@ var InfluencerRoutes = /** @class */ (function () {
|
|
|
10111
10174
|
function InfluencerRoutes() {
|
|
10112
10175
|
}
|
|
10113
10176
|
InfluencerRoutes.routes = {
|
|
10177
|
+
addInfluencer: { url: '/influencers', method: HTTP_METHODS.POST },
|
|
10114
10178
|
listInfluencers: { url: '/influencers', method: HTTP_METHODS.GET },
|
|
10115
10179
|
viewInfluencer: { url: '/influencers/{influencer_id}', method: HTTP_METHODS.GET },
|
|
10116
10180
|
generateProfile: { url: '/influencers/{influencer_id}/generateProfile', method: HTTP_METHODS.POST },
|
|
@@ -10126,6 +10190,16 @@ var InfluencerRoutes = /** @class */ (function () {
|
|
|
10126
10190
|
var Influencers = /** @class */ (function () {
|
|
10127
10191
|
function Influencers() {
|
|
10128
10192
|
}
|
|
10193
|
+
/**
|
|
10194
|
+
* Add a new influencer to the platform.
|
|
10195
|
+
*
|
|
10196
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/createInfluencersNotes
|
|
10197
|
+
*
|
|
10198
|
+
* @returns promise
|
|
10199
|
+
*/
|
|
10200
|
+
Influencers.addInfluencer = function (data, params) {
|
|
10201
|
+
return Requests.processRoute(InfluencerRoutes.routes.addInfluencer, data, {}, params);
|
|
10202
|
+
};
|
|
10129
10203
|
/**
|
|
10130
10204
|
* Get a list of influencers available on he platform.
|
|
10131
10205
|
*
|