Quickstart

  1. 1. Create a form in the dashboard.
  2. 2. Replace {public_slug} with your form slug.
  3. 3. Paste the snippet into any HTML page.

No-JS HTML form

<form action="https://api.formplume.com/f/{public_slug}" method="POST">
  <label>
    Email
    <input type="email" name="email" required>
  </label>

  <label>
    Message
    <textarea name="message" required></textarea>
  </label>

  <input type="text" name="_gotcha" tabindex="-1" autocomplete="off"
         style="position:absolute;left:-9999px">
  <input type="hidden" name="_redirect" value="https://yoursite.com/thanks">

  <button type="submit">Send</button>
</form>

Fresh time-trap token

<input type="hidden" name="_fp_ts" data-formplume-time-trap>
<script>
  fetch("https://api.formplume.com/f/{public_slug}/time-trap")
    .then((response) => response.json())
    .then(({ token }) => {
      document.querySelector("[data-formplume-time-trap]").value = token
    })
</script>

JSON/AJAX submit

fetch("https://api.formplume.com/f/{public_slug}", {
  method: "POST",
  headers: { "Content-Type": "application/json", "Accept": "application/json" },
  body: JSON.stringify({
    email: "lead@example.com",
    message: "Hello from my site"
  })
})

Multipart form

<form action="https://api.formplume.com/f/{public_slug}" method="POST" enctype="multipart/form-data">
  <input type="email" name="email" required>
  <input type="file" name="attachment">
  <button type="submit">Send</button>
</form>