ubx validate runs the full compiler pipeline without generating TypeScript or deploying. Fast — no cloud credentials required.
Usage
Examples
Flags
| Flag | Description |
|---|---|
--compile | Also run tsc --noEmit on generated TypeScript |
--cost | Check cost_limit attributes against AI cost estimates |
--env string | Target environment |
--stack string | Target stack name |
Output
Success:What Gets Validated
- Syntax — valid
.iacblock structure - Required fields — all required provider attributes present
- Unknown fields — warn on attributes not in schema
- References — all
~unit.x.y.z,local.name,input.namerefs exist - Circular dependencies — detected and reported
- Policy blocks — all
policyrules evaluated cost_limit— validated with AI when--costis set
--compile Flag
Runs tsc --noEmit after schema validation. Requires Node.js.
Exit Codes
| Code | Meaning |
|---|---|
0 | Valid (warnings don’t fail) |
1 | One or more errors |
