@datasynx/agentic-ai-cartography 2.11.0 → 2.12.1

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/mcp-bin.js CHANGED
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  parseMcpArgs,
4
4
  startMcp
5
- } from "./chunk-FFUUNSWP.js";
5
+ } from "./chunk-OIDAXUW5.js";
6
6
  import "./chunk-LO6YFS6H.js";
7
7
  import "./chunk-QQOQBE2A.js";
8
8
  import "./chunk-2SZ5QHGH.js";
package/llms-full.txt CHANGED
@@ -157,38 +157,318 @@ reusable **prompts**.
157
157
 
158
158
  # CLI reference
159
159
 
160
- `datasynx-cartography <command>` (the discovery/management CLI) and
161
- `cartography-mcp` (the MCP server binary).
160
+ Two binaries ship with Cartography:
162
161
 
163
- | Command | Purpose |
164
- | --- | --- |
165
- | `discover` | Scan and map your infrastructure (`--output-format text\|json\|stream-json`, `--name <name>`). |
166
- | `diff [base] [current]` | Compare two sessions for drift (`--format text\|json\|mermaid`). |
167
- | `schedule --config <file>` | Run discovery recurringly and record per-run drift (`--once` / `--watch`, config-file driven). |
168
- | `seed` | Manually add known tools/DBs/APIs. |
169
- | `install --client <id>` | Register the MCP server into a host's config. |
170
- | `list-clients` | List supported hosts. |
171
- | `mcp` | Run the MCP server (stdio by default; `--http` for Streamable HTTP). |
172
- | `export [session]` | Export Mermaid / JSON / YAML / HTML. |
173
- | `show [session]` | Show session details. |
174
- | `sessions` | List all sessions. |
175
- | `overview` | Aggregate overview across sessions. |
176
- | `bookmarks` | View browser bookmarks. |
177
- | `doctor` | Check requirements (kubectl, aws, gcloud, az). |
178
- | `prune` | Remove old sessions. |
179
- | `docs` | Full in-terminal feature reference. |
180
-
181
- ## `mcp` flags
162
+ - `datasynx-cartography <command>` the discovery & management CLI documented below.
163
+ - `cartography-mcp` starts the MCP server directly (equivalent to `datasynx-cartography mcp`; used by `server.json` via `npx`).
164
+
165
+ Global flags: `--version`, `--help`. `--db <path>` selects the catalog on most
166
+ commands; absent, the default catalog is used. All progress/log output goes to
167
+ stderr; machine-readable output goes to stdout.
168
+
169
+ Commands are grouped below by purpose: **Discovery**, **Analysis & insight**,
170
+ **Inspection**, **Consent & sync (collector client)**, **Servers**, and
171
+ **Setup & maintenance**.
172
+
173
+ ---
174
+
175
+ ## Discovery
176
+
177
+ ### `discover`
178
+
179
+ Scan and map your infrastructure (agentic by default; `--update` runs a deterministic local rescan).
180
+
181
+ `datasynx-cartography discover [options]`
182
+
183
+ | Flag | Default | Purpose |
184
+ | --- | --- | --- |
185
+ | `--entry <hosts...>` | `localhost` | Entry points to scan from. |
186
+ | `--depth <n>` | `8` | Max crawl depth (1–50). |
187
+ | `--max-turns <n>` | `50` | Max agent turns (1–500). |
188
+ | `--provider <name>` | `claude` | Agent provider: `claude`, `openai`, `ollama` (or `CARTOGRAPHY_PROVIDER`). |
189
+ | `--model <m>` | `claude-sonnet-4-5-20250929` | Agent model. |
190
+ | `--org <name>` | — | Organization/tenant name (scopes the session; used for Backstage). |
191
+ | `-o, --output <dir>` | `./datasynx-output` | Output directory. |
192
+ | `--db <path>` | default catalog | DB path. |
193
+ | `--name <name>` | auto-derived | Custom session name. |
194
+ | `--update [sessionId]` | — | Re-scan an existing session in place (deterministic local scan; default target: latest discover session). |
195
+ | `--output-format <fmt>` | `text` | Progress/result format: `text`, `json`, `stream-json`. |
196
+ | `-v, --verbose` | off | Show agent reasoning. |
197
+
198
+ ### `schedule`
199
+
200
+ Run discovery recurringly and record per-run topology drift (headless, read-only, no agent loop).
201
+
202
+ `datasynx-cartography schedule --config <file> [options]`
203
+
204
+ | Flag | Default | Purpose |
205
+ | --- | --- | --- |
206
+ | `--config <file>` | **required** | JSON config file with a `schedule` block. |
207
+ | `--once` | on (default) | Run a single pass and exit (cron-driver friendly). |
208
+ | `--watch` | off | Run continuously on the configured cron schedule. Mutually exclusive with `--once`; requires `schedule.cron`. |
209
+ | `--output-format <fmt>` | config / `json` | Result format: `text`, `json`, `stream-json` (overrides config). |
210
+ | `--db <path>` | config | DB path (overrides config). |
211
+
212
+ ### `seed`
213
+
214
+ Manually add known infrastructure (tools, DBs, APIs, etc.).
215
+
216
+ `datasynx-cartography seed [options]`
217
+
218
+ | Flag | Default | Purpose |
219
+ | --- | --- | --- |
220
+ | `--file <path>` | — | JSON file with node definitions. |
221
+ | `--session <id>` | new session | Add to an existing session. |
222
+ | `--org <name>` | `local` | Tenant/organization to scope the session to. |
223
+ | `--db <path>` | default catalog | DB path. |
224
+
225
+ ---
226
+
227
+ ## Analysis & insight
228
+
229
+ ### `diff [base] [current]`
230
+
231
+ Compare two discovery sessions (drift detection). Defaults to the two most recent.
232
+
233
+ | Flag | Default | Purpose |
234
+ | --- | --- | --- |
235
+ | `--format <fmt>` | `text` | Output format: `text`, `json`, `mermaid`. |
236
+ | `-o, --output <file>` | stdout | Write to a file instead of stdout. |
237
+ | `--db <path>` | default catalog | DB path. |
238
+
239
+ ### `drift [base] [current]`
240
+
241
+ Classify drift between two sessions into a severity-ranked alert and emit it to configured sinks (default: stdout). Defaults to the two most recent. A single-session catalog is a clean no-op (exit 0).
242
+
243
+ | Flag | Default | Purpose |
244
+ | --- | --- | --- |
245
+ | `--min-severity <s>` | `info` | Minimum severity to emit: `info`, `warning`, `critical`. |
246
+ | `--webhook <url>` | — | Outbound webhook URL (overrides config; token via `CARTOGRAPHY_DRIFT_TOKEN`). |
247
+ | `--db <path>` | default catalog | DB path. |
248
+
249
+ ### `compliance [session-id]`
250
+
251
+ Score a session against a compliance ruleset (CIS / SOC 2 / ISO 27001 starter sets). Defaults to the latest session.
252
+
253
+ | Flag | Default | Purpose |
254
+ | --- | --- | --- |
255
+ | `--ruleset <name>` | `baseline` | Ruleset: `baseline`, `cis`, `soc2`, `iso27001`. |
256
+ | `--format <fmt>` | `text` | Output format: `text`, `json`, `markdown`, `mermaid`. |
257
+ | `-o, --output <file>` | stdout | Write to a file instead of stdout. |
258
+ | `--db <path>` | default catalog | DB path. |
259
+
260
+ ### `cost`
261
+
262
+ Import cost/owner attribution from a CSV and enrich a session (FinOps).
263
+
264
+ `datasynx-cartography cost --file <path> [options]`
265
+
266
+ | Flag | Default | Purpose |
267
+ | --- | --- | --- |
268
+ | `--file <path>` | **required** | CSV: `nodeId,owner,amount,currency,period[,source]`. |
269
+ | `--session <id>` | latest | Session to enrich. |
270
+ | `--match <strategy>` | `nodeId` | Row→node match: `nodeId`, `name`, `tag`. |
271
+ | `--db <path>` | default catalog | DB path. |
272
+
273
+ ### `export [session-id]`
274
+
275
+ Generate all output files (Mermaid / JSON / YAML / HTML / map / cost). Defaults to the latest session.
276
+
277
+ | Flag | Default | Purpose |
278
+ | --- | --- | --- |
279
+ | `-o, --output <dir>` | `./datasynx-output` | Output directory. |
280
+ | `--format <fmt...>` | `mermaid json yaml html map` | Formats: `mermaid`, `json`, `yaml`, `html`, `map`, `cost`. |
281
+
282
+ ---
283
+
284
+ ## Inspection
285
+
286
+ ### `show [session-id]`
287
+
288
+ Show session details (mode, timing, node/edge/event counts, recent activity). Defaults to the latest session. No flags.
289
+
290
+ ### `sessions`
291
+
292
+ List all sessions. No flags.
293
+
294
+ ### `overview`
295
+
296
+ Aggregate overview across all cartography sessions.
297
+
298
+ | Flag | Default | Purpose |
299
+ | --- | --- | --- |
300
+ | `--db <path>` | default catalog | DB path. |
301
+
302
+ ### `chat [session-id]`
303
+
304
+ Interactive chat about your mapped infrastructure (uses `@anthropic-ai/sdk`; requires `ANTHROPIC_API_KEY`). Defaults to the latest completed session.
182
305
 
183
306
  | Flag | Default | Purpose |
184
307
  | --- | --- | --- |
185
- | `--http` | off | Use Streamable HTTP instead of stdio. |
308
+ | `--db <path>` | default catalog | DB path. |
309
+ | `--model <m>` | fast helper model | Model. |
310
+
311
+ ### `bookmarks`
312
+
313
+ View all browser bookmarks (Chrome, Chromium, Edge, Brave, Vivaldi, Opera, Firefox). No flags.
314
+
315
+ ### `docs`
316
+
317
+ Print the full in-terminal feature reference and all commands. No flags.
318
+
319
+ ---
320
+
321
+ ## Consent & sync (collector client)
322
+
323
+ These commands are the consent-gated outbound pipeline to a central collector.
324
+ They are opt-in; `sync` is inert unless `centralDb` is configured. Nothing leaves
325
+ the machine without an explicit approval or a remembered rule.
326
+
327
+ ### `consent`
328
+
329
+ Manage the per-employee data-sharing policy (`none` | `anonymized` | `full`) + admin anonymization. Sub-commands:
330
+
331
+ | Sub-command | Purpose | Flags |
332
+ | --- | --- | --- |
333
+ | `consent default <level>` | Set the global default sharing level (`none`/`anonymized`/`full`). | `--db <path>` |
334
+ | `consent set <pattern> <level>` | Set a pattern override (glob over the node id; `*` = within-segment, `**` = any). | `--db <path>` |
335
+ | `consent clear <pattern>` | Remove a pattern override (the global default cannot be cleared). | `--db <path>` |
336
+ | `consent list` | Show the global default + every pattern override. | `--db <path>` |
337
+ | `consent preview [session]` | Show exactly what would leave the machine for a session (default: latest). | `--db <path>`, `--org <name>` |
338
+ | `consent key rotate` | Rotate the org key (prior reversal entries become unrecoverable). | `--org <name>` |
339
+ | `consent reverse <token>` | Admin: recover the original plaintext behind a pseudonym token. | `--db <path>`, `--org <name>` |
340
+
341
+ `--org <name>` selects the organization namespace for the org key.
342
+
343
+ ### `sync`
344
+
345
+ Central-DB outbound sync: review queued items and push approved deltas (opt-in). Sub-commands:
346
+
347
+ | Sub-command | Purpose | Flags |
348
+ | --- | --- | --- |
349
+ | `sync status` | Show the pending-review queue (counts by status + pending items). | `--db <path>` |
350
+ | `sync review` | Interactively approve/withhold each pending item (decisions are remembered). | `--db <path>` |
351
+ | `sync push` | Push approved deltas to the central ingest endpoint (bearer-auth HTTPS). | `--db <path>`, `--dry-run` |
352
+
353
+ ---
354
+
355
+ ## Servers
356
+
357
+ ### `mcp`
358
+
359
+ Run the Model Context Protocol server (stdio by default) — the primary interface for AI agents. `--server-mode` turns the binary into a self-hostable central collector. The separate `cartography-mcp` binary is equivalent.
360
+
361
+ `datasynx-cartography mcp [options]`
362
+
363
+ | Flag | Default | Purpose |
364
+ | --- | --- | --- |
365
+ | `--http` | off | Use Streamable HTTP transport instead of stdio. |
186
366
  | `--port <n>` | `3737` | HTTP port. |
187
367
  | `--host <h>` | `127.0.0.1` | HTTP host. |
188
- | `--allowed-hosts <list>` | — | Host allowlist (required for non-loopback `--host`). |
189
- | `--db <path>` | default catalog | Catalog to serve. |
190
- | `--session <id>` | `latest` | Session to serve. |
368
+ | `--allowed-hosts <list>` | — | Comma-separated Host allowlist (required for non-loopback `--host`). |
369
+ | `--token <secret>` | | Bearer token required on HTTP requests (or `CARTOGRAPHY_HTTP_TOKEN`); mandatory for non-loopback `--host`. |
370
+ | `--db <path>` | default catalog | DB path. |
371
+ | `--session <id>` | `latest` | Session to serve (id or `"latest"`). |
372
+ | `--tenant <id>` | `local` | Tenant/organization whose topology to serve (alias: `--org`). |
373
+ | `--org <id>` | — | Alias for `--tenant`. |
191
374
  | `--no-semantic` | — | Disable semantic (vector) search. |
375
+ | `--plugins <list>` | — | Comma-separated scanner plugin package names to load (opt-in; or `CARTOGRAPHY_PLUGINS`). |
376
+ | `--server-mode` | off | Run as a central collector: enable the authenticated `POST /ingest` write route + org-wide summary (implies `--http`). |
377
+ | `--anon-mode <mode>` | `reject` | On ingest, `reject` \| `strip` un-anonymized identifying fragments (server-mode). |
378
+ | `--auth-required` | off | Reject unauthenticated requests even on loopback (RBAC required mode). |
379
+ | `--store-backend <kind>` | `sqlite` | Central store backend: `sqlite` \| `graph` (Neo4j/Memgraph, opt-in). |
380
+ | `--graph-url <url>` | — | Bolt URL for `--store-backend graph` (or `CARTOGRAPHY_GRAPH_URL`). |
381
+ | `--graph-user <user>` | — | Graph DB user (or `CARTOGRAPHY_GRAPH_USER`). |
382
+ | `--graph-password <pw>` | — | Graph DB password (or `CARTOGRAPHY_GRAPH_PASSWORD`). |
383
+
384
+ ### `api`
385
+
386
+ Run the read-only REST/GraphQL API server over the topology store.
387
+
388
+ `datasynx-cartography api [options]`
389
+
390
+ | Flag | Default | Purpose |
391
+ | --- | --- | --- |
392
+ | `--http` | on | Use HTTP transport (default; kept for symmetry with `mcp`). |
393
+ | `--port <n>` | `3737` | HTTP port. |
394
+ | `--host <h>` | `127.0.0.1` | HTTP host. |
395
+ | `--allowed-hosts <list>` | — | Comma-separated Host allowlist (required for non-loopback `--host`). |
396
+ | `--allowed-origins <list>` | same-origin | Comma-separated CORS Origin allowlist. |
397
+ | `--token <secret>` | — | Bearer token required on requests (or `CARTOGRAPHY_HTTP_TOKEN`); mandatory for non-loopback `--host`. |
398
+ | `--db <path>` | default catalog | DB path. |
399
+ | `--session <id>` | `latest` | Session to serve (id or `"latest"`). |
400
+ | `--tenant <id>` | `local` | Default tenant whose topology to serve (alias: `--org`). |
401
+ | `--org <id>` | — | Alias for `--tenant`. |
402
+ | `--no-graphql` | — | Disable the `/graphql` endpoint (REST only). |
403
+ | `--no-dashboard` | — | Disable the web dashboard at `/` and `/app`. |
404
+ | `--auth-required` | off | Reject unauthenticated requests even on loopback (RBAC required mode). |
405
+
406
+ ### `operator`
407
+
408
+ Run the Kubernetes operator: continuous in-cluster discovery + drift reporting.
409
+
410
+ `datasynx-cartography operator [options]`
411
+
412
+ | Flag | Default | Purpose |
413
+ | --- | --- | --- |
414
+ | `--config <file>` | — | JSON config file (drift sinks, db path). |
415
+ | `--interval <sec>` | `300` | Reconcile interval in seconds. |
416
+ | `--once` | off | Run a single reconcile and exit (CronJob-driver friendly). |
417
+ | `--db <path>` | config | DB path (overrides config). |
418
+
419
+ ---
420
+
421
+ ## Setup & maintenance
422
+
423
+ ### `auth`
424
+
425
+ Manage RBAC credentials for the HTTP surfaces (MCP transport + API server). Sub-commands:
426
+
427
+ | Sub-command | Purpose | Flags |
428
+ | --- | --- | --- |
429
+ | `auth add <subject>` | Create a credential and print its bearer token **once** (only the hash is stored). | `--role <role>` (`viewer`/`operator`/`admin`, default `viewer`), `--tenant <id>` (default `local`), `--token <secret>`, `--db <path>` |
430
+ | `auth list` | List credentials (subjects/roles/tenants — token hashes only, never the raw token). | `--db <path>` |
431
+ | `auth revoke <subject>` | Revoke all credentials for a subject. | `--db <path>` |
432
+
433
+ ### `install`
434
+
435
+ Register the Cartography MCP server into an AI host's config (parse-merge, never clobber).
436
+
437
+ `datasynx-cartography install --client <id> [options]`
438
+
439
+ | Flag | Default | Purpose |
440
+ | --- | --- | --- |
441
+ | `--client <id>` | **required** | Target host id (see `list-clients`). |
442
+ | `--global` | on (default) | Write the global/user config. |
443
+ | `--project` | off | Write the project-local config instead. |
444
+ | `--dry-run` | off | Show the merge diff without writing. |
445
+ | `--deeplink` | off | Print a one-click install deeplink instead of writing (Cursor / VS Code). |
446
+ | `--name <name>` | default server name | Server name to register. |
447
+ | `--http` | off | Register the Streamable HTTP endpoint instead of stdio. |
448
+ | `--url <url>` | — | HTTP endpoint (with `--http`). |
449
+ | `--db <path>` | — | Pass `--db <path>` to the server. |
450
+ | `--session <id>` | — | Pass `--session <id>` to the server. |
451
+
452
+ ### `list-clients`
453
+
454
+ List the AI hosts the installer can configure. No flags.
455
+
456
+ ### `doctor`
457
+
458
+ Check all requirements and cloud CLIs (kubectl, aws, gcloud, az). No flags.
459
+
460
+ ### `prune`
461
+
462
+ Delete old sessions and their data.
463
+
464
+ `datasynx-cartography prune [options]`
465
+
466
+ | Flag | Default | Purpose |
467
+ | --- | --- | --- |
468
+ | `--older-than <days>` | `30` | Delete sessions older than N days. |
469
+ | `--events-older-than <days>` | — | Compact the audit trail: delete activity events older than N days. |
470
+ | `--db <path>` | default catalog | DB path. |
471
+ | `--dry-run` | off | Show what would be deleted without deleting. |
192
472
 
193
473
 
194
474
  ---
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datasynx/agentic-ai-cartography",
3
- "version": "2.11.0",
3
+ "version": "2.12.1",
4
4
  "description": "MCP-first infrastructure & agentic-AI cartography — install once, every AI agent knows your system landscape. Read-only discovery exposed over the Model Context Protocol.",
5
5
  "type": "module",
6
6
  "sideEffects": false,
package/server.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
3
3
  "name": "io.github.datasynx/cartography",
4
4
  "description": "MCP-first read-only discovery of your infra & SaaS landscape as MCP resources, tools and prompts.",
5
- "version": "2.11.0",
5
+ "version": "2.12.1",
6
6
  "repository": {
7
7
  "url": "https://github.com/datasynx/agentic-ai-cartography",
8
8
  "source": "github"
@@ -12,7 +12,7 @@
12
12
  "registryType": "npm",
13
13
  "registryBaseUrl": "https://registry.npmjs.org",
14
14
  "identifier": "@datasynx/agentic-ai-cartography",
15
- "version": "2.11.0",
15
+ "version": "2.12.1",
16
16
  "runtimeHint": "npx",
17
17
  "transport": { "type": "stdio" },
18
18
  "runtimeArguments": [