# Start an n8n workflow from public link submissions

Run an n8n workflow when someone submits, edits or abandons a form through its share link, and pass the answers to the next node.

## Start an n8n workflow from public link submissions

This guide builds a two-node workflow: a new submission to a supplier onboarding form arrives in a formbase Trigger, and an Edit Fields node picks out the answers. Put your email, Sheets, Slack or CRM node after it.

<p>
  You need a <a href="/guides/n8n/connect">formbase credential in n8n</a> and a published form with a{' '}
  <a href="/sharing-publishing/sharing-embedding#share-links">share link</a>. Your n8n must be reachable from the internet over HTTPS; see{' '}
  <a href="/guides/n8n/install-the-node">Install the formbase node in n8n</a>. A submission to a request link does not start these
  workflows; see <a href="/guides/n8n/request-outcome">Act on a request's outcome in n8n</a> for that.
</p>

<h2 id="add-the-trigger">1. Add the trigger</h2>

<p>
  Create a workflow, click <strong>+</strong>, search for <strong>formbase</strong> and pick <strong>formbase Trigger</strong>. Choose the
  credential, the form, and one of the three public link events under <strong>Event</strong>:
</p>

Edit after submit</a> turned on for the form.',
      ],
    },
    {
      label: 'Public Link Submission Abandoned',
      cells: [
        'A respondent leaves the form unfinished for the time under <strong>Consider Abandoned After</strong> (12 hours to 1 week). formbase checks hourly, so the run can come up to an hour later.',
        'A Pro or Business plan, which saves <a href="/submissions-analytics/partial-submissions">partial submissions</a>.',
      ],
    },
  ]}
/>

<h2 id="listen-for-a-test-event">2. Listen for a test event</h2>

<p>
  Click <strong>Execute step</strong>. The node shows <em>Listening for test event</em>, and formbase starts sending this form's events to
  the node's test URL for two minutes. Open the form's share link in another tab and submit it within that time. The submission arrives in
  the node within seconds:
</p>

<p>
  n8n has no sample record: the test is a real submission, and <code>test</code> is <code>false</code>. Every answer appears twice:
</p>

<ul>
  <li>
    <strong>data.answers</strong> holds the value a workflow compares, under the question's <a href="/requests/field-keys">field key</a>: an
    option key like <code>yes</code>, a number, a date, or a list of files.
  </li>
  <li>
    <strong>data.display</strong> holds the text a person reads, like <code>Yes</code>.
  </li>
</ul>

<p>
  Use <strong>display</strong> in messages and <strong>answers</strong> in conditions. See the{' '}
  <a href="/developers/webhooks-reference#fields-vs-answers">webhooks reference</a> for both.
</p>

<p>
  Abandoned submissions arrive hours later, so <strong>Execute step</strong> cannot catch one. For that event, publish the workflow and
  check <strong>Executions</strong>.
</p>

<h2 id="map-the-fields">3. Pick out the answers</h2>

<p>
  Add an <strong>Edit Fields (Set)</strong> node after the trigger. Drag answers from the input panel into <strong>Fields to Set</strong>,
  or type the expressions yourself:
</p>

<p>
  The next node, say Gmail or Google Sheets, reads <code>{'{{ $json.company }}'}</code> and the other fields from here. When a question is
  renamed, its field key stays the same, so these expressions keep working.
</p>

<h2 id="publish-and-check">4. Publish and check a real run</h2>

<p>
  Click <strong>Publish</strong>, give the version a name, and confirm. formbase now sends every new submission to the workflow's production
  URL. Unpublishing the workflow stops that.
</p>

<p>
  Submit the form once more and open the <strong>Executions</strong> tab. The run appears within seconds. Runs you started with{' '}
  <strong>Execute step</strong> carry a flask icon; a production run has none:
</p>

<h2 id="troubleshooting">If the workflow does not start</h2>

<ul>
  <li>
    <strong>The form was submitted through a request link.</strong> That runs <strong>Request Completed</strong>, not Public Link Submission
    Created.
  </li>
  <li>
    <strong>The workflow is not published.</strong> Only <strong>Execute step</strong> listens while the workflow is a draft, and only until
    the first event arrives or two minutes pass.
  </li>
  <li>
    <strong>
      The trigger shows <em>targetUrl must use https</em>.
    </strong>{' '}
    Your n8n hands out an <code>http://</code> or private URL. See{' '}
    <a href="/guides/n8n/install-the-node#public-address">Tell n8n its public address</a>.
  </li>
  <li>
    <strong>The credential reaches another workspace.</strong> The trigger listens to the form in the workspace its credential points at.
  </li>
</ul>

> ℹ️ **Checking the signature**
> <p>
>     The formbase Trigger checks the <code>X-formbase-Signature</code> header of every event and rejects any that fails. Keep the n8n host's
>     clock accurate: an event signed more than five minutes earlier is rejected too.
>   </p>

<h2 id="next">Next</h2>

<div class="not-prose grid gap-3 sm:grid-cols-2 mb-8">
  - [Send a request from an n8n workflow](/guides/n8n/send-a-request)
  - [Native integrations](/integrations/overview) — Slack, Sheets and Notion without n8n.
</div>
