Skip to main content

Control Block Reference

Detailed reference for all Control Block types and their options.
In the current runtime, controls live inside a v0.3 Virtual API Configuration under objects.<objectName>.controls. This page documents the control entries themselves.

Common Execution Rules

Common Options

Data Control

redact

Remove sensitive data entirely. Behavior:
  • Strings → ""
  • Numbers → 0
  • Booleans → false
  • Objects and arrays are invalid targets
  • The key remains in the output. If you want to remove the field entirely, use delete instead.

tokenize

Replace with deterministic tokens. Behavior:
  • Same input → same token within the same Virtual API and matched object definition
  • Different object definitions or different Virtual APIs → different tokens
  • Token format: tok_[hash]
  • Booleans are not supported

anonymize

Replace with random values preserving structure. Behavior:
  • Each request produces different values
  • Format is preserved (email looks like email)
  • Not reversible, not correlatable

mask

Partially redact values while preserving structure. Behavior:
  • Strings → first and last characters visible, middle masked (e.g., "John Smith""Jo** ***th")
  • Numbers → leading digits zeroed, last 2 visible (e.g., 55512345670000000067)
  • Booleans → false

hash

Replace with one-way SHA-256 digest. Deterministic within the same Virtual API and matched object definition — same input always produces the same hash in the same scope. Behavior:
  • Strings → 64-character hex digest
  • Numbers → deterministic number derived from hash bytes
  • Booleans → deterministic boolean

allow

Pass values through unchanged. Fields not referenced by any control are allowed by default — allow is provided for users who prefer to be explicit about which fields are permitted.

Data Transform

combine

Merge fields into a new field. All source fields must be strings. When you use nested paths, every entry in fields plus into must share the same parent path. If into already exists, the transform fails instead of overwriting it.

coalesce

Select first non-empty value. coalesce treats missing values, null, and empty strings as empty. Whitespace-only strings, numeric 0, boolean false, objects, and arrays are all treated as present values. When you use nested paths, every entry in fields plus into must share the same parent path. If into already exists, the transform fails instead of overwriting it.

delete

Remove fields entirely from the outbound payload. delete does not support into. When you use nested paths, all entries in fields must share the same parent path. This keeps cleanup operations predictable for nested objects and arrays.

Access Control

Access controls are defined in the access block, not as Control Blocks.

expires


geo_allow / geo_deny


ip_allow


rate_limit


Field path syntax

Simple fields

Nested fields

Array items