Magic HTML & JSON Directives
Control email subjects, Reply-To headers, CC recipients, custom redirects, and honeypot traps directly from your HTML inputs or JSON payload.
Built-In Underscore Directives#
EntryWise recognizes special underscore-prefixed fields in both multipart/urlencoded HTML forms and application/json payloads. These directives configure email routing and response behavior per submission without exposing sensitive credentials in client code.
| Directive | Example Value | Behavior |
|---|---|---|
| _gotcha / _honeypot | "" (empty) | Invisible bot trap. If populated by an automated scraper, EntryWise returns a fake 200 OK and silently drops the payload. |
| _subject | "New Enterprise Lead: Acme" | Overrides the notification email subject line for this specific submission. |
| _replyto / email | "alex@acme.com" | Sets the Reply-To header on the team notification email so you can reply directly from your email client. |
| _cc | "sales@acme.com,ops@acme.com" | Comma-separated list of up to 5 email addresses to CC on the notification email. |
| _redirect / _next | "https://acme.com/thanks" | Redirects browser form submissions (302 Found) to your custom thank-you URL. |
Internal directives (_gotcha, _redirect, cf-turnstile-response) are stripped before storing your submission in SQLite or syncing to Google Sheets/Airtable/Notion so your database stays clean.
Sandbox & Mock Testing (?mock=true)#
Want to test your frontend form validation, Turnstile widget, and API key configuration during local development or CI without polluting your production database or burning email quota?
Append ?mock=true to your submission URL or send the X-EntryWise-Mock: true header. EntryWise executes the full validation and configuration preflight check (verifying whether your email provider key and connectors are properly configured) and returns a detailed diagnostic payload without writing to the database.
curl -X POST "https://api.entrywise.si/f/ew_live_your_form_key?mock=true" \
-H "Content-Type: application/json" \
-d '{"name": "Test User", "email": "test@example.com"}'