glitch-javascript-sdk 2.2.0 → 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 +71 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Titles.d.ts +52 -0
- package/dist/esm/index.js +71 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +52 -0
- package/package.json +1 -1
- package/src/api/Titles.ts +69 -0
- package/src/routes/CommunitiesRoute.ts +1 -0
- package/src/routes/TitlesRoute.ts +10 -1
package/dist/cjs/index.js
CHANGED
|
@@ -24536,7 +24536,15 @@ var TitlesRoute = /** @class */ (function () {
|
|
|
24536
24536
|
retryAdConversionEvent: {
|
|
24537
24537
|
url: '/titles/{title_id}/ad-conversion-events/{event_id}/retry',
|
|
24538
24538
|
method: HTTP_METHODS.POST
|
|
24539
|
-
}
|
|
24539
|
+
},
|
|
24540
|
+
listLandingPages: { url: '/titles/{title_id}/landing-pages', method: HTTP_METHODS.GET },
|
|
24541
|
+
createLandingPage: { url: '/titles/{title_id}/landing-pages', method: HTTP_METHODS.POST },
|
|
24542
|
+
viewLandingPage: { url: '/landing-pages/{landing_page_id}', method: HTTP_METHODS.GET },
|
|
24543
|
+
updateLandingPage: { url: '/landing-pages/{landing_page_id}', method: HTTP_METHODS.PUT },
|
|
24544
|
+
deleteLandingPage: { url: '/landing-pages/{landing_page_id}', method: HTTP_METHODS.DELETE },
|
|
24545
|
+
translateLandingPage: { url: '/landing-pages/{landing_page_id}/translate', method: HTTP_METHODS.POST },
|
|
24546
|
+
generateLandingPageAiContent: { url: '/landing-pages/{landing_page_id}/generate-ai-content', method: HTTP_METHODS.POST },
|
|
24547
|
+
saveLandingPageTranslation: { url: '/landing-pages/{landing_page_id}/translations', method: HTTP_METHODS.POST },
|
|
24540
24548
|
};
|
|
24541
24549
|
return TitlesRoute;
|
|
24542
24550
|
}());
|
|
@@ -25021,6 +25029,68 @@ var Titles = /** @class */ (function () {
|
|
|
25021
25029
|
Titles.retryAdConversionEvent = function (title_id, event_id) {
|
|
25022
25030
|
return Requests.processRoute(TitlesRoute.routes.retryAdConversionEvent, {}, { title_id: title_id, event_id: event_id });
|
|
25023
25031
|
};
|
|
25032
|
+
/**
|
|
25033
|
+
* List all landing pages for a specific title.
|
|
25034
|
+
* @param title_id The UUID of the title.
|
|
25035
|
+
* @param params Optional query parameters for pagination.
|
|
25036
|
+
*/
|
|
25037
|
+
Titles.listLandingPages = function (title_id, params) {
|
|
25038
|
+
return Requests.processRoute(TitlesRoute.routes.listLandingPages, {}, { title_id: title_id }, params);
|
|
25039
|
+
};
|
|
25040
|
+
/**
|
|
25041
|
+
* Create a new landing page for a title.
|
|
25042
|
+
* @param title_id The UUID of the title.
|
|
25043
|
+
* @param data The data for the new landing page.
|
|
25044
|
+
*/
|
|
25045
|
+
Titles.createLandingPage = function (title_id, data, params) {
|
|
25046
|
+
return Requests.processRoute(TitlesRoute.routes.createLandingPage, data, { title_id: title_id }, params);
|
|
25047
|
+
};
|
|
25048
|
+
/**
|
|
25049
|
+
* View a specific landing page by its ID.
|
|
25050
|
+
* @param landing_page_id The UUID of the landing page.
|
|
25051
|
+
*/
|
|
25052
|
+
Titles.viewLandingPage = function (landing_page_id, params) {
|
|
25053
|
+
return Requests.processRoute(TitlesRoute.routes.viewLandingPage, {}, { landing_page_id: landing_page_id }, params);
|
|
25054
|
+
};
|
|
25055
|
+
/**
|
|
25056
|
+
* Update an existing landing page.
|
|
25057
|
+
* @param landing_page_id The UUID of the landing page to update.
|
|
25058
|
+
* @param data The new data for the landing page.
|
|
25059
|
+
*/
|
|
25060
|
+
Titles.updateLandingPage = function (landing_page_id, data, params) {
|
|
25061
|
+
return Requests.processRoute(TitlesRoute.routes.updateLandingPage, data, { landing_page_id: landing_page_id }, params);
|
|
25062
|
+
};
|
|
25063
|
+
/**
|
|
25064
|
+
* Delete a landing page.
|
|
25065
|
+
* @param landing_page_id The UUID of the landing page to delete.
|
|
25066
|
+
*/
|
|
25067
|
+
Titles.deleteLandingPage = function (landing_page_id, params) {
|
|
25068
|
+
return Requests.processRoute(TitlesRoute.routes.deleteLandingPage, {}, { landing_page_id: landing_page_id }, params);
|
|
25069
|
+
};
|
|
25070
|
+
/**
|
|
25071
|
+
* Trigger an AI translation for a landing page.
|
|
25072
|
+
* @param landing_page_id The UUID of the landing page.
|
|
25073
|
+
* @param data An object containing the target language code, e.g., { language_code: 'es' }.
|
|
25074
|
+
*/
|
|
25075
|
+
Titles.translateLandingPage = function (landing_page_id, data, params) {
|
|
25076
|
+
return Requests.processRoute(TitlesRoute.routes.translateLandingPage, data, { landing_page_id: landing_page_id }, params);
|
|
25077
|
+
};
|
|
25078
|
+
/**
|
|
25079
|
+
* Generate or regenerate AI-powered HTML content for a landing page.
|
|
25080
|
+
* @param landing_page_id The UUID of the landing page.
|
|
25081
|
+
* @param data An object containing the prompt, language_code, and privacy_mode.
|
|
25082
|
+
*/
|
|
25083
|
+
Titles.generateLandingPageAiContent = function (landing_page_id, data, params) {
|
|
25084
|
+
return Requests.processRoute(TitlesRoute.routes.generateLandingPageAiContent, data, { landing_page_id: landing_page_id }, params);
|
|
25085
|
+
};
|
|
25086
|
+
/**
|
|
25087
|
+
* Create or update a specific translation for a landing page.
|
|
25088
|
+
* @param landing_page_id The UUID of the landing page.
|
|
25089
|
+
* @param translationData The full translation object to be saved.
|
|
25090
|
+
*/
|
|
25091
|
+
Titles.saveLandingPageTranslation = function (landing_page_id, translationData, params) {
|
|
25092
|
+
return Requests.processRoute(TitlesRoute.routes.saveLandingPageTranslation, translationData, { landing_page_id: landing_page_id }, params);
|
|
25093
|
+
};
|
|
25024
25094
|
return Titles;
|
|
25025
25095
|
}());
|
|
25026
25096
|
|