glitch-javascript-sdk 2.2.1 → 2.2.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 +18 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Titles.d.ts +16 -0
- package/dist/esm/index.js +18 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +16 -0
- package/package.json +1 -1
- package/src/api/Titles.ts +17 -0
- package/src/routes/CommunitiesRoute.ts +1 -0
- package/src/routes/TitlesRoute.ts +3 -0
package/dist/esm/api/Titles.d.ts
CHANGED
|
@@ -403,5 +403,21 @@ declare class Titles {
|
|
|
403
403
|
static translateLandingPage<T>(landing_page_id: string, data: {
|
|
404
404
|
language_code: string;
|
|
405
405
|
}, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
406
|
+
/**
|
|
407
|
+
* Generate or regenerate AI-powered HTML content for a landing page.
|
|
408
|
+
* @param landing_page_id The UUID of the landing page.
|
|
409
|
+
* @param data An object containing the prompt, language_code, and privacy_mode.
|
|
410
|
+
*/
|
|
411
|
+
static generateLandingPageAiContent<T>(landing_page_id: string, data: {
|
|
412
|
+
prompt: string;
|
|
413
|
+
language_code: string;
|
|
414
|
+
privacy_mode: string;
|
|
415
|
+
}, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
416
|
+
/**
|
|
417
|
+
* Create or update a specific translation for a landing page.
|
|
418
|
+
* @param landing_page_id The UUID of the landing page.
|
|
419
|
+
* @param translationData The full translation object to be saved.
|
|
420
|
+
*/
|
|
421
|
+
static saveLandingPageTranslation<T>(landing_page_id: string, translationData: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
406
422
|
}
|
|
407
423
|
export default Titles;
|
package/dist/esm/index.js
CHANGED
|
@@ -11359,6 +11359,8 @@ var TitlesRoute = /** @class */ (function () {
|
|
|
11359
11359
|
updateLandingPage: { url: '/landing-pages/{landing_page_id}', method: HTTP_METHODS.PUT },
|
|
11360
11360
|
deleteLandingPage: { url: '/landing-pages/{landing_page_id}', method: HTTP_METHODS.DELETE },
|
|
11361
11361
|
translateLandingPage: { url: '/landing-pages/{landing_page_id}/translate', method: HTTP_METHODS.POST },
|
|
11362
|
+
generateLandingPageAiContent: { url: '/landing-pages/{landing_page_id}/generate-ai-content', method: HTTP_METHODS.POST },
|
|
11363
|
+
saveLandingPageTranslation: { url: '/landing-pages/{landing_page_id}/translations', method: HTTP_METHODS.POST },
|
|
11362
11364
|
};
|
|
11363
11365
|
return TitlesRoute;
|
|
11364
11366
|
}());
|
|
@@ -11889,6 +11891,22 @@ var Titles = /** @class */ (function () {
|
|
|
11889
11891
|
Titles.translateLandingPage = function (landing_page_id, data, params) {
|
|
11890
11892
|
return Requests.processRoute(TitlesRoute.routes.translateLandingPage, data, { landing_page_id: landing_page_id }, params);
|
|
11891
11893
|
};
|
|
11894
|
+
/**
|
|
11895
|
+
* Generate or regenerate AI-powered HTML content for a landing page.
|
|
11896
|
+
* @param landing_page_id The UUID of the landing page.
|
|
11897
|
+
* @param data An object containing the prompt, language_code, and privacy_mode.
|
|
11898
|
+
*/
|
|
11899
|
+
Titles.generateLandingPageAiContent = function (landing_page_id, data, params) {
|
|
11900
|
+
return Requests.processRoute(TitlesRoute.routes.generateLandingPageAiContent, data, { landing_page_id: landing_page_id }, params);
|
|
11901
|
+
};
|
|
11902
|
+
/**
|
|
11903
|
+
* Create or update a specific translation for a landing page.
|
|
11904
|
+
* @param landing_page_id The UUID of the landing page.
|
|
11905
|
+
* @param translationData The full translation object to be saved.
|
|
11906
|
+
*/
|
|
11907
|
+
Titles.saveLandingPageTranslation = function (landing_page_id, translationData, params) {
|
|
11908
|
+
return Requests.processRoute(TitlesRoute.routes.saveLandingPageTranslation, translationData, { landing_page_id: landing_page_id }, params);
|
|
11909
|
+
};
|
|
11892
11910
|
return Titles;
|
|
11893
11911
|
}());
|
|
11894
11912
|
|