@griddo/api-types 1.1.3 → 1.3.0
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/ai/answers.d.ts +20 -0
- package/dist/ai/answers.js +8 -0
- package/dist/ai/index.d.ts +4 -0
- package/dist/ai/index.js +20 -0
- package/dist/ai/pages.d.ts +19 -0
- package/dist/ai/pages.js +2 -0
- package/dist/ai/search.d.ts +54 -0
- package/dist/ai/search.js +13 -0
- package/dist/ai/summary.d.ts +12 -0
- package/dist/ai/summary.js +7 -0
- package/dist/analytics/dimensions.d.ts +13 -0
- package/dist/analytics/dimensions.js +5 -0
- package/dist/analytics/groups.d.ts +20 -0
- package/dist/analytics/groups.js +5 -0
- package/dist/analytics/index.d.ts +3 -0
- package/dist/analytics/index.js +19 -0
- package/dist/analytics/script.d.ts +34 -0
- package/dist/analytics/script.js +5 -0
- package/dist/apiTokens/api_token.d.ts +33 -0
- package/dist/apiTokens/api_token.js +12 -0
- package/dist/apiTokens/index.d.ts +2 -0
- package/dist/apiTokens/index.js +18 -0
- package/dist/apiTokens/service_account.d.ts +32 -0
- package/dist/apiTokens/service_account.js +12 -0
- package/dist/common/index.d.ts +2 -0
- package/dist/common/index.js +2 -0
- package/dist/common/success.d.ts +10 -0
- package/dist/common/success.js +2 -0
- package/dist/common/uuid.d.ts +1 -0
- package/dist/common/uuid.js +2 -0
- package/dist/dataPack/index.d.ts +1 -0
- package/dist/dataPack/index.js +1 -0
- package/dist/dataPack/types.d.ts +15 -0
- package/dist/dataPack/types.js +2 -0
- package/dist/domains/domains.d.ts +33 -0
- package/dist/domains/domains.js +2 -0
- package/dist/domains/index.d.ts +42 -0
- package/dist/domains/index.js +33 -0
- package/dist/domains/robots.d.ts +24 -0
- package/dist/domains/robots.js +2 -0
- package/dist/feeds/index.d.ts +40 -0
- package/dist/feeds/index.js +9 -0
- package/dist/files/index.d.ts +60 -0
- package/dist/files/index.js +2 -0
- package/dist/form-categories/index.d.ts +46 -0
- package/dist/form-categories/index.js +9 -0
- package/dist/forms/index.d.ts +71 -0
- package/dist/forms/index.js +10 -0
- package/dist/images/index.d.ts +235 -0
- package/dist/images/index.js +6 -0
- package/dist/index.d.ts +25 -0
- package/dist/index.js +25 -0
- package/dist/instances/index.d.ts +10 -0
- package/dist/instances/index.js +10 -0
- package/dist/integrations/index.d.ts +92 -0
- package/dist/integrations/index.js +17 -0
- package/dist/languages/index.d.ts +23 -0
- package/dist/languages/index.js +2 -0
- package/dist/liveStatus/index.d.ts +14 -0
- package/dist/liveStatus/index.js +10 -0
- package/dist/logs/LogActivityEvents.d.ts +35 -0
- package/dist/logs/LogActivityEvents.js +35 -0
- package/dist/menus/index.d.ts +52 -0
- package/dist/menus/index.js +8 -0
- package/dist/navigation/index.d.ts +44 -0
- package/dist/navigation/index.js +8 -0
- package/dist/pages/index.d.ts +3 -0
- package/dist/pages/index.js +3 -0
- package/dist/pages/llms.d.ts +13 -0
- package/dist/pages/llms.js +8 -0
- package/dist/pages/page_access_grants.d.ts +46 -0
- package/dist/pages/page_access_grants.js +2 -0
- package/dist/pages/preview_share.d.ts +13 -0
- package/dist/pages/preview_share.js +8 -0
- package/dist/payables/index.d.ts +19 -0
- package/dist/payables/index.js +10 -0
- package/dist/redirects/index.d.ts +33 -0
- package/dist/render/index.d.ts +1 -0
- package/dist/render/index.js +17 -0
- package/dist/render/status.d.ts +59 -0
- package/dist/render/status.js +2 -0
- package/dist/roles/index.d.ts +61 -0
- package/dist/roles/index.js +3 -0
- package/dist/schemas/index.d.ts +1 -0
- package/dist/schemas/index.js +1 -0
- package/dist/schemas/schemas.d.ts +2 -0
- package/dist/schemas/version.d.ts +9 -0
- package/dist/schemas/version.js +2 -0
- package/dist/search/index.d.ts +33 -0
- package/dist/search/index.js +9 -0
- package/dist/settings/index.d.ts +16 -0
- package/dist/settings/index.js +10 -0
- package/dist/site/index.d.ts +1 -0
- package/dist/site/index.js +1 -0
- package/dist/site/site.d.ts +3 -1
- package/dist/site/site_languages.d.ts +43 -0
- package/dist/site/site_languages.js +14 -0
- package/dist/storage/index.d.ts +4 -0
- package/dist/storage/index.js +8 -0
- package/dist/structuredData/access_grants.d.ts +36 -0
- package/dist/structuredData/access_grants.js +2 -0
- package/dist/structuredData/categories.d.ts +69 -0
- package/dist/structuredData/categories.js +2 -0
- package/dist/structuredData/content.d.ts +164 -0
- package/dist/structuredData/content.js +2 -0
- package/dist/structuredData/distributor.d.ts +80 -0
- package/dist/structuredData/distributor.js +2 -0
- package/dist/structuredData/index.d.ts +5 -0
- package/dist/structuredData/index.js +21 -0
- package/dist/structuredData/types.d.ts +38 -0
- package/dist/structuredData/types.js +9 -0
- package/dist/translations/index.d.ts +108 -0
- package/dist/translations/index.js +5 -0
- package/dist/user/index.d.ts +74 -0
- package/dist/user/index.js +19 -0
- package/dist/user/page_permissions.d.ts +22 -0
- package/dist/user/page_permissions.js +2 -0
- package/dist/user/single_login.d.ts +17 -0
- package/dist/user/single_login.js +2 -0
- package/dist/user/sso_login.d.ts +12 -0
- package/dist/user/sso_login.js +2 -0
- package/package.json +4 -2
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface LanguageDomainInfo {
|
|
2
|
+
id: number;
|
|
3
|
+
url: string;
|
|
4
|
+
slug: string | null;
|
|
5
|
+
}
|
|
6
|
+
export interface LanguageListItem {
|
|
7
|
+
id: number;
|
|
8
|
+
locale: string;
|
|
9
|
+
language: string;
|
|
10
|
+
label: string;
|
|
11
|
+
isDefault: boolean;
|
|
12
|
+
path?: string | null;
|
|
13
|
+
domain?: LanguageDomainInfo | null;
|
|
14
|
+
home?: string | null;
|
|
15
|
+
}
|
|
16
|
+
export interface LanguageListResponse {
|
|
17
|
+
totalItems: number;
|
|
18
|
+
items: LanguageListItem[];
|
|
19
|
+
}
|
|
20
|
+
export interface LanguageSelectItem {
|
|
21
|
+
value: number;
|
|
22
|
+
label: string;
|
|
23
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for the `live-status` module.
|
|
3
|
+
*
|
|
4
|
+
* `live_status` is a tiny lookup table that catalogues the publishing
|
|
5
|
+
* states (`offline`, `upload-pending`, `active`, `offline-pending`,
|
|
6
|
+
* `scheduled`). The values are seeded once at boot and exposed by the
|
|
7
|
+
* `GET /live-status` endpoint so admin UIs can render the catalogue.
|
|
8
|
+
*/
|
|
9
|
+
export interface LiveStatus {
|
|
10
|
+
id: number;
|
|
11
|
+
title: string | null;
|
|
12
|
+
status: string | null;
|
|
13
|
+
}
|
|
14
|
+
export type GetLiveStatusResponse = LiveStatus[];
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public types for the `live-status` module.
|
|
4
|
+
*
|
|
5
|
+
* `live_status` is a tiny lookup table that catalogues the publishing
|
|
6
|
+
* states (`offline`, `upload-pending`, `active`, `offline-pending`,
|
|
7
|
+
* `scheduled`). The values are seeded once at boot and exposed by the
|
|
8
|
+
* `GET /live-status` endpoint so admin UIs can render the catalogue.
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -474,6 +474,11 @@ export declare const LogActivityEvent: {
|
|
|
474
474
|
readonly description: "Modificación de las configuraciones generales del site.";
|
|
475
475
|
readonly scope: readonly ["SITE"];
|
|
476
476
|
};
|
|
477
|
+
readonly REPUBLISH_SITE: {
|
|
478
|
+
readonly name: "Republish site";
|
|
479
|
+
readonly description: "Solicitud de re-renderizado (republicación) de todas las páginas publicables del site.";
|
|
480
|
+
readonly scope: readonly ["SITE"];
|
|
481
|
+
};
|
|
477
482
|
readonly EDITED_ROBOT_TXT: {
|
|
478
483
|
readonly name: "Edited robot.txt";
|
|
479
484
|
readonly description: "Modificación del archivo robots.txt para guiar a los motores de búsqueda.";
|
|
@@ -664,4 +669,34 @@ export declare const LogActivityEvent: {
|
|
|
664
669
|
readonly description: "Elimina un ID de analíticas para el seguimiento en Analytics.";
|
|
665
670
|
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
666
671
|
};
|
|
672
|
+
readonly SET_PAGE_ACCESS: {
|
|
673
|
+
readonly name: "Set page access";
|
|
674
|
+
readonly description: "Primer cambio en los permisos de acceso de una página.";
|
|
675
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
676
|
+
};
|
|
677
|
+
readonly SET_CONTENT_TYPE_PAGE_ACCESS: {
|
|
678
|
+
readonly name: "Set content type page access";
|
|
679
|
+
readonly description: "Primer cambio en los permisos de acceso de una página de tipo de contenido.";
|
|
680
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
681
|
+
};
|
|
682
|
+
readonly SET_CONTENT_TYPE_SIMPLE_ACCESS: {
|
|
683
|
+
readonly name: "Set content type simple access";
|
|
684
|
+
readonly description: "Primer cambio en los permisos de acceso de un contenido simple.";
|
|
685
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
686
|
+
};
|
|
687
|
+
readonly EDITED_PAGE_ACCESS: {
|
|
688
|
+
readonly name: "Edited page access";
|
|
689
|
+
readonly description: "Cualquier cambio en los permisos de acceso de una página.";
|
|
690
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
691
|
+
};
|
|
692
|
+
readonly EDITED_CONTENT_TYPE_PAGE_ACCESS: {
|
|
693
|
+
readonly name: "Edited content type page access";
|
|
694
|
+
readonly description: "Cualquier cambio en los permisos de acceso de una página de tipo de contenido.";
|
|
695
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
696
|
+
};
|
|
697
|
+
readonly EDITED_CONTENT_TYPE_SIMPLE_ACCESS: {
|
|
698
|
+
readonly name: "Edited content type simple access";
|
|
699
|
+
readonly description: "Cualquier cambio en los permisos de acceso de un contenido simple.";
|
|
700
|
+
readonly scope: readonly ["GLOBAL", "SITE"];
|
|
701
|
+
};
|
|
667
702
|
};
|
|
@@ -477,6 +477,11 @@ exports.LogActivityEvent = {
|
|
|
477
477
|
description: `Modificación de las configuraciones generales del site.`,
|
|
478
478
|
scope: ["SITE"],
|
|
479
479
|
},
|
|
480
|
+
REPUBLISH_SITE: {
|
|
481
|
+
name: "Republish site",
|
|
482
|
+
description: `Solicitud de re-renderizado (republicación) de todas las páginas publicables del site.`,
|
|
483
|
+
scope: ["SITE"],
|
|
484
|
+
},
|
|
480
485
|
EDITED_ROBOT_TXT: {
|
|
481
486
|
name: "Edited robot.txt",
|
|
482
487
|
description: `Modificación del archivo robots.txt para guiar a los motores de búsqueda.`,
|
|
@@ -667,4 +672,34 @@ exports.LogActivityEvent = {
|
|
|
667
672
|
description: `Elimina un ID de analíticas para el seguimiento en Analytics.`,
|
|
668
673
|
scope: ["GLOBAL", "SITE"],
|
|
669
674
|
},
|
|
675
|
+
SET_PAGE_ACCESS: {
|
|
676
|
+
name: "Set page access",
|
|
677
|
+
description: `Primer cambio en los permisos de acceso de una página.`,
|
|
678
|
+
scope: ["GLOBAL", "SITE"],
|
|
679
|
+
},
|
|
680
|
+
SET_CONTENT_TYPE_PAGE_ACCESS: {
|
|
681
|
+
name: "Set content type page access",
|
|
682
|
+
description: `Primer cambio en los permisos de acceso de una página de tipo de contenido.`,
|
|
683
|
+
scope: ["GLOBAL", "SITE"],
|
|
684
|
+
},
|
|
685
|
+
SET_CONTENT_TYPE_SIMPLE_ACCESS: {
|
|
686
|
+
name: "Set content type simple access",
|
|
687
|
+
description: `Primer cambio en los permisos de acceso de un contenido simple.`,
|
|
688
|
+
scope: ["GLOBAL", "SITE"],
|
|
689
|
+
},
|
|
690
|
+
EDITED_PAGE_ACCESS: {
|
|
691
|
+
name: "Edited page access",
|
|
692
|
+
description: `Cualquier cambio en los permisos de acceso de una página.`,
|
|
693
|
+
scope: ["GLOBAL", "SITE"],
|
|
694
|
+
},
|
|
695
|
+
EDITED_CONTENT_TYPE_PAGE_ACCESS: {
|
|
696
|
+
name: "Edited content type page access",
|
|
697
|
+
description: `Cualquier cambio en los permisos de acceso de una página de tipo de contenido.`,
|
|
698
|
+
scope: ["GLOBAL", "SITE"],
|
|
699
|
+
},
|
|
700
|
+
EDITED_CONTENT_TYPE_SIMPLE_ACCESS: {
|
|
701
|
+
name: "Edited content type simple access",
|
|
702
|
+
description: `Cualquier cambio en los permisos de acceso de un contenido simple.`,
|
|
703
|
+
scope: ["GLOBAL", "SITE"],
|
|
704
|
+
},
|
|
670
705
|
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for `/menus` and `/menu_container` API responses.
|
|
3
|
+
*
|
|
4
|
+
* Mirrors the legacy contract emitted by `endpoints/menus.ts` so existing
|
|
5
|
+
* consumers can rely on the same shape after the DDD migration.
|
|
6
|
+
*/
|
|
7
|
+
export interface MenuSelectItem {
|
|
8
|
+
value: number;
|
|
9
|
+
label: string;
|
|
10
|
+
}
|
|
11
|
+
export interface MenuUrl {
|
|
12
|
+
href: string | null;
|
|
13
|
+
anchor: string | null;
|
|
14
|
+
subSlug: string | null;
|
|
15
|
+
linkTo: number | null;
|
|
16
|
+
newTab: boolean | null;
|
|
17
|
+
noFollow: boolean | null;
|
|
18
|
+
title: string | null;
|
|
19
|
+
}
|
|
20
|
+
export interface MenuElement {
|
|
21
|
+
id: number;
|
|
22
|
+
label: string | null;
|
|
23
|
+
url: MenuUrl | null;
|
|
24
|
+
component: string;
|
|
25
|
+
auxText: string | null;
|
|
26
|
+
image: unknown | null;
|
|
27
|
+
config: Record<string, unknown> | null;
|
|
28
|
+
special: boolean;
|
|
29
|
+
children: MenuElement[];
|
|
30
|
+
[key: string]: unknown;
|
|
31
|
+
}
|
|
32
|
+
export interface MenuContainer {
|
|
33
|
+
id: number;
|
|
34
|
+
site: number | null;
|
|
35
|
+
language: number | null;
|
|
36
|
+
name: string | null;
|
|
37
|
+
title: string;
|
|
38
|
+
component: string;
|
|
39
|
+
type: string | null;
|
|
40
|
+
layout: string | null;
|
|
41
|
+
elements: MenuElement[] | undefined;
|
|
42
|
+
}
|
|
43
|
+
export interface UpdateMenuContainerBody {
|
|
44
|
+
name: string;
|
|
45
|
+
component?: string;
|
|
46
|
+
type?: string | null;
|
|
47
|
+
layout?: string | null;
|
|
48
|
+
elements?: MenuElement[];
|
|
49
|
+
language: number | string | {
|
|
50
|
+
id: number;
|
|
51
|
+
};
|
|
52
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public types for `/menus` and `/menu_container` API responses.
|
|
4
|
+
*
|
|
5
|
+
* Mirrors the legacy contract emitted by `endpoints/menus.ts` so existing
|
|
6
|
+
* consumers can rely on the same shape after the DDD migration.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for the `/navigations` API.
|
|
3
|
+
*
|
|
4
|
+
* Mirrors the contract emitted by `endpoints/navigation.ts` so existing
|
|
5
|
+
* consumers keep working after the DDD migration.
|
|
6
|
+
*/
|
|
7
|
+
export interface NavigationLanguageEntry {
|
|
8
|
+
navigationId: number;
|
|
9
|
+
languageId: number;
|
|
10
|
+
locale: string | null;
|
|
11
|
+
language: string | null;
|
|
12
|
+
}
|
|
13
|
+
export interface NavigationListResponse {
|
|
14
|
+
totalItems: number;
|
|
15
|
+
page: number;
|
|
16
|
+
items: NavigationPayload[];
|
|
17
|
+
}
|
|
18
|
+
export interface NavigationPayload {
|
|
19
|
+
id: number;
|
|
20
|
+
site: number | null;
|
|
21
|
+
language: number | null;
|
|
22
|
+
entity: string | null;
|
|
23
|
+
thumbnail: unknown | null;
|
|
24
|
+
isDefault: boolean;
|
|
25
|
+
deleted: boolean;
|
|
26
|
+
setAsDefault: boolean;
|
|
27
|
+
navigationLanguages?: NavigationLanguageEntry[];
|
|
28
|
+
[key: string]: unknown;
|
|
29
|
+
}
|
|
30
|
+
export interface PagesReplaceResponse {
|
|
31
|
+
availableNavigationsInSite: Array<{
|
|
32
|
+
id: number;
|
|
33
|
+
isDefault: boolean;
|
|
34
|
+
}>;
|
|
35
|
+
items: {
|
|
36
|
+
totalItems: number;
|
|
37
|
+
pagesInUse: Array<{
|
|
38
|
+
pageId: number;
|
|
39
|
+
pageTitle: string | null;
|
|
40
|
+
pathString: string | null;
|
|
41
|
+
navigationId: number;
|
|
42
|
+
}>;
|
|
43
|
+
};
|
|
44
|
+
}
|
package/dist/pages/index.d.ts
CHANGED
package/dist/pages/index.js
CHANGED
|
@@ -16,3 +16,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./clear_corrupted_pages"), exports);
|
|
18
18
|
__exportStar(require("./add-ons"), exports);
|
|
19
|
+
__exportStar(require("./page_access_grants"), exports);
|
|
20
|
+
__exportStar(require("./llms"), exports);
|
|
21
|
+
__exportStar(require("./preview_share"), exports);
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for `GET /domains/:domainId/llms`.
|
|
3
|
+
*
|
|
4
|
+
* Returns the list of published pages of a domain, in the minimal shape
|
|
5
|
+
* consumed to build its `llms.txt` (id, title, absolute url, description).
|
|
6
|
+
*/
|
|
7
|
+
export interface LlmsReadyPage {
|
|
8
|
+
id: number;
|
|
9
|
+
title: string;
|
|
10
|
+
url: string;
|
|
11
|
+
description: string;
|
|
12
|
+
}
|
|
13
|
+
export type GetDomainLlmsResponse = LlmsReadyPage[];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public types for `GET /domains/:domainId/llms`.
|
|
4
|
+
*
|
|
5
|
+
* Returns the list of published pages of a domain, in the minimal shape
|
|
6
|
+
* consumed to build its `llms.txt` (id, title, absolute url, description).
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Forma mínima embebida en `GET /page/:id` (campo `accessGrants`).
|
|
3
|
+
* Solo IDs; los detalles los obtiene el FE desde `/access-grants` o `/candidates`.
|
|
4
|
+
*/
|
|
5
|
+
export interface PageAccessGrantsSummary {
|
|
6
|
+
users: number[];
|
|
7
|
+
roles: number[];
|
|
8
|
+
}
|
|
9
|
+
export interface PageAccessGrantUserResponse {
|
|
10
|
+
id: number;
|
|
11
|
+
email: string;
|
|
12
|
+
username: string;
|
|
13
|
+
}
|
|
14
|
+
export interface PageAccessGrantRoleResponse {
|
|
15
|
+
id: number;
|
|
16
|
+
name: string;
|
|
17
|
+
}
|
|
18
|
+
export interface GetPageAccessGrantsResponse {
|
|
19
|
+
users: PageAccessGrantUserResponse[];
|
|
20
|
+
roles: PageAccessGrantRoleResponse[];
|
|
21
|
+
}
|
|
22
|
+
export interface PageAccessGrantCandidateUser {
|
|
23
|
+
id: number;
|
|
24
|
+
name: string;
|
|
25
|
+
email: string;
|
|
26
|
+
}
|
|
27
|
+
export interface PageAccessGrantCandidateRole {
|
|
28
|
+
id: number;
|
|
29
|
+
name: string;
|
|
30
|
+
}
|
|
31
|
+
export interface GetPageAccessGrantsCandidatesResponse {
|
|
32
|
+
availableUsers: PageAccessGrantCandidateUser[];
|
|
33
|
+
grantedUsers: PageAccessGrantCandidateUser[];
|
|
34
|
+
availableRoles: PageAccessGrantCandidateRole[];
|
|
35
|
+
grantedRoles: PageAccessGrantCandidateRole[];
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Body de `PUT /site/:site/pages/:page/access-grant`.
|
|
39
|
+
* Sobrescribe por completo la whitelist de la página.
|
|
40
|
+
* Solo puede llegar uno de los dos con contenido: `users` O `roles`, no ambos.
|
|
41
|
+
* Ambos vacíos limpia la whitelist.
|
|
42
|
+
*/
|
|
43
|
+
export interface ReplacePageAccessGrantsBody {
|
|
44
|
+
users: number[];
|
|
45
|
+
roles: number[];
|
|
46
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for the `/page/:id/share` endpoint family.
|
|
3
|
+
*
|
|
4
|
+
* `GET`, `POST` (create) and `PUT` (renew) all return the same shape: the
|
|
5
|
+
* current state of the page's preview share link.
|
|
6
|
+
*/
|
|
7
|
+
export interface PagePreviewShareResponseDTO {
|
|
8
|
+
entity: string;
|
|
9
|
+
daysValid: number;
|
|
10
|
+
startDate: string;
|
|
11
|
+
endDate: string;
|
|
12
|
+
visitCount: number;
|
|
13
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public types for the `/page/:id/share` endpoint family.
|
|
4
|
+
*
|
|
5
|
+
* `GET`, `POST` (create) and `PUT` (renew) all return the same shape: the
|
|
6
|
+
* current state of the page's preview share link.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public types for the `/payables` endpoint family.
|
|
3
|
+
*
|
|
4
|
+
* `payables` is an internal accounting ledger: each AI / translation call
|
|
5
|
+
* appends a row recording the consumed units per concept (OPENAI_TOKENS,
|
|
6
|
+
* OPENAI_TOKENS_EMBED, DEEPL_CHARS, …). The reporting endpoint groups them
|
|
7
|
+
* by month and returns the rows plus a per-concept totals aggregate.
|
|
8
|
+
*/
|
|
9
|
+
export type PayableConcept = string;
|
|
10
|
+
export interface PayableRecord {
|
|
11
|
+
id: number;
|
|
12
|
+
date: string;
|
|
13
|
+
concept: PayableConcept;
|
|
14
|
+
units: number;
|
|
15
|
+
}
|
|
16
|
+
export interface GetPayablesResponse {
|
|
17
|
+
total: Record<PayableConcept, number>;
|
|
18
|
+
detail: PayableRecord[];
|
|
19
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public types for the `/payables` endpoint family.
|
|
4
|
+
*
|
|
5
|
+
* `payables` is an internal accounting ledger: each AI / translation call
|
|
6
|
+
* appends a row recording the consumed units per concept (OPENAI_TOKENS,
|
|
7
|
+
* OPENAI_TOKENS_EMBED, DEEPL_CHARS, …). The reporting endpoint groups them
|
|
8
|
+
* by month and returns the rows plus a per-concept totals aggregate.
|
|
9
|
+
*/
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -5,3 +5,36 @@ export interface RedirectDTO {
|
|
|
5
5
|
slug: string;
|
|
6
6
|
parentSlug: string | null;
|
|
7
7
|
}
|
|
8
|
+
export interface RedirectSiteInfo {
|
|
9
|
+
siteId: number | null;
|
|
10
|
+
siteName: string | null;
|
|
11
|
+
siteUrl: string;
|
|
12
|
+
}
|
|
13
|
+
export interface RedirectDestinationInfo {
|
|
14
|
+
pageId: number | null;
|
|
15
|
+
url: string | null;
|
|
16
|
+
}
|
|
17
|
+
export interface RedirectListItem {
|
|
18
|
+
id: number;
|
|
19
|
+
domain: string | null;
|
|
20
|
+
date: Date | string | null;
|
|
21
|
+
site: RedirectSiteInfo;
|
|
22
|
+
from: string;
|
|
23
|
+
to: RedirectDestinationInfo;
|
|
24
|
+
}
|
|
25
|
+
export interface RedirectListResponse {
|
|
26
|
+
totalItems: number;
|
|
27
|
+
page: number;
|
|
28
|
+
items: RedirectListItem[];
|
|
29
|
+
}
|
|
30
|
+
export interface RedirectBulkInput {
|
|
31
|
+
from?: string;
|
|
32
|
+
to?: string | number;
|
|
33
|
+
id?: number | string | null;
|
|
34
|
+
}
|
|
35
|
+
export interface RedirectBulkResult {
|
|
36
|
+
total: number;
|
|
37
|
+
error: Array<Record<string, unknown>>;
|
|
38
|
+
existing: Array<Record<string, unknown>>;
|
|
39
|
+
ok: Array<Record<string, unknown>>;
|
|
40
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./status";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./status"), exports);
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import type { PaginationRequest, PaginationResponse } from "src/common";
|
|
2
|
+
/**
|
|
3
|
+
* Estados posibles de un `render_runs` (ciclo de render, legacy o K8s).
|
|
4
|
+
*/
|
|
5
|
+
export type RenderRunStatus = "pending" | "running" | "completed" | "failed";
|
|
6
|
+
/**
|
|
7
|
+
* Estados posibles de un `render_run_sites` (site dentro de un run).
|
|
8
|
+
* `failed` se infiere por cascada cuando el run llega a terminal sin que el
|
|
9
|
+
* site haya reportado su `build/end` (reconcile-by-timeout, watch de K8s).
|
|
10
|
+
*/
|
|
11
|
+
export type RenderRunSiteStatus = "pending" | "completed" | "failed";
|
|
12
|
+
/**
|
|
13
|
+
* DTO de un `render_runs` (sin sus sites — usado en el listado paginado).
|
|
14
|
+
*/
|
|
15
|
+
export interface RenderRunDTO {
|
|
16
|
+
readonly id: number;
|
|
17
|
+
readonly status: RenderRunStatus;
|
|
18
|
+
readonly jobName: string | null;
|
|
19
|
+
readonly requestedAt: Date;
|
|
20
|
+
readonly startedAt: Date | null;
|
|
21
|
+
readonly completedAt: Date | null;
|
|
22
|
+
readonly errorMessage: string | null;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* DTO de un site dentro de un run (para el detalle).
|
|
26
|
+
*/
|
|
27
|
+
export interface RenderRunSiteDTO {
|
|
28
|
+
readonly id: number;
|
|
29
|
+
readonly siteId: number;
|
|
30
|
+
readonly status: RenderRunSiteStatus;
|
|
31
|
+
readonly startedAt: Date | null;
|
|
32
|
+
readonly completedAt: Date | null;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* DTO de detalle de un run: el run + todos sus sites trackeados.
|
|
36
|
+
*/
|
|
37
|
+
export interface RenderRunDetailDTO extends RenderRunDTO {
|
|
38
|
+
readonly sites: RenderRunSiteDTO[];
|
|
39
|
+
}
|
|
40
|
+
/** Parámetros para `GET /renders/:id`. */
|
|
41
|
+
export type GetRenderRunParamsDTO = {
|
|
42
|
+
id: number;
|
|
43
|
+
};
|
|
44
|
+
/** Respuesta de `GET /renders/:id`. */
|
|
45
|
+
export type GetRenderRunResponseDTO = RenderRunDetailDTO;
|
|
46
|
+
/** Respuesta de `GET /renders/active` — `null` si no hay run `running`. */
|
|
47
|
+
export type GetActiveRenderRunResponseDTO = RenderRunDetailDTO | null;
|
|
48
|
+
/** Filtro soportado por el listado paginado de runs. */
|
|
49
|
+
export interface PaginationFilterRenderRunDTO {
|
|
50
|
+
status?: RenderRunStatus;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Parámetros de paginación para `GET /renders`. Sin `search` (no aplica a
|
|
54
|
+
* runs, que no tienen texto libre buscable).
|
|
55
|
+
*/
|
|
56
|
+
export type PaginationRenderRunDTO = Omit<PaginationRequest<PaginationFilterRenderRunDTO>, "search">;
|
|
57
|
+
export type PaginationRenderRunParamsDTO = PaginationRenderRunDTO;
|
|
58
|
+
/** Respuesta de `GET /renders`. */
|
|
59
|
+
export type PaginationRenderRunResponseDTO = PaginationResponse<RenderRunDTO>;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/** Public types for the Roles domain. */
|
|
2
|
+
/** A site id context: a numeric site id, or the "global"/"all" sentinels. */
|
|
3
|
+
export type RoleSiteId = number | "global" | "all";
|
|
4
|
+
/**
|
|
5
|
+
* Basic role info as exposed by `GET /roles` and `CONFIG.rolesInfo`.
|
|
6
|
+
*
|
|
7
|
+
* `editable`/`visible` are kept as raw `0 | 1` numbers to match the legacy
|
|
8
|
+
* contract: the boolean transformer normalizes both dialects to 0/1, and
|
|
9
|
+
* downstream consumers rely on truthiness (`!item.editable`).
|
|
10
|
+
*/
|
|
11
|
+
export interface RoleInfo {
|
|
12
|
+
id: number;
|
|
13
|
+
name: string;
|
|
14
|
+
description: string | null;
|
|
15
|
+
editable: number | null;
|
|
16
|
+
visible: number | null;
|
|
17
|
+
}
|
|
18
|
+
/** A single permission entry inside a site role. */
|
|
19
|
+
export interface SiteRolePermissionItem {
|
|
20
|
+
name: string;
|
|
21
|
+
key: string;
|
|
22
|
+
}
|
|
23
|
+
/** Permission breakdown for a role within a site. */
|
|
24
|
+
export interface SiteRolePermissions {
|
|
25
|
+
totalPermissions: string;
|
|
26
|
+
sitePermissions: SiteRolePermissionItem[];
|
|
27
|
+
globalPermissions: SiteRolePermissionItem[];
|
|
28
|
+
}
|
|
29
|
+
/** A role as exposed by `GET /site/:site/roles`. */
|
|
30
|
+
export interface SiteRole {
|
|
31
|
+
id: number;
|
|
32
|
+
name: string;
|
|
33
|
+
hex: string | undefined;
|
|
34
|
+
description: string | null;
|
|
35
|
+
permissions: SiteRolePermissions;
|
|
36
|
+
editable: boolean;
|
|
37
|
+
active: boolean;
|
|
38
|
+
/** Only present for non-global listings. */
|
|
39
|
+
users?: number[];
|
|
40
|
+
}
|
|
41
|
+
/** Roles a user holds, grouped by site, as exposed by `GET /user/:user/roles`. */
|
|
42
|
+
export interface UserSiteRoles {
|
|
43
|
+
siteId: RoleSiteId;
|
|
44
|
+
roles: number[];
|
|
45
|
+
}
|
|
46
|
+
/** Input for activating/deactivating a role in a site or globally. */
|
|
47
|
+
export interface ActivateRoleSiteParams {
|
|
48
|
+
active: boolean;
|
|
49
|
+
role: number | string;
|
|
50
|
+
site: number | string | "global";
|
|
51
|
+
}
|
|
52
|
+
/** Input for creating a role. */
|
|
53
|
+
export interface CreateRoleParams {
|
|
54
|
+
name: string;
|
|
55
|
+
description: string;
|
|
56
|
+
visible?: boolean;
|
|
57
|
+
editable?: boolean;
|
|
58
|
+
}
|
|
59
|
+
/** Ordering accepted by `GET /site/:site/roles`. */
|
|
60
|
+
export type SiteRolesOrderField = "name" | "users" | "permissions";
|
|
61
|
+
export type SiteRolesOrderDir = "ASC" | "DESC";
|
package/dist/schemas/index.d.ts
CHANGED
package/dist/schemas/index.js
CHANGED
|
@@ -16,3 +16,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./select"), exports);
|
|
18
18
|
__exportStar(require("./schemas"), exports);
|
|
19
|
+
__exportStar(require("./version"), exports);
|
|
@@ -42,6 +42,8 @@ export interface SchemaRichTextConfig {
|
|
|
42
42
|
paragraphStyles: SchemaStyleConfig[];
|
|
43
43
|
tableStyles: SchemaStyleConfig[];
|
|
44
44
|
tableCellStyles: SchemaStyleConfig[];
|
|
45
|
+
imageStyles: SchemaStyleConfig[];
|
|
46
|
+
imageResize: boolean;
|
|
45
47
|
editorLangs: SchemaEditorLang[];
|
|
46
48
|
}
|
|
47
49
|
export interface SchemaStyleConfig {
|