Skip to Content
CLI

CLI

Install the binary (dev dependency is typical):

pnpm add -D @cyphra/cli

App code usually depends on cyphra (library stack) separately — see home / Install.

CommandDescription
cyphra initScaffold config, schema, migrations, env example
cyphra validateParse and validate schema.cyphra
cyphra schema printCanonical pretty-print of the schema to stdout
cyphra schema ddlPrint cyphra push DDL (constraints + indexes); no DB
cyphra generateEmit cyphra.gen.ts (labels & relationship types)
cyphra migrate deployRun pending migrations
cyphra migrate devSame with verbose logging
cyphra migration:create <name>New .mjs migration
cyphra pushApply constraints + @index range indexes (Neo4j 5+)

cyphra.json may set schema, migrations, and optional generate (output path; default ./cyphra.gen.ts).

validate, generate, schema print, and schema ddl only need the schema file (and cyphra.json). migrate and push require NEO4J_URI, NEO4J_USER, and NEO4J_PASSWORD.

Last updated on