glitch-javascript-sdk 1.6.3 → 1.6.5
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 +29 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Communities.d.ts +13 -0
- package/dist/esm/api/Funnel.d.ts +9 -0
- package/dist/esm/index.js +29 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +22 -0
- package/package.json +1 -1
- package/src/api/Communities.ts +23 -1
- package/src/api/Funnel.ts +13 -0
- package/src/routes/CommunitiesRoute.ts +5 -0
- package/src/routes/FunnelRoutes.ts +1 -0
|
@@ -581,5 +581,18 @@ declare class Communities {
|
|
|
581
581
|
* @param params Optional date-range filter (start_date, end_date, etc.)
|
|
582
582
|
*/
|
|
583
583
|
static newsletterSubscriberTrend<T>(community_id: string, newsletter_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
584
|
+
/**
|
|
585
|
+
* Export subscribers for a specific newsletter.
|
|
586
|
+
* The file is generated asynchronously on the server and
|
|
587
|
+
* the user is emailed a link to download the file.
|
|
588
|
+
*
|
|
589
|
+
* @param community_id The ID of the community.
|
|
590
|
+
* @param newsletter_id The ID of the newsletter.
|
|
591
|
+
* @param data Export options (format: 'csv' or 'xlsx').
|
|
592
|
+
* @returns Promise
|
|
593
|
+
*/
|
|
594
|
+
static exportNewsletterSubscribers<T>(community_id: string, newsletter_id: string, data: {
|
|
595
|
+
format: 'csv' | 'xlsx';
|
|
596
|
+
}, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
584
597
|
}
|
|
585
598
|
export default Communities;
|
package/dist/esm/api/Funnel.d.ts
CHANGED
|
@@ -62,5 +62,14 @@ declare class Funnel {
|
|
|
62
62
|
* @returns Promise with yearly funnel metrics data
|
|
63
63
|
*/
|
|
64
64
|
static yearly<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
65
|
+
/**
|
|
66
|
+
* Get gamified funnel metrics with recommended targets, scores, and ranks.
|
|
67
|
+
*
|
|
68
|
+
* @see https://api.glitch.fun/api/documentation#/Funnel%20Metrics/get_funnels_gamify
|
|
69
|
+
*
|
|
70
|
+
* @param params Query parameters (title_id, community_id, start_date, end_date)
|
|
71
|
+
* @returns Promise with the gamified funnel data
|
|
72
|
+
*/
|
|
73
|
+
static gamify<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
65
74
|
}
|
|
66
75
|
export default Funnel;
|
package/dist/esm/index.js
CHANGED
|
@@ -6634,6 +6634,10 @@ var CommunitiesRoute = /** @class */ (function () {
|
|
|
6634
6634
|
url: '/communities/{community_id}/newsletters/{newsletter_id}/reports/subscriber_trend',
|
|
6635
6635
|
method: HTTP_METHODS.GET
|
|
6636
6636
|
},
|
|
6637
|
+
exportNewsletterSubscribers: {
|
|
6638
|
+
url: '/communities/{community_id}/newsletters/{newsletter_id}/subscribers/export',
|
|
6639
|
+
method: HTTP_METHODS.POST
|
|
6640
|
+
},
|
|
6637
6641
|
// Campaigns
|
|
6638
6642
|
listCampaigns: { url: '/communities/{community_id}/newsletters/{newsletter_id}/campaigns', method: HTTP_METHODS.GET },
|
|
6639
6643
|
createCampaign: { url: '/communities/{community_id}/newsletters/{newsletter_id}/campaigns', method: HTTP_METHODS.POST },
|
|
@@ -7379,6 +7383,19 @@ var Communities = /** @class */ (function () {
|
|
|
7379
7383
|
return Requests.processRoute(CommunitiesRoute.routes.newsletterSubscriberTrend, undefined, // no body data
|
|
7380
7384
|
{ community_id: community_id, newsletter_id: newsletter_id }, params);
|
|
7381
7385
|
};
|
|
7386
|
+
/**
|
|
7387
|
+
* Export subscribers for a specific newsletter.
|
|
7388
|
+
* The file is generated asynchronously on the server and
|
|
7389
|
+
* the user is emailed a link to download the file.
|
|
7390
|
+
*
|
|
7391
|
+
* @param community_id The ID of the community.
|
|
7392
|
+
* @param newsletter_id The ID of the newsletter.
|
|
7393
|
+
* @param data Export options (format: 'csv' or 'xlsx').
|
|
7394
|
+
* @returns Promise
|
|
7395
|
+
*/
|
|
7396
|
+
Communities.exportNewsletterSubscribers = function (community_id, newsletter_id, data, params) {
|
|
7397
|
+
return Requests.processRoute(CommunitiesRoute.routes.exportNewsletterSubscribers, data, { community_id: community_id, newsletter_id: newsletter_id }, params);
|
|
7398
|
+
};
|
|
7382
7399
|
return Communities;
|
|
7383
7400
|
}());
|
|
7384
7401
|
|
|
@@ -11901,6 +11918,7 @@ var FunnelRoutes = /** @class */ (function () {
|
|
|
11901
11918
|
daily: { url: '/funnels/daily', method: HTTP_METHODS.GET },
|
|
11902
11919
|
monthly: { url: '/funnels/monthly', method: HTTP_METHODS.GET },
|
|
11903
11920
|
yearly: { url: '/funnels/yearly', method: HTTP_METHODS.GET },
|
|
11921
|
+
gamify: { url: '/funnels/gamify', method: HTTP_METHODS.GET },
|
|
11904
11922
|
};
|
|
11905
11923
|
return FunnelRoutes;
|
|
11906
11924
|
}());
|
|
@@ -11984,6 +12002,17 @@ var Funnel = /** @class */ (function () {
|
|
|
11984
12002
|
Funnel.yearly = function (params) {
|
|
11985
12003
|
return Requests.processRoute(FunnelRoutes.routes.yearly, undefined, undefined, params);
|
|
11986
12004
|
};
|
|
12005
|
+
/**
|
|
12006
|
+
* Get gamified funnel metrics with recommended targets, scores, and ranks.
|
|
12007
|
+
*
|
|
12008
|
+
* @see https://api.glitch.fun/api/documentation#/Funnel%20Metrics/get_funnels_gamify
|
|
12009
|
+
*
|
|
12010
|
+
* @param params Query parameters (title_id, community_id, start_date, end_date)
|
|
12011
|
+
* @returns Promise with the gamified funnel data
|
|
12012
|
+
*/
|
|
12013
|
+
Funnel.gamify = function (params) {
|
|
12014
|
+
return Requests.processRoute(FunnelRoutes.routes.gamify, undefined, undefined, params);
|
|
12015
|
+
};
|
|
11987
12016
|
return Funnel;
|
|
11988
12017
|
}());
|
|
11989
12018
|
|