@roilab/crm-cli 0.18.0 → 0.21.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/CHANGELOG.md +114 -0
- package/LICENSE +21 -21
- package/README.md +156 -119
- package/SKILL.md +116 -4
- package/SURFACE.txt +84 -24
- package/dist/bin/crm.js +11 -6
- package/dist/bin/crm.js.map +1 -1
- package/dist/src/commands/change.js +314 -0
- package/dist/src/commands/change.js.map +1 -0
- package/dist/src/commands/doc.js +21 -7
- package/dist/src/commands/doc.js.map +1 -1
- package/dist/src/commands/generic.js +76 -39
- package/dist/src/commands/generic.js.map +1 -1
- package/dist/src/commands/options.js +8 -1
- package/dist/src/commands/options.js.map +1 -1
- package/dist/src/commands/review.js +1 -1
- package/dist/src/commands/review.js.map +1 -1
- package/dist/src/commands/site.js +268 -0
- package/dist/src/commands/site.js.map +1 -0
- package/dist/src/commands/task-verify.js +197 -0
- package/dist/src/commands/task-verify.js.map +1 -0
- package/dist/src/commands/task.js +15 -28
- package/dist/src/commands/task.js.map +1 -1
- package/dist/src/transport/usage.js +137 -0
- package/dist/src/transport/usage.js.map +1 -0
- package/dist/src/types.js +7 -1
- package/dist/src/types.js.map +1 -1
- package/package.json +58 -58
- package/skill-bundles/tools/ahrefs-tool/SKILL.md +5 -5
- package/skill-bundles/tools/brightlocal-tool/SKILL.md +5 -5
- package/skill-bundles/tools/dataforseo-tool/SKILL.md +5 -5
- package/skill-bundles/tools/google-analytics-tool/SKILL.md +5 -5
- package/skill-bundles/tools/google-search-console-tool/SKILL.md +5 -5
- package/skill-bundles/tools/local-falcon-tool/SKILL.md +5 -5
- package/skill-bundles/tools/localseodata-tool/SKILL.md +5 -5
- package/skill-bundles/tools/lsa-spy-tool/SKILL.md +5 -5
- package/skill-bundles/tools/screaming-frog-tool/SKILL.md +5 -5
- package/skill-bundles/tools/semrush-tool/SKILL.md +5 -5
- package/skill-bundles/tools/serpapi-tool/SKILL.md +5 -5
- package/skill-bundles/tools/task-preflight/SKILL.md +157 -157
- package/skill-bundles/tools/whitespark-tool/SKILL.md +5 -5
- package/dist/src/commands/marketplace.js +0 -158
- package/dist/src/commands/marketplace.js.map +0 -1
package/SURFACE.txt
CHANGED
|
@@ -30,9 +30,13 @@ CMD crm auth logout [name]
|
|
|
30
30
|
CMD crm task list --status <status> --domain <id> --board <id> --column <id> --assignee <id> --tag <id> --review-pending --review-acked --limit <n>
|
|
31
31
|
# --review-pending / --review-acked filtran la cola de revisión (agente pendiente
|
|
32
32
|
# de aceptar vs ya aceptada por staff).
|
|
33
|
-
# --board filtra
|
|
34
|
-
#
|
|
35
|
-
#
|
|
33
|
+
# --board filtra por tablero incluyendo su multi-home; --column por la columna
|
|
34
|
+
# en la que la tarea SE PINTA (sin colocación explícita cae en la primera columna
|
|
35
|
+
# de su estado, igual que el kanban), y ya implica su tablero. Sirven para leer
|
|
36
|
+
# una sola swimlane (p. ej. el backlog "To Do" de un board de redactores).
|
|
37
|
+
# Ambos bajan al índice del tablero: no truncan y no leen el workspace entero.
|
|
38
|
+
# Si hay más resultados que --limit (máx. 500), la respuesta lo dice en
|
|
39
|
+
# `summary` + `pagination.hasMore` en vez de recortar en silencio.
|
|
36
40
|
CMD crm task get <id>
|
|
37
41
|
# task get returns `participants[]` with name, role, expertise, and
|
|
38
42
|
# internalNotes (staff-only, markdown handling rules) — use it instead of a
|
|
@@ -61,8 +65,8 @@ CMD crm task preflight --title <title> --url <url> --domain <id> --limit <n> --s
|
|
|
61
65
|
# se borran salvo que también los pases); usa `--clear-files` para vaciar.
|
|
62
66
|
# `--description-file <path>` lee el cuerpo de un fichero (markdown / code fences
|
|
63
67
|
# seguros, evita la substitución de shell con backticks). Gana a `--description`.
|
|
64
|
-
CMD crm task create --title <title> --description <text> --description-file <path> --domain <id> --board <id> --status <status> --assignee <id...> --collaborator <id...> --tag <id...> --start <date> --due <date> --completion-strategy <all|any|manual> --client-visible --no-review --file <path...>
|
|
65
|
-
CMD crm task update <id> --title <title> --description <text> --description-file <path> --status <status> --domain <id> --board <id> --column <id> --assignee <id...> --collaborator <id...> --tag <id...> --start <date> --due <date> --completion-strategy <all|any|manual> --client-visible --no-client-visible --file <path...> --clear-files
|
|
68
|
+
CMD crm task create --title <title> --description <text> --description-file <path> --domain <id> --board <id> --status <status> --assignee <id...> --collaborator <id...> --tag <id...> --start <date> --due <date> --completion-strategy <all|any|manual> --client-visible --completed-at <date> --no-review --file <path...>
|
|
69
|
+
CMD crm task update <id> --title <title> --description <text> --description-file <path> --status <status> --domain <id> --board <id> --column <id> --assignee <id...> --collaborator <id...> --tag <id...> --start <date> --due <date> --completion-strategy <all|any|manual> --client-visible --no-client-visible --completed-at <date> --file <path...> --clear-files
|
|
66
70
|
# task delete — destructivo, owner/admin. Borra la tarea (desadjunta timeEntries).
|
|
67
71
|
CMD crm task delete <id>
|
|
68
72
|
# Tableros kanban — `board list` descubre los tableros del workspace (id, nombre,
|
|
@@ -75,12 +79,11 @@ CMD crm task delete <id>
|
|
|
75
79
|
CMD crm board list --client <id> --archived
|
|
76
80
|
CMD crm board columns <boardId>
|
|
77
81
|
# Phase 41 — task ↔ backlink linking. `assets` returns the primary FK +
|
|
78
|
-
# outgoing mentions in one payload; `link-backlink`
|
|
79
|
-
#
|
|
80
|
-
#
|
|
82
|
+
# outgoing mentions in one payload; `link-backlink` sets the primary FK
|
|
83
|
+
# (use --unlink to clear); `complete-with-evidence` closes a task citing a
|
|
84
|
+
# backlink (server validates the comment cites the asset).
|
|
81
85
|
CMD crm task assets <id>
|
|
82
86
|
CMD crm task link-backlink <task-id> <backlink-id> --unlink
|
|
83
|
-
CMD crm task link-offer <task-id> <offer-id> --unlink
|
|
84
87
|
CMD crm task complete-with-evidence <task-id> --asset <kind:id> --comment <id>
|
|
85
88
|
# `task cancel` CIERRA la tarea sin contarla como entregada (status done +
|
|
86
89
|
# resolution cancelled). Úsalo en vez de `--status done` cuando el trabajo se
|
|
@@ -88,6 +91,28 @@ CMD crm task complete-with-evidence <task-id> --asset <kind:id> --comment <id>
|
|
|
88
91
|
# hecho. El motivo es obligatorio e interno (no lo ve el cliente). Para
|
|
89
92
|
# reabrirla: `crm task update <id> --status todo` (limpia la cancelación).
|
|
90
93
|
CMD crm task cancel <task-id> --reason <texto>
|
|
94
|
+
# `task verify` — revisión de métricas ("aplicada, pendiente de revisión").
|
|
95
|
+
# La tarea se completa el día que se aplica el cambio y se revisa N días
|
|
96
|
+
# después: ese día avisa al equipo y entra en `verify list` con la foto de
|
|
97
|
+
# métricas antes/después (ventanas simétricas alrededor del día aplicado +
|
|
98
|
+
# metas de ranking). Veredicto: positive | neutral | negative | inconclusive.
|
|
99
|
+
# Un AGENTE solo PROPONE (queda `proposed`, nota obligatoria, solo cuando ya
|
|
100
|
+
# venció); una persona lo confirma en la bandeja. Staff-only.
|
|
101
|
+
CMD crm task verify list --state <estado> --domain <id> --client <id>
|
|
102
|
+
CMD crm task verify show <task-id>
|
|
103
|
+
CMD crm task verify schedule <task-id> --in <días> --at <AAAA-MM-DD> --criteria <texto> --complete
|
|
104
|
+
CMD crm task verify snooze <task-id> --in <días> --at <AAAA-MM-DD>
|
|
105
|
+
CMD crm task verify resolve <task-id> --verdict <veredicto> --note <texto> --note-file <ruta>
|
|
106
|
+
CMD crm task verify measure <task-id>
|
|
107
|
+
CMD crm task verify clear <task-id>
|
|
108
|
+
|
|
109
|
+
# `task tracking` — URLs tocadas por la tarea y ámbito de su revisión de
|
|
110
|
+
# métricas. Cada registro de cambios añade su URL solo. Modos: urls (lista
|
|
111
|
+
# exacta), pattern (filtro de página GSC, RE2: '\.html$' = todas las fichas)
|
|
112
|
+
# o domain (propiedad entera). Al completar la tarea la revisión se programa
|
|
113
|
+
# sola a --verify-days (28 por defecto) del cierre.
|
|
114
|
+
CMD crm task tracking get <task-id>
|
|
115
|
+
CMD crm task tracking set <task-id> --urls <lista> --urls-file <path> --add-url <url...> --pattern <expr> --operator <regex|contains|not_regex|not_contains> --domain --verify-days <n> --auto-verify --no-auto-verify
|
|
91
116
|
# `task attach` — add/remove/list files INDIVIDUALLY (no clobber, unlike
|
|
92
117
|
# `task update --file` which replaces the whole list). `attach remove` takes the
|
|
93
118
|
# attachment id from `attach list`. Máx 10 MB/archivo, máx 50 archivos/tarea.
|
|
@@ -156,6 +181,12 @@ CMD crm property create --source-type <gsc|ga4|bing|ads|gbp> --identifier <id> -
|
|
|
156
181
|
CMD crm property update <id> --display-name <name> --client <id> --clear-client --domain <id> --clear-domain --favicon <url> --primary-metric <id>
|
|
157
182
|
|
|
158
183
|
CMD crm backlink list --domain <id> --status <status>
|
|
184
|
+
# create: da de alta un enlace conseguido. --source-url es la URL EXACTA de la
|
|
185
|
+
# pagina que enlaza, NUNCA el dominio (la salud se comprueba sobre esa URL, asi
|
|
186
|
+
# que un dominio suelto deja un backlink que no se puede verificar nunca).
|
|
187
|
+
# --target-url debe estar en el dominio indicado. Duplicado (mismo origen→destino
|
|
188
|
+
# y misma tipologia) devuelve el id existente sin escribir salvo --allow-duplicate.
|
|
189
|
+
CMD crm backlink create --domain <id> --source-url <url> --target-url <url> --go-live <YYYY-MM-DD> --placement-type <key> --anchor <text> --kind <link|mention> --link-type <dofollow|nofollow|ugc|sponsored> --brand-term <text> --provider <name> --cost <n> --currency <code> --notes <text> --contact-email <email> --task <id> --allow-duplicate
|
|
159
190
|
CMD crm backlink lost --domain <id> --since <iso>
|
|
160
191
|
CMD crm backlink list-tasks <backlink-id>
|
|
161
192
|
# Human-QA verbs (staff-only). `pending` lists rows awaiting review; `verify`
|
|
@@ -174,8 +205,6 @@ CMD crm backlink update <id> --source-url <url>
|
|
|
174
205
|
# Dry-run por defecto; --confirm gasta unidades (1 llamada filtrada, aborta si pocas).
|
|
175
206
|
CMD crm backlink reconcile --domain <id> --confirm --unit-floor <n>
|
|
176
207
|
|
|
177
|
-
CMD crm offer list-tasks <offer-id>
|
|
178
|
-
|
|
179
208
|
# Social profiles (Phase 44) — store + manage a domain's / client's handles.
|
|
180
209
|
# `--domain` for a site's profile, `--client` for a brand-level handle.
|
|
181
210
|
# platform=other requires `--label`. Staff-only.
|
|
@@ -184,7 +213,45 @@ CMD crm social create --platform <instagram|facebook|x|youtube|tiktok|linkedin|p
|
|
|
184
213
|
CMD crm social update <id> --platform <p> --url <url> --handle <h> --label <l> --primary --order <n> --notes <t> --internal-notes <t>
|
|
185
214
|
CMD crm social delete <id>
|
|
186
215
|
|
|
187
|
-
|
|
216
|
+
# Todos los filtros son opcionales y combinables — sin ninguno lista el
|
|
217
|
+
# workspace entero. --task es el más barato (índice propio) y devuelve lo mismo
|
|
218
|
+
# que el log de cambios del cajón de la tarea. --url sin --domain vale: el
|
|
219
|
+
# filtro de URL es exacto y se resuelve en el servidor.
|
|
220
|
+
CMD crm change list --domain <id> --task <id> --url <url> --since <iso>
|
|
221
|
+
|
|
222
|
+
# Registrar un cambio on-page (= botón «Registrar cambio» de la web). Un
|
|
223
|
+
# registro = una URL: un cambio con --type, o varios con --items-file (array
|
|
224
|
+
# JSON de {type,before,after,sourceUrl,anchor,direction,note}). --url por
|
|
225
|
+
# defecto = URL objetivo de la meta de la tarea. --date = fecha real de
|
|
226
|
+
# publicación (coloca el marcador en las gráficas; la revisión de métricas
|
|
227
|
+
# cuenta desde que se completa la tarea). La URL entra sola en el seguimiento
|
|
228
|
+
# de la tarea (crm task tracking get). Reglas por tipo:
|
|
229
|
+
# metaTitle/metaDesc/h1 → --after; content → --after-file o --note; link* →
|
|
230
|
+
# --source-url; linkChanged → --after (anchor nuevo); other → --note. Textos
|
|
231
|
+
# largos o con acentos por fichero (*-file, UTF-8). Staff-only; sin --shadow
|
|
232
|
+
# (no hay revisión de change events). Verifica en la página publicada antes.
|
|
233
|
+
CMD crm change log --task <id> --type <metaTitle|metaDesc|h1|content|linkAdded|linkRemoved|linkChanged|other> --url <url> --date <AAAA-MM-DD|iso> --before <t> --before-file <path> --after <t> --after-file <path> --source-url <url> --anchor <t> --direction <inbound|outbound> --note <t> --note-file <path>
|
|
234
|
+
CMD crm change log --task <id> --items-file <path.json> --url <url> --date <AAAA-MM-DD|iso> --note <t> --note-file <path>
|
|
235
|
+
|
|
236
|
+
# Conector de webs — tienda (PrestaShop) y blog (WordPress) con la credencial
|
|
237
|
+
# guardada en el CRM (Ajustes del dominio → Conexiones con la web). La
|
|
238
|
+
# credencial nunca sale del servidor. Una conexión la usan owner/admin y las
|
|
239
|
+
# personas autorizadas en ella. La URL elige la conexión (el blog en /blog
|
|
240
|
+
# gana a la tienda del mismo dominio). Campos: h1, metaTitle,
|
|
241
|
+
# metaDescription, content (HTML) y summary (extracto / descripción corta /
|
|
242
|
+
# descripción adicional). Fuera: URL/slug, noindex/canonical, precio, stock.
|
|
243
|
+
CMD crm site list --domain <id>
|
|
244
|
+
CMD crm site test <connection-id>
|
|
245
|
+
# Reglas de publicación de la web (perfil del dominio, normas, comprobaciones,
|
|
246
|
+
# skills y documentos completos). Obligatorio antes de escribir: update exige
|
|
247
|
+
# haber leído la versión vigente en las últimas 24 h.
|
|
248
|
+
CMD crm site rules --url <url> --connection <id>
|
|
249
|
+
# Lee la página tal como está ahora. Siempre antes de cambiar nada.
|
|
250
|
+
CMD crm site get --url <url> --ref <post|page|product|category|cms:id> --connection <id>
|
|
251
|
+
# Escribe solo lo que cambia, vuelve a leer para confirmar, comprueba la página
|
|
252
|
+
# publicada y crea el registro de cambios de la tarea (antes/después reales).
|
|
253
|
+
# --task obligatorio (mismo dominio). Textos largos por fichero (UTF-8).
|
|
254
|
+
CMD crm site update --task <id> --url <url> --ref <tipo:id> --connection <id> --h1 <t> --h1-file <path> --meta-title <t> --meta-title-file <path> --meta-desc <t> --meta-desc-file <path> --content <html> --content-file <path> --summary <html> --summary-file <path> --author <id> --note <t> --note-file <path> --dry-run
|
|
188
255
|
|
|
189
256
|
CMD crm scope list --domain <id> --kind <saved|ephemeral>
|
|
190
257
|
CMD crm scope get <id>
|
|
@@ -218,6 +285,9 @@ CMD crm inbox read <category>
|
|
|
218
285
|
|
|
219
286
|
CMD crm review list --mine --key <apiKeyId>
|
|
220
287
|
CMD crm review show <task|comment|edit> <id>
|
|
288
|
+
# review approve task <id> sobre una tarea aplicada con REVISAR (reviewRequired) la
|
|
289
|
+
# acepta (= botón Aceptar de la web); --completed-at fecha trabajo cerrado fuera
|
|
290
|
+
# del CRM (solo staff, tarea en done, sin fechas futuras).
|
|
221
291
|
CMD crm review approve <task|comment|edit> <id>
|
|
222
292
|
CMD crm review reject <task|comment|edit> <id> --reason <text>
|
|
223
293
|
# Agent iteration loop — read your own rejected proposals + the reviewer's
|
|
@@ -302,8 +372,8 @@ CMD crm doc list --client <id> --kind <proceso|guia|nota|entregable> --status <d
|
|
|
302
372
|
CMD crm doc get <slug> --client <id>
|
|
303
373
|
CMD crm doc content <slug> --client <id> --revision <id>
|
|
304
374
|
CMD crm doc revisions <slug> --client <id>
|
|
305
|
-
CMD crm doc create --client <id> --slug <slug> --title <text> --summary <text> --kind <proceso|guia|nota|entregable> --domain <id> --body <md> --body-file <path>
|
|
306
|
-
CMD crm doc update <slug> --client <id> --title <text> --summary <text> --kind <kind> --domain <id> --body <md> --body-file <path>
|
|
375
|
+
CMD crm doc create --client <id> --slug <slug> --title <text> --summary <text> --kind <proceso|guia|nota|entregable> --domain <id> --body <md> --body-file <path> --format <markdown|html>
|
|
376
|
+
CMD crm doc update <slug> --client <id> --title <text> --summary <text> --kind <kind> --domain <id> --body <md> --body-file <path> --format <markdown|html>
|
|
307
377
|
CMD crm doc publish <slug> --client <id> --note <text>
|
|
308
378
|
CMD crm doc share <slug> --client <id> --retract
|
|
309
379
|
CMD crm doc archive <slug> --client <id>
|
|
@@ -371,16 +441,6 @@ CMD crm report snapshot <id>
|
|
|
371
441
|
CMD crm report approve <id> --note <text>
|
|
372
442
|
CMD crm report reject <id> --reason <text>
|
|
373
443
|
|
|
374
|
-
# Marketplace — comparador cross-provider de precios de backlinks (Phase 35).
|
|
375
|
-
# `compare` consulta el catálogo global con filtros; `domain <domain>` agrupa
|
|
376
|
-
# las ofertas de un dominio; `providers` lista los proveedores; `import` carga
|
|
377
|
-
# ofertas manualmente (--file/--stdin); `scrape` dispara el worker hosted.
|
|
378
|
-
CMD crm marketplace compare --search <text> --provider <id> --country <iso2> --min-dr <n> --max-price <eur> --in-stock
|
|
379
|
-
CMD crm marketplace domain <domain>
|
|
380
|
-
CMD crm marketplace providers
|
|
381
|
-
CMD crm marketplace import --provider <id> --file <path> --stdin
|
|
382
|
-
CMD crm marketplace scrape --provider <id>
|
|
383
|
-
|
|
384
444
|
# Dump the full CLI surface as JSON so agents can introspect without help-text
|
|
385
445
|
# parsing. `{ data: { tree, flat } }` — `flat` is the linear command list.
|
|
386
446
|
CMD crm commands
|
package/dist/bin/crm.js
CHANGED
|
@@ -26,8 +26,9 @@ import { registerTime } from "../src/commands/time.js";
|
|
|
26
26
|
import { registerRank } from "../src/commands/rank.js";
|
|
27
27
|
import { registerMeta } from "../src/commands/meta.js";
|
|
28
28
|
import { registerReport } from "../src/commands/report.js";
|
|
29
|
-
import {
|
|
29
|
+
import { registerSite } from "../src/commands/site.js";
|
|
30
30
|
import { maybeNudgeFromCache, readInstalledVersion, refreshCacheInBackground, } from "../src/utils/version-check.js";
|
|
31
|
+
import { installUsageEnvelope, handleTopLevelError } from "../src/transport/usage.js";
|
|
31
32
|
const program = new Command();
|
|
32
33
|
program
|
|
33
34
|
.name("crm")
|
|
@@ -35,6 +36,10 @@ program
|
|
|
35
36
|
// Single source of truth: read from package.json so `crm --version`,
|
|
36
37
|
// the `User-Agent` header, and the cache nudge all agree.
|
|
37
38
|
.version(readInstalledVersion());
|
|
39
|
+
// Antes de registrar nada: `.command()` copia estos ajustes a cada hijo en el
|
|
40
|
+
// momento de crearlo, así que un error de parseo en cualquier subcomando sale
|
|
41
|
+
// como envoltura JSON y no como texto suelto por stderr.
|
|
42
|
+
installUsageEnvelope(program);
|
|
38
43
|
registerGlobalFlags(program);
|
|
39
44
|
registerAuth(program);
|
|
40
45
|
registerAccess(program);
|
|
@@ -53,17 +58,17 @@ registerTime(program);
|
|
|
53
58
|
registerRank(program);
|
|
54
59
|
registerMeta(program);
|
|
55
60
|
registerReport(program);
|
|
56
|
-
|
|
61
|
+
registerSite(program);
|
|
57
62
|
registerCommands(program);
|
|
58
63
|
registerDoctor(program);
|
|
64
|
+
// Cinturón y tirantes: cubre cualquier subcomando enganchado con addCommand()
|
|
65
|
+
// en vez de .command(), que no hereda los ajustes del padre.
|
|
66
|
+
installUsageEnvelope(program);
|
|
59
67
|
// Nudge basado en cache: instantáneo, sin red. `crm doctor` refresca contra npm.
|
|
60
68
|
maybeNudgeFromCache();
|
|
61
69
|
// Si la cache está caducada (>24h) o no existe, lanza un hijo desacoplado que
|
|
62
70
|
// la refresque contra el registro de npm. Fire-and-forget — el foreground
|
|
63
71
|
// sigue corriendo sin esperar.
|
|
64
72
|
refreshCacheInBackground();
|
|
65
|
-
program.parseAsync(process.argv).catch((err) =>
|
|
66
|
-
process.stderr.write(`[INTERNO] ${err instanceof Error ? err.message : String(err)}\n`);
|
|
67
|
-
process.exit(1);
|
|
68
|
-
});
|
|
73
|
+
program.parseAsync(process.argv).catch((err) => handleTopLevelError(err));
|
|
69
74
|
//# sourceMappingURL=crm.js.map
|
package/dist/bin/crm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crm.js","sourceRoot":"","sources":["../../bin/crm.ts"],"names":[],"mappings":";AACA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,0B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CAAC;AACtB,cAAc,CAAC,OAAO,CAAC,CAAC;AACxB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,aAAa,CAAC,OAAO,CAAC,CAAC;AACvB,eAAe,CAAC,OAAO,CAAC,CAAC;AACzB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,eAAe,CAAC,OAAO,CAAC,CAAC;AACzB,aAAa,CAAC,OAAO,CAAC,CAAC;AACvB,eAAe,CAAC,OAAO,CAAC,CAAC;AACzB,cAAc,CAAC,OAAO,CAAC,CAAC;AACxB,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAC9B,aAAa,CAAC,OAAO,CAAC,CAAC;AACvB,WAAW,CAAC,OAAO,CAAC,CAAC;AACrB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,cAAc,CAAC,OAAO,CAAC,CAAC;AACxB,YAAY,CAAC,OAAO,CAAC,CAAC;AACtB,gBAAgB,CAAC,OAAO,CAAC,CAAC;AAC1B,cAAc,CAAC,OAAO,CAAC,CAAC;AAExB,8EAA8E;AAC9E,6DAA6D;AAC7D,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAE9B,iFAAiF;AACjF,mBAAmB,EAAE,CAAC;AACtB,8EAA8E;AAC9E,0EAA0E;AAC1E,+BAA+B;AAC/B,wBAAwB,EAAE,CAAC;AAE3B,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,mBAAmB,CAAC,GAAG,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `crm change` — log de cambios SEO on-page (`changeEvents`).
|
|
3
|
+
*
|
|
4
|
+
* - `list` lee el log (GET /changes).
|
|
5
|
+
* - `log` registra un cambio (POST /changes): el equivalente del botón
|
|
6
|
+
* "Registrar cambio" de la ficha de tarea. La fecha del registro coloca el
|
|
7
|
+
* marcador en las gráficas; la URL entra en el seguimiento de la tarea
|
|
8
|
+
* (`crm task tracking`), que es lo que mide su revisión de métricas.
|
|
9
|
+
*
|
|
10
|
+
* Los textos largos (contenido, metas con acentos) entran por fichero
|
|
11
|
+
* (`--before-file` / `--after-file` / `--note-file` / `--items-file`): en
|
|
12
|
+
* Windows los argumentos con saltos de línea, comillas o acentos se rompen
|
|
13
|
+
* por el camino del shell. Los ficheros se leen como UTF-8 y se les quita el
|
|
14
|
+
* BOM que mete PowerShell.
|
|
15
|
+
*/
|
|
16
|
+
import { readFileSync } from "node:fs";
|
|
17
|
+
import { CommanderError } from "commander";
|
|
18
|
+
import { run } from "../transport/run.js";
|
|
19
|
+
import { EXIT } from "../types.js";
|
|
20
|
+
import { outputFromFlags, readFlags } from "./options.js";
|
|
21
|
+
const CHANGE_TYPES = [
|
|
22
|
+
"metaTitle",
|
|
23
|
+
"metaDesc",
|
|
24
|
+
"h1",
|
|
25
|
+
"content",
|
|
26
|
+
"linkAdded",
|
|
27
|
+
"linkRemoved",
|
|
28
|
+
"linkChanged",
|
|
29
|
+
"other",
|
|
30
|
+
];
|
|
31
|
+
const LINK_TYPES = new Set(["linkAdded", "linkRemoved", "linkChanged"]);
|
|
32
|
+
const META_TYPES = new Set(["metaTitle", "metaDesc", "h1"]);
|
|
33
|
+
const ITEM_KEYS = new Set(["type", "before", "after", "sourceUrl", "anchor", "direction", "note"]);
|
|
34
|
+
/**
|
|
35
|
+
* Error de argumentos: lo recoge `handleTopLevelError` y sale como envoltura
|
|
36
|
+
* JSON `USAGE` por stdout con exit 64 — el mismo contrato que los fallos de
|
|
37
|
+
* parseo de commander (ver `transport/usage.ts`).
|
|
38
|
+
*/
|
|
39
|
+
function usage(message) {
|
|
40
|
+
throw new CommanderError(EXIT.USAGE, "crm.usage", message);
|
|
41
|
+
}
|
|
42
|
+
function readUtf8(path, flag) {
|
|
43
|
+
try {
|
|
44
|
+
return readFileSync(path, "utf8").replace(/^/, "");
|
|
45
|
+
}
|
|
46
|
+
catch (err) {
|
|
47
|
+
usage(`No se pudo leer ${flag} ${path}: ${err.message}`);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
/** Valor de un campo desde `--x` o `--x-file` (excluyentes). */
|
|
51
|
+
function textFrom(inline, file, flag) {
|
|
52
|
+
if (inline !== undefined && file !== undefined) {
|
|
53
|
+
usage(`No combines ${flag} y ${flag}-file: elige uno.`);
|
|
54
|
+
}
|
|
55
|
+
return file !== undefined ? readUtf8(file, `${flag}-file`) : inline;
|
|
56
|
+
}
|
|
57
|
+
const has = (s) => s !== undefined && s.trim().length > 0;
|
|
58
|
+
/**
|
|
59
|
+
* Fecha del cambio → ISO. `AAAA-MM-DD` se fija a las 12:00 locales (mismo día
|
|
60
|
+
* natural para quien mire la gráfica en Europa o América); si eso cae en el
|
|
61
|
+
* futuro (hoy por la mañana), se usa ahora.
|
|
62
|
+
*/
|
|
63
|
+
function parseDate(raw) {
|
|
64
|
+
const value = raw.trim();
|
|
65
|
+
const dateOnly = /^(\d{4})-(\d{2})-(\d{2})$/.exec(value);
|
|
66
|
+
if (dateOnly) {
|
|
67
|
+
const [, y, m, d] = dateOnly;
|
|
68
|
+
const noon = new Date(Number(y), Number(m) - 1, Number(d), 12, 0, 0, 0);
|
|
69
|
+
if (noon.getMonth() !== Number(m) - 1 || noon.getDate() !== Number(d)) {
|
|
70
|
+
usage(`--date no es una fecha válida: "${raw}".`);
|
|
71
|
+
}
|
|
72
|
+
return (noon.getTime() > Date.now() ? new Date() : noon).toISOString();
|
|
73
|
+
}
|
|
74
|
+
if (/^\d{4}-\d{2}-\d{2}T/.test(value)) {
|
|
75
|
+
const ms = Date.parse(value);
|
|
76
|
+
if (!Number.isNaN(ms))
|
|
77
|
+
return new Date(ms).toISOString();
|
|
78
|
+
}
|
|
79
|
+
usage(`--date espera AAAA-MM-DD o ISO 8601 (2026-10-19T09:30:00Z), no "${raw}".`);
|
|
80
|
+
}
|
|
81
|
+
/** Reglas por tipo — las mismas que el compositor web y el servidor. */
|
|
82
|
+
function checkItem(item, where) {
|
|
83
|
+
const t = item.type;
|
|
84
|
+
if (META_TYPES.has(t) && !has(item.after)) {
|
|
85
|
+
usage(`${where}: ${t} necesita el valor nuevo (--after / --after-file).`);
|
|
86
|
+
}
|
|
87
|
+
if (t === "content" && !has(item.after) && !has(item.note)) {
|
|
88
|
+
usage(`${where}: content necesita el contenido nuevo (--after-file) o un resumen (--note).`);
|
|
89
|
+
}
|
|
90
|
+
if (LINK_TYPES.has(t) && !has(item.sourceUrl)) {
|
|
91
|
+
usage(`${where}: ${t} necesita --source-url (destino del enlace, u origen si es inbound).`);
|
|
92
|
+
}
|
|
93
|
+
if (t === "linkChanged" && !has(item.after)) {
|
|
94
|
+
usage(`${where}: linkChanged necesita el anchor nuevo en --after (el anterior va en --before).`);
|
|
95
|
+
}
|
|
96
|
+
if (t === "other" && !has(item.note)) {
|
|
97
|
+
usage(`${where}: other necesita --note describiendo el cambio.`);
|
|
98
|
+
}
|
|
99
|
+
// Campos que no aplican al tipo: se rechazan en vez de descartarlos en
|
|
100
|
+
// silencio, para que el agente no crea que registró algo que no se guardó.
|
|
101
|
+
if (LINK_TYPES.has(t)) {
|
|
102
|
+
if (t !== "linkChanged" && item.before !== undefined) {
|
|
103
|
+
usage(`${where}: ${t} no admite --before (solo linkChanged guarda el anchor anterior).`);
|
|
104
|
+
}
|
|
105
|
+
if (t !== "linkChanged" && item.after !== undefined) {
|
|
106
|
+
usage(`${where}: ${t} no admite --after (usa --anchor).`);
|
|
107
|
+
}
|
|
108
|
+
if (t === "linkChanged" && item.anchor !== undefined) {
|
|
109
|
+
usage(`${where}: linkChanged no admite --anchor (anterior en --before, nuevo en --after).`);
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
else {
|
|
113
|
+
for (const [key, flag] of [
|
|
114
|
+
["sourceUrl", "--source-url"],
|
|
115
|
+
["anchor", "--anchor"],
|
|
116
|
+
["direction", "--direction"],
|
|
117
|
+
]) {
|
|
118
|
+
if (item[key] !== undefined)
|
|
119
|
+
usage(`${where}: ${flag} solo aplica a linkAdded/linkRemoved/linkChanged.`);
|
|
120
|
+
}
|
|
121
|
+
if (t === "other" && (item.before !== undefined || item.after !== undefined)) {
|
|
122
|
+
usage(`${where}: other no admite --before/--after; describe el cambio en --note.`);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
function asType(raw, where) {
|
|
127
|
+
if (typeof raw !== "string" || !CHANGE_TYPES.includes(raw)) {
|
|
128
|
+
usage(`${where}: type debe ser ${CHANGE_TYPES.join(" | ")} (recibido: ${JSON.stringify(raw)}).`);
|
|
129
|
+
}
|
|
130
|
+
return raw;
|
|
131
|
+
}
|
|
132
|
+
function asDirection(raw, where) {
|
|
133
|
+
if (raw === undefined)
|
|
134
|
+
return undefined;
|
|
135
|
+
if (raw !== "inbound" && raw !== "outbound") {
|
|
136
|
+
usage(`${where}: direction debe ser inbound | outbound (recibido: ${JSON.stringify(raw)}).`);
|
|
137
|
+
}
|
|
138
|
+
return raw;
|
|
139
|
+
}
|
|
140
|
+
/** `--items-file`: array de ítems, o `{ "note": "...", "items": [...] }`. */
|
|
141
|
+
function readItemsFile(path) {
|
|
142
|
+
let parsed;
|
|
143
|
+
try {
|
|
144
|
+
parsed = JSON.parse(readUtf8(path, "--items-file"));
|
|
145
|
+
}
|
|
146
|
+
catch (err) {
|
|
147
|
+
if (err instanceof CommanderError)
|
|
148
|
+
throw err;
|
|
149
|
+
usage(`--items-file ${path} no es JSON válido: ${err.message}`);
|
|
150
|
+
}
|
|
151
|
+
let rawItems = parsed;
|
|
152
|
+
let note;
|
|
153
|
+
if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) {
|
|
154
|
+
const obj = parsed;
|
|
155
|
+
rawItems = obj.items;
|
|
156
|
+
if (obj.note !== undefined) {
|
|
157
|
+
if (typeof obj.note !== "string")
|
|
158
|
+
usage("--items-file: note debe ser texto.");
|
|
159
|
+
note = obj.note;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
if (!Array.isArray(rawItems) || rawItems.length === 0) {
|
|
163
|
+
usage('--items-file debe contener un array de ítems no vacío, o { "items": [...] }.');
|
|
164
|
+
}
|
|
165
|
+
const items = rawItems.map((raw, idx) => {
|
|
166
|
+
const where = `ítem #${idx + 1} de --items-file`;
|
|
167
|
+
if (!raw || typeof raw !== "object" || Array.isArray(raw))
|
|
168
|
+
usage(`${where}: debe ser un objeto.`);
|
|
169
|
+
const obj = raw;
|
|
170
|
+
for (const key of Object.keys(obj)) {
|
|
171
|
+
if (!ITEM_KEYS.has(key)) {
|
|
172
|
+
usage(`${where}: campo desconocido "${key}" (válidos: ${[...ITEM_KEYS].join(", ")}).`);
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
for (const key of ["before", "after", "sourceUrl", "anchor", "note"]) {
|
|
176
|
+
if (obj[key] !== undefined && typeof obj[key] !== "string")
|
|
177
|
+
usage(`${where}: ${key} debe ser texto.`);
|
|
178
|
+
}
|
|
179
|
+
const item = {
|
|
180
|
+
type: asType(obj.type, where),
|
|
181
|
+
before: obj.before,
|
|
182
|
+
after: obj.after,
|
|
183
|
+
sourceUrl: obj.sourceUrl,
|
|
184
|
+
anchor: obj.anchor,
|
|
185
|
+
direction: asDirection(obj.direction, where),
|
|
186
|
+
note: obj.note,
|
|
187
|
+
};
|
|
188
|
+
checkItem(item, where);
|
|
189
|
+
return item;
|
|
190
|
+
});
|
|
191
|
+
return { items, note };
|
|
192
|
+
}
|
|
193
|
+
/** Arma el body de POST /changes validando la línea de comandos entera. */
|
|
194
|
+
export function buildChangeLogBody(opts) {
|
|
195
|
+
if (opts.url !== undefined && !/^https?:\/\/\S+$/i.test(opts.url.trim())) {
|
|
196
|
+
usage(`--url debe ser absoluta (http:// o https://), no "${opts.url}".`);
|
|
197
|
+
}
|
|
198
|
+
const occurredAt = opts.date !== undefined ? parseDate(opts.date) : undefined;
|
|
199
|
+
const note = textFrom(opts.note, opts.noteFile, "--note");
|
|
200
|
+
if ((opts.itemsFile === undefined) === (opts.type === undefined)) {
|
|
201
|
+
usage("Indica --type <tipo> para un cambio, o --items-file <ruta.json> para varios (uno de los dos).");
|
|
202
|
+
}
|
|
203
|
+
let items;
|
|
204
|
+
let entryNote;
|
|
205
|
+
if (opts.itemsFile !== undefined) {
|
|
206
|
+
const itemFlags = [
|
|
207
|
+
[opts.before, "--before"],
|
|
208
|
+
[opts.beforeFile, "--before-file"],
|
|
209
|
+
[opts.after, "--after"],
|
|
210
|
+
[opts.afterFile, "--after-file"],
|
|
211
|
+
[opts.sourceUrl, "--source-url"],
|
|
212
|
+
[opts.anchor, "--anchor"],
|
|
213
|
+
[opts.direction, "--direction"],
|
|
214
|
+
];
|
|
215
|
+
const clash = itemFlags.find(([v]) => v !== undefined);
|
|
216
|
+
if (clash)
|
|
217
|
+
usage(`${clash[1]} no se combina con --items-file: pon ese campo dentro del JSON.`);
|
|
218
|
+
const fromFile = readItemsFile(opts.itemsFile);
|
|
219
|
+
if (fromFile.note !== undefined && note !== undefined) {
|
|
220
|
+
usage('Nota duplicada: va en --note o en el "note" de --items-file, no en los dos.');
|
|
221
|
+
}
|
|
222
|
+
items = fromFile.items;
|
|
223
|
+
// Con varios ítems, --note es la nota general del registro.
|
|
224
|
+
entryNote = note ?? fromFile.note;
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
const item = {
|
|
228
|
+
type: asType(opts.type, "--type"),
|
|
229
|
+
before: textFrom(opts.before, opts.beforeFile, "--before"),
|
|
230
|
+
after: textFrom(opts.after, opts.afterFile, "--after"),
|
|
231
|
+
sourceUrl: opts.sourceUrl,
|
|
232
|
+
anchor: opts.anchor,
|
|
233
|
+
direction: asDirection(opts.direction, "--direction"),
|
|
234
|
+
// Con un solo ítem, --note es la nota del cambio (la que la web
|
|
235
|
+
// muestra bajo el ítem y la que exigen content/other).
|
|
236
|
+
note,
|
|
237
|
+
};
|
|
238
|
+
checkItem(item, "--type " + item.type);
|
|
239
|
+
items = [item];
|
|
240
|
+
}
|
|
241
|
+
return {
|
|
242
|
+
taskId: opts.task,
|
|
243
|
+
...(opts.url !== undefined ? { url: opts.url.trim() } : {}),
|
|
244
|
+
...(occurredAt !== undefined ? { occurredAt } : {}),
|
|
245
|
+
items,
|
|
246
|
+
...(entryNote !== undefined ? { note: entryNote } : {}),
|
|
247
|
+
};
|
|
248
|
+
}
|
|
249
|
+
export function registerChange(program) {
|
|
250
|
+
const change = program.command("change").description("Log de cambios SEO on-page");
|
|
251
|
+
change
|
|
252
|
+
.command("list")
|
|
253
|
+
.description("Lista eventos de cambios on-page. Todos los filtros son opcionales y combinables: sin ninguno lista el workspace entero.")
|
|
254
|
+
.option("--domain <id>", "filtra por dominio (id ms7…, no el host)")
|
|
255
|
+
.option("--task <id>", "filtra por tarea — el filtro más barato (índice propio)")
|
|
256
|
+
.option("--url <url>", "filtra a una URL concreta (coincidencia exacta)")
|
|
257
|
+
.option("--since <iso>", "límite inferior de occurredAt")
|
|
258
|
+
.action(async (opts, cmd) => {
|
|
259
|
+
const flags = readFlags(cmd);
|
|
260
|
+
await run({
|
|
261
|
+
method: "GET",
|
|
262
|
+
path: "/changes",
|
|
263
|
+
request: {
|
|
264
|
+
query: {
|
|
265
|
+
domainId: opts.domain,
|
|
266
|
+
taskId: opts.task,
|
|
267
|
+
url: opts.url,
|
|
268
|
+
// `--since` y `--limit` también viven en la raíz: el valor
|
|
269
|
+
// aterriza ahí, no en `opts`. Ver readFlags en options.ts.
|
|
270
|
+
sinceIso: flags.since,
|
|
271
|
+
limit: flags.limit,
|
|
272
|
+
},
|
|
273
|
+
},
|
|
274
|
+
output: outputFromFlags(flags),
|
|
275
|
+
profile: flags.profile,
|
|
276
|
+
});
|
|
277
|
+
});
|
|
278
|
+
change
|
|
279
|
+
.command("log")
|
|
280
|
+
.description("Registra un cambio on-page en una tarea (= botón 'Registrar cambio' de la web). Un registro = una URL; " +
|
|
281
|
+
"un cambio con --type, o varios con --items-file. La fecha (--date) coloca el marcador en las gráficas: pon la de " +
|
|
282
|
+
"publicación real. La URL entra sola en el seguimiento de la tarea (crm task tracking get). Verifica el cambio en " +
|
|
283
|
+
"la página publicada ANTES de registrarlo; si lo aplicas con `crm site update`, el registro se crea solo.")
|
|
284
|
+
.requiredOption("--task <id>", "id de la tarea (debe estar anclada a un dominio)")
|
|
285
|
+
.option("--url <url>", "URL editada, absoluta. Por defecto, la URL objetivo de la meta de la tarea (si no tiene, es obligatoria)")
|
|
286
|
+
.option("--date <fecha>", "fecha del cambio: AAAA-MM-DD (12:00 locales) o ISO 8601. Por defecto, ahora")
|
|
287
|
+
.option("--type <tipo>", `tipo del cambio: ${CHANGE_TYPES.join(" | ")}`)
|
|
288
|
+
.option("--before <texto>", "valor anterior (meta/H1/contenido; anchor anterior en linkChanged)")
|
|
289
|
+
.option("--before-file <ruta>", "lee el valor anterior de un fichero UTF-8 (textos largos o con acentos)")
|
|
290
|
+
.option("--after <texto>", "valor nuevo (obligatorio en metaTitle/metaDesc/h1/linkChanged)")
|
|
291
|
+
.option("--after-file <ruta>", "lee el valor nuevo de un fichero UTF-8")
|
|
292
|
+
.option("--source-url <url>", "enlaces: destino (outbound) u origen (inbound). Obligatorio en link*")
|
|
293
|
+
.option("--anchor <texto>", "anchor del enlace (linkAdded/linkRemoved)")
|
|
294
|
+
.option("--direction <dir>", "enlaces: outbound (por defecto) | inbound")
|
|
295
|
+
.option("--note <texto>", "con --type: nota del cambio (obligatoria en other; en content basta en lugar del texto completo). Con --items-file: nota general")
|
|
296
|
+
.option("--note-file <ruta>", "lee --note de un fichero UTF-8")
|
|
297
|
+
.option("--items-file <ruta.json>", 'varios cambios en la misma URL: array JSON de {type, before, after, sourceUrl, anchor, direction, note}, o { "note": "...", "items": [...] }')
|
|
298
|
+
.action(async (opts, cmd) => {
|
|
299
|
+
const flags = readFlags(cmd);
|
|
300
|
+
const body = buildChangeLogBody(opts);
|
|
301
|
+
await run({
|
|
302
|
+
method: "POST",
|
|
303
|
+
path: "/changes",
|
|
304
|
+
request: {
|
|
305
|
+
body: { ...body, ...(flags.shadow ? { shadow: true } : {}) },
|
|
306
|
+
idempotencyKey: flags.idempotencyKey,
|
|
307
|
+
},
|
|
308
|
+
output: outputFromFlags(flags),
|
|
309
|
+
profile: flags.profile,
|
|
310
|
+
asAgent: flags.asAgent,
|
|
311
|
+
});
|
|
312
|
+
});
|
|
313
|
+
}
|
|
314
|
+
//# sourceMappingURL=change.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"change.js","sourceRoot":"","sources":["../../../src/commands/change.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAW,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,GAAG,EAAE,MAAM,qBAAqB,CAAC;AAC1C,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACnC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAE1D,MAAM,YAAY,GAAG;IACnB,WAAW;IACX,UAAU;IACV,IAAI;IACJ,SAAS;IACT,WAAW;IACX,aAAa;IACb,aAAa;IACb,OAAO;CACC,CAAC;AAGX,MAAM,UAAU,GAA4B,IAAI,GAAG,CAAC,CAAC,WAAW,EAAE,aAAa,EAAE,aAAa,CAAC,CAAC,CAAC;AACjG,MAAM,UAAU,GAA4B,IAAI,GAAG,CAAC,CAAC,WAAW,EAAE,UAAU,EAAE,IAAI,CAAC,CAAC,CAAC;AACrF,MAAM,SAAS,GAAG,IAAI,GAAG,CAAC,CAAC,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,CAAC,CAAC,CAAC;AAYnG;;;;GAIG;AACH,SAAS,KAAK,CAAC,OAAe;IAC5B,M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