Forms API
HTML Embed

HTML Embed

For Squarespace, Wix, WordPress, Webflow, or any static HTML site.

This method uses a native browser form submission (<form method="post">). The browser handles the POST request directly, the honeypot is processed automatically, and the user is redirected to your configured success URL upon completion.

Setup

  1. Configure your form's Allowed Domains and Success Redirect URL in the Gordon CRM dashboard.
  2. Copy the HTML snippet below (or generate your custom snippet from the form detail page).
  3. Paste it into an "HTML," "Code," or "Embed" block on your website builder.
  4. Update the <input> types and CSS classes to match your brand's styling.

Code Snippet

<form method="post" action="https://app.gordoncrm.com/api/forms/YOUR_FORM_ID">
  <input type="email" name="email" placeholder="Email Address" required />
  <input type="text" name="first_name" placeholder="First Name" />
  <input type="text" name="last_name" placeholder="Last Name" />
 
  <!-- Honeypot — hidden from real users, caught by bots -->
  <div style="position:absolute;left:-9999px" aria-hidden="true">
    <input type="text" name="website_url" tabindex="-1" autocomplete="off" />
  </div>
 
  <button type="submit">Submit</button>
</form>

How It Works

  1. The browser sends a native POST request to the forms API endpoint.
  2. Authentication is handled via the Origin header, which is validated against the form's allowed domains.
  3. After successful processing, the API returns a 302 Redirect to your configured success URL. If no success URL is configured, the browser receives a JSON response instead.

Honeypot Field

The hidden website_url div is a spam honeypot. Real users never see it, but automated bots will fill it out. If the API receives data in this field, the submission is silently dropped (returning 200 to fool the bot).

Do not remove this <div>. Without it, your form will be exposed to automated spam submissions. See the Honeypot documentation for details.

Optional Fields

You can add any of the supported submission fields as additional inputs. For example, to collect phone numbers and marketing consent:

<input type="tel" name="phone" placeholder="Phone Number" />
 
<label>
  <input type="checkbox" name="is_subscribed" value="on" />
  Subscribe to our newsletter
</label>
 
<textarea name="notes" placeholder="How can we help?"></textarea>