1. Template Guidelines
  2. Public Forms

Template Guidelines

Public Forms

Explains how to expose an action as a public web form for collecting many data points and rich fields.

Sometimes a process needs to collect data from the public, or from a specific person, as part of a stub's process. You can expose an action as a public form. This gives it a unique URL anyone can use to submit data to the stub without signing in.

Enable it in the action's action_meta:

        {
  "public_form": {
    "enable": true,
    "publicformlayoutuuid": "fa100e93-a2c5-4707-ba24-7ee4e2d77847",
    "public_form_variables": {
      "title": "Form {{stub.stubref}}"
    }
  }
}

      

See Public Forms action meta for the settings and layouts for designing the form.

Features

  • A customizable look and feel, with your own branding in HTML and CSS.
  • Every field type in the platform is supported, so you can collect a wide variety of data, such as maps, file uploads and signatures.
  • The form expires automatically when the action is no longer available on the stub, so it is only active while it can be submitted.
  • A submission runs the action on the stub as if the data had been submitted in the platform, so you can use everything actions and tasks can do.

Use cases

  • Collecting many data points from a chat. When an AI agent needs a lot of information from a user, it can send them a link to a public form. They submit the data and then continue the conversation or process.
  • Starting a process. Expose an action on the _create context as a public form, so anyone can submit it to create a new stub and kick off a process without signing in. Set action_meta.clear_action_data to true on that action.

How it works

  • The action's fields become the form's fields.
  • When the action is available on a stub and set as a public form, the form is available at https://forms.stubber.com/[stubref]/[action_name].
  • Submitting the form runs the action on the stub, with the submitted data as input.
  • Public form variables are interpolated and available in the layout's HTML as public_form_variables.[var], so you can inject dynamic data into the form.
  • You can create a public form layout in the platform, or reuse an existing one, and refer to it with publicformlayoutuuid.

The components library has examples of public form actions combined with AI-enabled actions, so an agent can prefill some fields before sending the user a link to complete the rest. See also the Generate and Prefill a Public Form technique.

Designing layouts with Flowpilot

Flowpilot has a form design agent that can customize public form layouts for you. You can:

  • give it detailed instructions on what to change
  • give it a website to use as design inspiration for colors and logos, for example Design a form to follow the look and feel of www.stubber.com; it browses the site and extracts the styling itself
  • ask it to publish the layout so you can check the changes, or to publish straight away after designing it

You can view and edit a layout at:

https://editor.stubber.com/[org domain]/public-form-layouts/[public form uuid]