Receipt Generation

Prev Next

Forms submissions will often require a simple human-readable ID to allow users to easily reference their form submissions. The Receipt Generation function allows you to create custom Receipt IDs for your form submission process.

There are two ways to create a Receipt ID, one is generating it using the built-in Receipt ID feature, and the second is using an API.

Create a Custom Receipt ID

By default, the receipt will be an 8-character random string created from numbers and uppercase letters. You are able to customize this Receipt ID by adding additional components. Components come in four types: Text, Date, Random, and Sequential Numbers. You can choose to add any number of these to your Receipt ID. The exception is Sequential Numbers which you can only have 1 of in any Receipt ID.

Important Note

If you want to guarantee that the Receipt IDs being generated are unique to each submission you will need to include a Sequential Number component.

Create a Custom Receipt ID Instructions

  1. Sign in to your site

  2. Navigate to the Forms tab and select the applicable form or create a new form The Forms tab in the left navigation menu with a form selected on the page.

  3. Navigate to the Developer Tools tab

  4. Scroll down to the Receipt Generation section and choose Receipt IDReceipt ID configuration section.

  5. Select the component to edit Receipt generation configuration with custom identifier and API endpoint options displayed.

  6. Configure the Receipt Component type as needed

    • Text: Generates a piece of text that is displayed on every receipt. This can be used to add prefixes or separate the different sections of the Receipt ID by using a dash (-). Editing receipt component options including text, date, random, and sequential number types.

    • Date: Generates a specific chosen type of date in the Receipt. These can be used to create a specific date format for your users and allows you to know when the submission was completed by looking at the date section of the Receipt ID. Editing receipt component options for text, date, random, and sequential number types.

      • Day: The day of the month. For example, 01 or 25.

      • Month: The numerical month of the year. For example, 01 or 12.

      • Year (2 digit): The two-digit representation of the year. For example, 97 or 03.

      • Year (4 digit): The four-digit representation of the year. For example, 1997 or 2003.

    • Random: Adds randomly generated text and or numbers to Receipts. Choose the number of characters and then what character sets to include. To avoid confusion for users we remove similar appearing characters in the generated Receipt ID (i, I, l, L, o, O, 0). Settings for editing receipt components, including type and character options.

    • Sequential Number: Generates a sequential number for every submission. You can enter a starting number to begin the sequence at a higher number. Once the form is submitted a starting number cannot be added or modified. Editing receipt component options including text, date, random, and sequential number types.

  7. Click OkThe Ok button on the edit receipt ID screen.

  8. Select Add New Component to add additional components, as needed Configure custom receipt identifier settings and add new components for submission management.

  9. We recommend adding a dash between the components. You can do this by adding a Text component with a -A dash in the receipt text field.

  10. If needed, drag and drop the components into the desired order Drag and drop receipt components.

  11. View an example of what your receipt ID will look like Configuration options for custom receipt identifier with example format displayed below.

  12. Scroll up and click Save

  13. Learn how to Display the Receipt ID to Users


Use a Custom URL/Hosted API

If you need to generate a receipt ID that cannot be catered for using the out-of-the-box Receipt ID functionality, then you will need to add a custom URL or a hosted API endpoint. This endpoint will be called on a form submission and allow you to generate an external ID.

Examples

Following is an example of the request payload:

{ formsAppId: numberformId: numberexternalIdUrlSearchParam: string | nulldraftId: string | nullpreFillFormDataId: string | nulljobId: string | nullpreviousFormSubmissionApprovalId: string | null}

Below is an example of the response payload:

{ externalId?: string }

The External ID is required in the response payload if the externalIdUrlSearchParam is provided in the request payload.

Use a Custom URL/Hosted API Instructions

  1. Sign in to your site

  2. Navigate to the Forms tab and select the applicable form or create a new form The Forms tab in the left navigation menu with a form selected on the page.

  3. Navigate to the Developer Tools tab

  4. Scroll down to the Receipt Generation section and choose Custom URL or Hosted APIReceipt generation options including Custom URL and Hosted API settings highlighted.

    • Custom URL: Enter the URL address for an API endpoint Custom URL configuration for receipt generation with highlighted input field.

    • Hosted API: Select a Hosted API you have created and a Route from the drop-downs Configuration options for receipt generation, including Hosted API and Route fields.

  5. Scroll up and click Save


Display the Receipt ID to Users

You can display the receipt ID using a custom submission message or by redirecting to a receipt page.

Submission Message

In order to display the Receipt Id to your users you can add it in the successful submission message. Follow the instructions to Customize the Form Submission Message and include the {EXTERNAL_ID} in the message to allow users to see their Receipt ID once they complete the form.

The Customize the success message toggle enabled with an external id added in the text.

Create a Receipt Page

If you instead want to redirect the user to another form and display the Receipt Id there, you do so using the pre-fill and redirect URL functionality. Create your receipt page and add the URL of your Receipt page as a Redirect URL to your form.

The Redirect to URL option on the navigation section of the form.

Add the following text to the end of the redirect URL. Be sure to add the name of the element you want to pre-fill with the external ID. This will ensure that an element on your Receipt page is populated with the Receipt ID.

?preFillData={"name of your element":"{EXTERNAL_ID}"}