We have the requirement as explained below. I would like to understand how it can be achieved in airtable? The steps are as follow.
There will be a form-1 where in user enters “company name”.
Click on “Generate Data” button. This button will call the script to invoke external API.And whatever response we get from API,those responses will used to buld the airtable form-2 link with pre-fill option.
After that, flow will be redirect edto this pre-filled form-2 link automatically.
The challenges in above approach is as flollow:
For step-2, when end user will click on generate data button This action will call some custom script to fetch response from external API. So, my doubt is how to build form-2 link using pre-fill option with the values got from custom script/external API on the fly.
Apart from this, Let’s say we are on form-1 and clicked on generate data button. So, is it possible to display responses got from custom script/API on same airtable form?
Please suggest your thought on above questions. It would be very helpful.
Airtable forms can redirect to one predefined link that can include only one dynamic parameter: the record ID of the record that was just submitted. So you can redirect the person to a webhook in Make that includes the record ID, have Make calculate the prefill link, and then redirect the person to the 2nd form by using a custom webhook response that redirects the user: Webhook Documentation
While we do have Subforms in the new On2Air Forms (you can add a form inside of a form), it’s not quite possible to do exactly what you’re wanting to do because it would take time for the script to run to generate the prefill values. So, you couldn’t link to new form yet since values won’t be available on the first form submission.
You could do what @ScottWorld suggested as his #1 workaround. Once the first form is submitted and runs the script, then have an Airtable automation that sends an email with link to second form to fill out that can have the prefills in the link. (We also have an easy-to-use prefills setting in our app)
Thank you for your reply Scott. I was also thinking to implement using option #1. I am looking for free services which allow me to implement this flow.
I have another question, Is it possible to have only single form where i can click on “Generate Data” button. And then, person will be redirected to same form but wilth prefilled values. Keep in mind, when i click generate data it will call 2-3 external API which w’ll use for pre filling.
Coming to option#3, we can pass record_id dynamically using Redirect to URL option. But basically, how to prepare form-2 link just like prefill_FIELD=value.
It doesn’t make a difference whether you use 1 form or 2 forms… the same exact process would be necessary.
Whether you use #1 or #3, you’ll need to create your own prefill formula field in Airtable. If you’re having difficulty creating your own prefill formula, I would check out @kuovonne’s Prefilled Forms extension: