glitch-javascript-sdk 1.2.0 → 1.2.1
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 +13 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Communities.d.ts +10 -0
- package/dist/esm/index.js +13 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +10 -0
- package/package.json +1 -1
- package/src/api/Communities.ts +14 -0
- package/src/routes/CommunitiesRoute.ts +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -19765,6 +19765,7 @@ var CommunitiesRoute = /** @class */ (function () {
|
|
|
19765
19765
|
viewEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.GET },
|
|
19766
19766
|
updateEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.PUT },
|
|
19767
19767
|
deleteEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}', method: HTTP_METHODS.DELETE },
|
|
19768
|
+
populateEmailTemplate: { url: '/communities/{community_id}/emails/templates/{template_id}/populate', method: HTTP_METHODS.POST },
|
|
19768
19769
|
};
|
|
19769
19770
|
return CommunitiesRoute;
|
|
19770
19771
|
}());
|
|
@@ -20183,6 +20184,18 @@ var Communities = /** @class */ (function () {
|
|
|
20183
20184
|
Communities.deleteEmailTemplate = function (community_id, template_id, params) {
|
|
20184
20185
|
return Requests.processRoute(CommunitiesRoute.routes.deleteEmailTemplate, {}, { community_id: community_id, template_id: template_id });
|
|
20185
20186
|
};
|
|
20187
|
+
/**
|
|
20188
|
+
* Populates an email template for the community that will replace the platholders with the data provided.
|
|
20189
|
+
*
|
|
20190
|
+
* @see https://api.glitch.fun/api/documentation#/Community%20Route/newCommunityResourceStorage
|
|
20191
|
+
*
|
|
20192
|
+
* @param data The data to be passed when creating a community.
|
|
20193
|
+
*
|
|
20194
|
+
* @returns Promise
|
|
20195
|
+
*/
|
|
20196
|
+
Communities.populateEmailTemplate = function (community_id, template_id, data, params) {
|
|
20197
|
+
return Requests.processRoute(CommunitiesRoute.routes.createEmailTemplate, data, { community_id: community_id, template_id: template_id }, params);
|
|
20198
|
+
};
|
|
20186
20199
|
return Communities;
|
|
20187
20200
|
}());
|
|
20188
20201
|
|