Safe writes
Writes are off by default. Four checks run before a request leaves your machine, and a refused write costs no API call at all.
- Validation. The body is checked against the catalogue: method allowed, mandatory fields present, no unknown field, no read-only field on an update. Exit 64 otherwise.
- The write gate.
--allow-writes(orEXACTCLI_ALLOW_WRITES=1in the shell), and--yesfor a delete. Exit 77 otherwise. - The division guard. A read-only profile refuses every write;
write_divisionslimits writes to a list of divisions, also for rawapicalls and MCP tools. - Sent once. A POST or a DELETE is never repeated after a network failure or a 5xx: the write may have landed, so exactcli exits 69 and says so.
Preview
Section titled “Preview”--dry-run prints the validated request and sends nothing. It needs no flag, so an
agent can preview a write.
exactcli create crm/Accounts --set Name=Acme --set Code=1001 --dry-runexactcli create crm/Accounts --set Name=Acme --set Code=1001 --allow-writesexactcli update crm/Accounts <id> --set Name="Acme NV" --allow-writesexactcli delete crm/Accounts <id> --allow-writes --yesField values
Section titled “Field values”--set Key=value is repeatable and merges over --body (a JSON string, @file or
piped stdin). Values: text, numbers, true, false, null; @str:1001 pins a string;
@guid:<id> pins a GUID; @ref:crm/Accounts:1001 resolves a code to the GUID of that
record.
Create or update by key
Section titled “Create or update by key”exactcli upsert crm/Accounts --match Code=1001 --set Name="Acme NV" --allow-writesupsert creates the record that --match finds nothing for, or updates the one it
finds; the match fields stay out of the update. Several matches exit 65.
Aliases that write
Section titled “Aliases that write”An alias that stores --allow-writes or --yes writes without them on the command
line, and alias set warns about it. The profile guards still apply.