PayPal + Formstack is a great way to collect payment from your customers online without the hassle of gateway fees, setup charges, or merchant accounts. Today, we're going to show you how to add PayPal to your Formstack order form, and generate a customer receipt using Formstack Documents. You could also use the steps outlined in this tutorial to send your customers coupons, special offers, or thank you letters.
For this receipt generator tutorial, you will need:
- Formstack Forms account
- Formstack Documents account
- PayPal account
- Customer order form template
- Customer receipt template with merge fields
5 Steps to Automated Receipt Generation
Step 1: Create your document.
We're going to start in your Formstack Documents account. Select "New Document." For this example, we're going to use a pre-built receipt template. Here's an example of a receipt template:

After setting up our document, we need to create an email delivery so our receipt sends directly to our customer when they complete their order form and payment. Navigate to the Delivery tab. You'll want to edit the email delivery that is there by default, and change the setting to the {$email} field you have on your receipt.

Now we're ready to jump into Formstack Forms to create our order form. Using our simple, drag-and-drop builder add the fields you'd like on your order form. Here's what our final example looks like:

Once your form has been built, head over to the "Settings" tab, and select "Integrations." Scroll down until you find the PayPal integration you need. Add your API/Secret Key, and map your unit price and quantity fields. Don't forget to add any additional charges or tax. Here's our final mapping:

Finally, we'll connect our form and our document. Navigate back to the integration tab, and select "Formstack Documents." Map your form fields to your document.

After completing our mappings, we're ready to test our automated receipt workflow. Fill out your form with demo information and make your documents are populating correcting and sending to your email. Congrats, you're finished!