sass-cms-template-common 0.0.25 → 0.0.27
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/index.d.ts +60 -2
- package/dist/index.js +349 -308
- package/dist/index.js.map +1 -1
- package/dist/server.d.ts +58 -0
- package/dist/server.js +1 -1
- package/dist/{services-DoVB2Gol.js → services-2zqQa6zN.js} +59 -1
- package/dist/services-2zqQa6zN.js.map +1 -0
- package/package.json +1 -1
- package/dist/services-DoVB2Gol.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1033,6 +1033,17 @@ export declare class CmsCopilotServices {
|
|
|
1033
1033
|
* oportunidad: `save` | `like` | `dislike` | `assign` (permiso COPILOT_ACTION).
|
|
1034
1034
|
*/
|
|
1035
1035
|
executeAction: (input: CopilotActionInput) => Promise<CopilotActionResponse>;
|
|
1036
|
+
/**
|
|
1037
|
+
* POST /copilot/generate — genera la nota con IA (Kundera) a partir de una
|
|
1038
|
+
* oportunidad y la crea en el CMS, devolviendo su `fileName` (path VFS) para
|
|
1039
|
+
* abrir el editor de noticias. Llamada **síncrona** (10–40s) que consume cuota,
|
|
1040
|
+
* marca la oportunidad como `actioned` y exige los permisos `COPILOT_ACTION` e
|
|
1041
|
+
* `IA_NEWS_CREATE` (NAA-4863; contrato verificado contra la ficha del endpoint).
|
|
1042
|
+
* @param opportunityId - Id de la oportunidad a generar.
|
|
1043
|
+
* @param model - Modelo de IA opcional (ej. `gemini-2.5-flash`); si se omite,
|
|
1044
|
+
* usa el default del microservicio.
|
|
1045
|
+
*/
|
|
1046
|
+
generate: (opportunityId: string, model?: string) => Promise<CopilotGenerateResponse>;
|
|
1036
1047
|
/**
|
|
1037
1048
|
* POST /copilot/snooze — "recordar luego" de una oportunidad de la campanita
|
|
1038
1049
|
* (permiso COPILOT_VIEW). La oportunidad desaparece de la campanita para el
|
|
@@ -2982,6 +2993,53 @@ export declare interface CopilotActionResponse extends CmsResponse {
|
|
|
2982
2993
|
data?: CopilotActionData;
|
|
2983
2994
|
}
|
|
2984
2995
|
|
|
2996
|
+
/**
|
|
2997
|
+
* Artículo generado por IA (Kundera) que devuelve POST /copilot/generate. Cada
|
|
2998
|
+
* campo viene solo si tuvo valor. Hoy la nota se crea con `title` + `body_markdown`
|
|
2999
|
+
* (crudo); el resto (tags, imágenes) se devuelve para reuso del front pero NO se
|
|
3000
|
+
* escribe en la nota (ver ficha del endpoint, NAA-4863).
|
|
3001
|
+
*/
|
|
3002
|
+
export declare interface CopilotArticle {
|
|
3003
|
+
/** Título de la nota. */
|
|
3004
|
+
title?: string;
|
|
3005
|
+
/** Copete / bajada. */
|
|
3006
|
+
lead?: string;
|
|
3007
|
+
/** Cuerpo en Markdown (hoy se guarda crudo hasta que Kundera devuelva HTML). */
|
|
3008
|
+
body_markdown?: string;
|
|
3009
|
+
/** Resumen para SEO / meta description. */
|
|
3010
|
+
meta_description?: string;
|
|
3011
|
+
/** Tags sugeridos. */
|
|
3012
|
+
tags?: string[];
|
|
3013
|
+
/** Consulta sugerida para buscar la imagen de portada. */
|
|
3014
|
+
image_search_query?: string;
|
|
3015
|
+
/** Descripción de la imagen sugerida. */
|
|
3016
|
+
image_suggestion?: string;
|
|
3017
|
+
/** Advertencias editoriales de la IA. */
|
|
3018
|
+
warnings?: string[];
|
|
3019
|
+
}
|
|
3020
|
+
|
|
3021
|
+
/**
|
|
3022
|
+
* Cuerpo de la respuesta de POST /copilot/generate (NAA-4863).
|
|
3023
|
+
*
|
|
3024
|
+
* El endpoint genera el artículo con IA (Kundera) a partir de una oportunidad y
|
|
3025
|
+
* **crea la nota en el CMS** (misma lógica que `news/IAcreate/create`),
|
|
3026
|
+
* devolviendo el `fileName` (path VFS) para que el front abra el editor.
|
|
3027
|
+
*/
|
|
3028
|
+
export declare interface CopilotGenerateResponse extends CmsResponse {
|
|
3029
|
+
copilotEnabled?: boolean;
|
|
3030
|
+
opportunity_id?: string;
|
|
3031
|
+
/** Código de resultado devuelto por el microservicio (omitido si es nulo). */
|
|
3032
|
+
code?: string;
|
|
3033
|
+
/**
|
|
3034
|
+
* Path VFS de la nota recién creada. El front lo usa para abrir el editor de
|
|
3035
|
+
* noticias (`/new_post/{fileName}/edit/{idPublicación}`). Solo si la creación
|
|
3036
|
+
* fue exitosa.
|
|
3037
|
+
*/
|
|
3038
|
+
fileName?: string;
|
|
3039
|
+
/** Artículo generado por IA (título, cuerpo, tags, imágenes sugeridas…). */
|
|
3040
|
+
article?: CopilotArticle;
|
|
3041
|
+
}
|
|
3042
|
+
|
|
2985
3043
|
/** Filtros opcionales de POST /copilot/opportunities (passthrough al micro). */
|
|
2986
3044
|
export declare interface CopilotOpportunitiesFilters {
|
|
2987
3045
|
/** Filtro de estado de las oportunidades (p. ej. "open"). */
|
|
@@ -3342,7 +3400,7 @@ export declare type DropdownOption = {
|
|
|
3342
3400
|
|
|
3343
3401
|
export declare type EditorialOpportunityColors = typeof editorialOpportunityColors;
|
|
3344
3402
|
|
|
3345
|
-
export declare const editorialOpportunityColors: Record<"accent" | "text" | "topicBg" | "topicHoverBg" | "topicBorder" | "trending" | "listRowHover" | "assignBtnHover" | "generateBtn" | "generateBtnHover", string>;
|
|
3403
|
+
export declare const editorialOpportunityColors: Record<"accent" | "text" | "topicBg" | "topicHoverBg" | "topicBorder" | "trending" | "listRowHover" | "assignBtnHover" | "generateBtn" | "generateBtnHover" | "cardBg" | "iconBg" | "iconShadow" | "iconGradientPurple" | "iconGradientBlue" | "iconGradientGreen" | "iconGradientAmber", string>;
|
|
3346
3404
|
|
|
3347
3405
|
export declare const enMessages: {
|
|
3348
3406
|
readonly navigation: {
|
|
@@ -7206,7 +7264,7 @@ export declare const sizes: {
|
|
|
7206
7264
|
|
|
7207
7265
|
export declare type SourceColors = typeof sourceColors;
|
|
7208
7266
|
|
|
7209
|
-
export declare const sourceColors: Record<"rss" | "gtrends" | "sconsole" | "x", string>;
|
|
7267
|
+
export declare const sourceColors: Record<"rss" | "gtrends" | "sconsole" | "ga4" | "x", string>;
|
|
7210
7268
|
|
|
7211
7269
|
export declare type StateColors = typeof stateColors;
|
|
7212
7270
|
|