reorc-cli
v1.2.2
Published
CLI tool for ReOrc platform - Manage projects, models, pipelines, jobs, and data operations
Maintainers
Readme
reorc-cli
CLI tool for ReOrc platform.
Important: This CLI uses local YAML files as the source for data model and pipeline export, diff, and apply operations.
yqis recommended for editing, inspecting, and validating YAML, but is not required.
Installation
npm install -g reorc-cliQuick Start
reorc-cli config set
reorc-cli login --website <login-url>If you already have an access token, skip the browser flow by pairing it with the website whose API should verify it:
reorc-cli login --website https://xxx.reorc.cloud --token '<access-token>'--token also accepts a quoted Bearer <access-token> value. Be aware that
command-line arguments may be recorded in shell history or visible to other
local processes.
Select an account for a command
Available since 1.2.2. Use -p <profile_name> or --profile <profile_name> before the command to
select a saved login for this invocation. The default account is unchanged.
The profile is the tenant:username shown by reorc-cli config show, or a
username if it matches exactly one saved account. Unknown or ambiguous profiles
fail without making a request. Without this option, the current account is used.
reorc-cli -p acme:[email protected] projects list
reorc-cli --profile [email protected] projects use <project_id> data-models list
reorc-cli -p acme:[email protected] projects list --page 2Pagination uses --page <number> in both projects list and ops list.
The former pagination shorthand -p is no longer supported; -p selects a profile.
Browser Login
reorc-cli login opens a real Chrome window (isolated temporary profile) on the ReOrc login page. Complete the login there — MFA/SSO included — and the CLI automatically captures the resulting access token; the window then closes itself.
Requirements and fallbacks:
- Chrome, Chromium, or Edge must be installed (override the path with
REORC_CHROME_PATH). - Headless environments (CI, SSH without X11): run
reorc-cli login --no-browser(or setREORC_NO_BROWSER=1), log in on any machine, then open DevTools (F12) → Network → any/apirequest → copy theauthorizationrequest header value (with or without theBearerprefix) and paste it. - If the automatic flow fails, the CLI offers to retry or switch to manual paste.
Command Tree
reorc-cli
├── config Manage CLI configuration
│ ├── set Set config values (interactive)
│ ├── show Display current config
│ ├── clear Clear current account config and credentials
│ └── remove Remove a specific account
│
├── login Log in via browser, or use -w with -t to set a token directly
│
├── switch Switch between saved accounts
│
├── projects Manage projects
│ ├── list List projects (--page --page-size --search)
│ │
│ └── use <project_id> Enter project context
│ ├── data-models Manage data models and sources
│ │ ├── list List models (--search)
│ │ ├── create Create model (--name --materialization --content)
│ │ ├── manage Manage directories
│ │ │ ├── new-directory Create directory (--name --parent-id --listing-type)
│ │ │ └── move Move model (--model-id --directory-id)
│ │ └── use <model_id>
│ │ ├── export Export to local YAML
│ │ ├── diff Diff YAML against platform definition
│ │ ├── apply Apply YAML to platform
│ │ ├── build Placeholder; build the model manually on the platform
│ │ └── preview-data Preview model run data (--limit 10 --json --interval/--timeout in seconds)
│ │
│ ├── advanced-pipelines Manage advanced pipelines
│ │ ├── list List pipelines (--search)
│ │ ├── create Create pipeline (--name --directory-id)
│ │ ├── yaml-guide YAML authoring guide (--operator)
│ │ ├── manage Manage directories and move pipelines
│ │ │ ├── new-directory Create directory (--name --parent-id --listing-type)
│ │ │ └── move Move pipeline (--pipeline-id --directory-id)
│ │ └── use <pipeline_id>
│ │ ├── export Export to local YAML
│ │ ├── diff Diff YAML against platform definition
│ │ ├── apply Apply YAML to platform
│ │ └── get-jobs List scheduled jobs
│ │
│ ├── modeling-pipelines Manage modeling pipelines
│ │ ├── list List pipelines (--search)
│ │ ├── create Create pipeline (--name --models --directory-id)
│ │ ├── get <pipeline_id> View pipeline details
│ │ └── use <pipeline_id>
│ │ └── get-jobs List scheduled jobs
│ │
│ ├── connections Project connections
│ │ └── list List connections
│ │
│ ├── variables Project variables
│ │ ├── list List variables
│ │ └── get <name> View variable details
│ │
│ ├── macros Project macros
│ │ ├── list List macros (--search --status)
│ │ └── get <id> View macro details
│ │
│ └── export-all Clear cache and re-download all models and pipelines
│
├── global-connections Manage global connections
│ ├── list List connections
│ └── use <connection_id> Enter connection context
│ ├── query [sql] Execute read-only SQL (-d --database --env --limit)
│ ├── list-databases List databases (--env --refresh)
│ ├── list-tables List tables (--database --env --refresh)
│ └── get-table-schema <table> Get table schema (--database --env --refresh)
│
├── ops Data Ops - Monitoring
│ ├── overview Pipeline health overview (--env --range)
│ ├── list List pipelines with job status
│ └── jobs <pipeline_id> View pipeline job details and run history
│
├── environments Environments and workers
│ ├── list List environments (with workers)
│ └── workers List worker details (--env --status)
│
└── install-skill Install skill to .claude/skills and .agents/skills (--lang en|cn)Default YAML Paths
export, diff, and apply use the default local YAML path:
- Advanced pipelines:
./reorc/project_<project_id>/advanced-pipelines/<directory>/<name>.yaml - Source models:
./reorc/project_<project_id>/data-models/sources/<directory>/<name>.yaml - Data models:
./reorc/project_<project_id>/data-models/models/<directory>/<name>.yaml
Names and directory segments are normalized into file-system-safe paths.
Project Variables
Reference variables in Python/SQL code using {{ var("variable_name") }}.
Recommended model workflow: edit the exported local YAML, run diff, run apply, then run preview-data to verify the platform model output.
build is a placeholder command only. It does not build the model; model builds must be performed manually on the ReOrc platform.
Project Macros
List active macros with projects use <id> macros list. Use --search <keyword> to filter by keyword, --status <status> to select a status (default: active), and --json for structured output. View a macro with projects use <id> macros get <macro_id>.
Development
npm run build
npm start