op: reject
Abort the intent with a typed error code.
Allowed phases
| Phase | Status |
|---|---|
preflight | ✓ allowed |
core | ✗ forbidden |
side_effects | ✗ forbidden |
Syntax
- op: reject
code: TICKET_LIMIT_EXCEEDED
message: "You can only purchase 4 tickets per show"Parameters
| Field | Required | Description |
|---|---|---|
code | yes | SCREAMING_SNAKE_CASE code returned to the client |
message | no | Human-readable rejection message |
Behavior
- Preflight only. When
rejectruns, core and side_effects never execute. - Compiler error
VERR_PREFLIGHT_SIDE_EFFECTifrejectappears outside preflight.
Related operations
See also
- Operations index — all ops by phase
- actions — rule structure and phases
- Intents: Rules — narrative examples