FormLoom

Cline contact form

Ask Cline to add a contact form wired to FormLoom — one prompt, and you get working code with a provisioned key.

The prompt

Add a support ticket form with a file upload using FormLoom.

The generated code

ContactForm.tsx
// ContactForm.tsx — React (works in Vite, CRA, Next 'use client')
"use client";
import { useState } from "react";

export function ContactForm() {
  const [status, setStatus] = useState<"idle" | "ok" | "error">("idle");

  async function onSubmit(e: React.FormEvent<HTMLFormElement>) {
    e.preventDefault();
    const form = e.currentTarget;
    const res = await fetch("https://formloom.vercel.app/api/submit/fl_provisioned_key", {
      method: "POST",
      headers: { "Content-Type": "application/json", Accept: "application/json" },
      body: JSON.stringify(Object.fromEntries(new FormData(form))),
    });
    setStatus((await res.json()).success ? "ok" : "error");
    if (status !== "error") form.reset();
  }

  if (status === "ok") return <p>Thanks — we got your message.</p>;
  return (
    <form onSubmit={onSubmit}>
      <label>
        Name
        <input type="text" name="name" required />
      </label>
      <label>
        Email
        <input type="email" name="email" required />
      </label>
      <label>
        Message
        <textarea name="message" required placeholder="How can we help?"></textarea>
      </label>
      <!-- honeypot: bots fill this, humans don't see it -->
      <input type="checkbox" name="botcheck" style="display:none" tabindex="-1" autocomplete="off" />
      <button type="submit">Send</button>
    </form>
  );
}

FAQ

Yes — add the FormLoom server in Cline's MCP settings and it can call `get_snippet` and `provision_endpoint`.
Cline contact form — generate one with FormLoom · FormLoom