Skip to content

You are currently viewing documentation for0.1.0-alpha.3

Saved documentation for 0.1.0-alpha.3 (npm) / 0.1.0a2 (PyPI). Interactive tools use the current release. View latest documentation.

AGINDOW CLI & Offline Reports

Install and run

Inspect supported integration definitions and generate offline reports without executing your application. The CLI ships with the Node SDK, not as a separate Python tool. Use Node 22+ and install the selected version with npm install agindow@0.1.0-alpha.3. The installed binary is agindow; from that project directory run the command below. . means the current directory. Report reads supported JS/TS source recursively, but does not import/execute the project, write project files or contact providers. Installation itself may use the network.

sh
npx --no-install agindow report .

Generate your first report

1. Open your supported JS/TS project. For a reproducible exercise, use a clean directory and save the fixture below as tools.ts; it need not be executed or have LangChain installed. 2. Run npx --no-install agindow report . after installing the CLI there. 3. Read the text on stdout. There is no default report file. To save it yourself, use npx --no-install agindow report . > agindow-report.txt. Shell redirection writes that file. 4. Review discovered tools and skipped files, then collect scoped runtime evidence before drawing conclusions about drift.

ts
import { tool } from '@langchain/core/tools';
export const lookup = tool(async () => ({ id: 'customer-123' }),
  { name: 'crm.read', description: 'Read a customer' });

Understand report output

This is the actual output for that fixture, with the decorative CLI brand banner omitted. Tool counts and wrapper detection are static inventory hints. Vendors lists recognized imports/URLs near supported definitions; zero does not prove no vendor usage. No registry snapshot means no supplied drift evidence. A shape repair candidate from historical events remains execution unverified; a recorded sandbox verdict describes only that fixture.

text
Tools detected: 1
Already wrapped: 0
Vendors: 0 ()
Skipped files: 0
No registry snapshot; drift evidence unavailable.
  crm.read → evidence unavailable
FieldHow to use it
Tools detected / Already wrappedInspect recognized definitions and wrappers; dynamic shapes may be absent.
VendorsKnown supported vendor references, not an exhaustive integration inventory.
Skipped filesInspect unsupported syntax, unreadable/oversized files, symlinks or bounds. Coverage is incomplete.
Evidence unavailableSupply a valid local snapshot if you have one; do not interpret this as no drift.
Known drift / recorded local sandbox fixtureHistorical or simulated evidence matched by tool name; not live confirmation or repair permission.

Use the CLI in development and CI

Run report when reviewing a new integration or before merging, and archive the stdout diagnostic alongside human review. report has no --json, --strict or --fail-on-findings option. A completed report exits 0 even with missing/invalid snapshot evidence, skipped files or warnings; even an unreadable scan directory can yield a successful report with skipped files. Usage errors and uncaught failures exit 1. Do not use exit 0 as a CI protection or completeness gate. There is no reliable report findings-failure contract to demonstrate in GitHub Actions. rotation-readiness has its own explicit JSON and verifiability gate below; those flags do not apply to report.

Reporting versus simulation, scan and codegen

Choose by the evidence you have and the side effects you intend. None of these operations proves production write integrity or deployed repair.

OperationInterface and effects
reportCLI; reads bounded local sources and optional snapshot; writes text to stdout.
sdk.simulate(tool, input)Node SDK API; evaluates supplied recordings without calling upstream. Await sdk.ready. No CLI simulate subcommand and no Python equivalent.
scan --snapshotCLI; potentially mutating. Inserts/updates generated guards in supported Nango actions/syncs; review the diff in version control.
codegenCLI; reads a local contract bundle and emits TypeScript to stdout. Redirection may create a file. Does not patch the project itself.

CLI command reference

Commands below describe the selected SDK version. The prepared release notice at the top of this page applies: the additional source-fix commands belong to the prepared Node release and are absent from the last published alpha.2 CLI. Arguments shown are required unless bracketed. No universal --help/--version or output-format flag is implemented. Invalid invocation exits 1; diagnostics go to stderr. report may also print a brand banner before its text.

report command

Syntax: agindow report <directory> [--snapshot <local-file.json>]. Example: npx --no-install agindow report . --snapshot ./evidence.json. Prints inventory/evidence text; exit 0 after reporting, including invalid snapshot warnings. Read-only except caller shell redirection. Snapshot schema is {version: 1, window: {start, end}, events: [...], recordings?: [...]}; ISO timestamps must be ordered and include all events. Events use the frozen drift-event schema and unique IDs. A recording supplies tool, contract, args and recorded; contract.tool must match tool. Limits: snapshot 1 MiB, 10000 events, 256 recordings. Invalid snapshots produce “Invalid registry snapshot; drift evidence unavailable.” and do not fail the command.

codegen command

Syntax: agindow codegen <local-contracts.json>. Example: npx --no-install agindow codegen ./contracts.json > generated.ts. Emits sandbox evaluator TypeScript to stdout; the shell writes generated.ts. Input is {version: 1, contracts: [...]}, at most 1 MiB / 256 contracts, one contract per file. Each bounded contract specifies version: 1, id, file, tool, endpoint, method, mode and operation, with optional request/response field rules and disabled. File must be a relative actions/*.ts or syncs/*.ts path. Supported methods: get, post, put, patch, delete, request. Each encoded contract is at most 2048 bytes; each request/response has at most 64 field definitions. Field types are string, number, boolean or null, with optional required and string enum (up to 64 values). Request-only renames supply from, to, identity and confidence; up to 32 reviewed sibling rules. AGINDOW_DISABLED=true forces disabled generation; no runtime refresh is provisioned. Exit 0 on emission, 1 on invalid input/usage. Generated output is not evidence that your deployed integration was exercised.

scan command

Syntax: agindow scan <directory> --snapshot <local-contracts.json>. Example: npx --no-install agindow scan . --snapshot ./contracts.json. Uses the codegen bundle schema above, not the report snapshot schema. Potentially mutating: reads and replaces supported Nango source files with generated guards through temporary files and rename. Prints Changed files and Skipped files. Exit 0 when skipped is zero; exit 1 for skipped/unsupported files, invalid usage or failure. Earlier files may already be changed when a later file is skipped. Review all diffs; failure is not rollback. Symlink/escaping/oversized paths and changed source are refused. No general-purpose project rewrite or automatic repair discovery.

rotation-readiness command

Syntax: agindow rotation-readiness <events.ndjson> <facts.ndjson> --as-of <UTC> [--json] [--require=verifiable]. Example: npx --no-install agindow rotation-readiness ./events.ndjson ./facts.ndjson --as-of 2026-10-29T12:00:00Z --json --require=verifiable. Reads local event and capability-fact streams, prints a table or agindow.rotation-readiness/1 JSON. It does not rotate credentials or contact providers. Facts must use the typed tenant/connection/provider/capability evidence format, not arbitrary settings. Exit 0 after valid reporting; --require=verifiable exits 1 for an empty report or any row other than verifiable. Invalid inputs/flags exit 1. Evidence expires according to the report clock; it does not establish durable replay.

Local source-fix export

These prepared-release commands read local requests and explicitly admitted committed JS/TS source. Inventory hints do not authorize edits. Exports remain unvalidated until an independent runner verifies the exact candidate. They emit JSON to stdout, do not apply a patch or open a pull request. Scope, source digests, separate generation consent and independently reviewed migration evidence are required. Keep artifacts private to the authorized repository; validate the exact candidate independently before considering publication.

Command and exampleOutput / exit behavior
agindow bind-source ./binding-request.jsonLocal request {grant, selection}; bound manifest JSON, exit 0 when bound; abstention exit 1. Request cap 1 MiB.
agindow resolve-source ./resolve-request.jsonLocal request {grant, manifest}; re-resolves against committed source. Bound JSON exit 0; stale/unsafe/unsupported abstention exit 1.
agindow generate-source-patch ./patch-request.json --as-of 2026-10-29T12:00:00ZAdmitted single-token rename artifact JSON; refusal exit 1, otherwise 0. Local JSON request cap 64 KiB; explicit UTC evaluation clock.
agindow export-source-fix ./export-request.json --as-of 2026-10-29T12:00:00ZEvidence-backed local artifact JSON; refusal exit 1, otherwise 0. Request cap 64 KiB; local references resolved relative to request, each up to 32 KiB.

Limitations and troubleshooting

Missing binary: install the selected Node package in your current project; npx --no-install intentionally refuses downloading a missing CLI. Unexpected empty inventory: the scanner recognizes static tool definitions, imported LangChain tool factories, supported Nango builders and known vendor references, not every HTTP call or arbitrary application structure. Python files are not scanned. Readable JS/TS extensions include .js, .jsx, .ts, .tsx and c/m variants; dependency/build directories are excluded. Scan bounds are 10000 files, 1 MiB per file and depth 64; symlinks are skipped. Missing evidence: report without a snapshot cannot establish runtime drift; fix invalid windows, duplicate IDs or malformed recordings. Unexpected stdout: the brand banner and warning lines are text, not JSON. Generation failure: check supported Nango forms and local contracts, then inspect diffs before retrying scan. A report is not write-integrity proof. Missing evidence remains unavailable, not clean; offline reports do not establish production calibration, streaming coverage, durable replay or hosted readiness.