Add a feature to allow submitting a data modification request in "simulation" or "dry-run" mode without actually modifying data:
- Client sends request in the usual form, only difference is an additional "dry-run" header or query option
- Service processes the request
- Syntax check
- Semantic check (business rules are satisfied)
- Simulated request outcome (for 201 or 200 responses)
- Service does not perform the data modification
- Service responds in the usual form (response code, headers and body), only difference is an additional "was a dry-run" marker
Service announces dry-run capability via annotation on entity container or top-level resource.
Service may announce check level (1. is minimum, 2. and 3. are optional) in the annotation.
If response is an entity or collection of entities, mark them as transient.
Query option may be safer than a header because servers are strongly encouraged not to silently ignore unknown $xxx query options.