CLI

generate, validate, dry runs and diffs. The generator reports what it wrote, what it skipped and what it refused.

The binary is vendor/bin/poagen.

generate

poagen generate path/to/poagen.php

Reads the profile, parses the document, and rewrites the output directory. The output is owned by poagen: files from a previous run that the current document no longer produces are removed.

FlagEffect
--dry-runReport what would be written and deleted, write nothing.
--diffPrint a unified diff against disk and write nothing.
--diff=Generated/Model/**Scope the diff to a subtree.
--color=alwaysForce colour even when piped.
--output=/tmp/outOverride the profile's output directory.

validate

poagen validate path/to/schema.yaml

Parses and validates the document without generating. A JSON document is read as JSON by its .json extension; anything else is read as YAML. The same rule applies to Profile::$schema, so a .json document generates the same client its .yaml equivalent would.

The run report

Every run reports:

A refusal exits non-zero. Nothing is written when the profile or the document fails validation, so a broken profile cannot leave a half-generated tree.

Skip or fix

A construct poagen refuses is a decision point, not a warning to scroll past. Either:

There is no silent fallback. See Status for the constructs that stop a run.