When integrating a contact form or booking page in your app, platform or website, you can add data in the URL to prefill some answers of questions and improve the customer experience.
Adding the data to the URL is pretty easy and can be done via a URL parameter. As the contact forms and booking pages consist of several types of questions, you will need to have a good look at which data to add for which type of question.
The prefill functionality works for all question types of contact forms. For booking pages however, prefilling isn't functional yet for all question types. This will be updated soon!
In this help article
Adding data via a URL parameter
Here we'll take a contact form as an example, but know you can do the same for your booking pages.
Basically all you have to do is add a parameter with information to the contact form URL to prefill questions.
A contact form URL looks like this:
- Vectera domain: https://vectera.com/form/<teamname>/<formname>/
- Custom domain: https://something.mydomain.com/form/<formname>/
You can add a parameter by adding ?questions.<id>=<value>.
Add a second question by adding &questions.<id>=<value>.
So a contact form with 2 filled in questions will look like this:
You can copy the question ID of a contact form question by following these steps:
- Go to https://www.vectera.com/contact-forms/
- Click on the pencil icon next to the contact form that you want to prefill
- Click on the 3 dots next to the question that you want to prefill
- Click on Copy question id
The answers to most of the question types are pretty straightforward, you just type in the value.
A few examples:
- Single line: questions.<id>=simon
- Email address: questions.<id>=email@example.com
- VAT number: questions.<id>=BE0123456789
Some question types require a specific type of answer value. These are the values to set:
|Single selection||The label of the option. If the question has an "other option, you just have to type the word.||Option1|
|Multi selection||A comma separated list of options. If the question has an "other" option, one of the values can be a random word.||Option 1,Option 2,randomword|
*see note 1
|Yes/No||0 (=no) or 1 (=yes)||0|
|Address||A comma separated list with 5 values: street, number, postal code, city, country**||Dok-Noord,3A/101,9000,Gent,Belgium|
*Note 1: for single and multi select questions the answer needs to be the exact value.
- Capital letters need to be added.
- Spaces need to be added in the form of %20.
- Newlines need to be added in the form of either %0A or \n
**Note 2: the country of the address must be in English. E.g. if the country is Belgium you fill out 'Belgium' and not 'België'/'Belgique'.
Note 3: It's not possible to prefill an Attachment/file question.
To prefill the questions of the following form as follows:
- Option 1 & Other = Cheese
I will need to add the following parameter to the contact form URL:
Note: Option 1 has a capital letter and a space and needs to be added as Option%201.
Which results in:
Vectera is looking forward to your feedback so we can offer you the best scheduling and customer meeting experience. Set up your next customer meeting right away by logging into your account or sign-up for a free, fully-featured trial of Vectera!