How to create a Typeform quiz to match listings
Learn how to create a quiz in Typeform using Typeform custom variables that intelligently recommends quiz-takers listings in your Tangram app.
At A Glance
- Create a new Typeform quiz for the questions you want to match listings based on
- Assign Tangram IDs to Typeform custom variables for each potential answer in “Advanced Logic”
- Use “Branching & Calculations” in the “Logic” tab to add the option_id to the variable you just created.
- Redirect the Typeform on completion to your pre-filtered Tangram directory by passing the Typeform variables into the directory URL.
Step #1: Decide On Typeform Quiz Matching Questions
The first step of this Typeform quiz tutorial is to decide what questions you want to match users who fill out your Typeform quiz on. For example, a wellness marketplace may want to match users based on the “type of service” (e.g. class, workshop, private session) and “modality” (e.g. yoga, acupuncture, art therapy). Once you have decided what questions will determine which listings the quiz-taker will get recommended you can build your Typeform as shown below:
Step #2: Create a Typeform Variable for Each Matching Questions
Now that you have built and designed your quiz in Typeform and decided which of the questions should determine the match you will need to create Typeform custom variables for each of the matching questions. To create a variable in Typeform navigate to “Logic” > “Advanced Logic” > ”Variables” > “Add Custom Variable”. For the question, “What type of service are you looking for?”, we have to create a variable and name it “@service_type” and make sure that it is a “Number” type variable so we can add an option_id from Tangram in the next step.
Note: if you want to match on the listing location (e.g. city, neighborhood, zip, or exact address you will want to make the category variable(s) of the type TEXT). If you want to match on “listing type” or “listing location” these can only be single-select answers.
For the question, “What modalities are you interested in?”, because this input is a select field in Tangram, we have the choice to decide whether we want quiz-takers to be able to select multiple or just one of the answers to this question. If we want quiz-takers to be able to say they are looking for both acupuncture AND yoga we will need to create a variable for each modality (e.g. @modality1, @modality2, @modality3, @modality4, @modality5)
You do NOT need to create a variable for each answer if you want the quiz-taker to only be able to select one answer to a given question. For example, in the case above if you want to force the quiz-taker to specify whether the quiz-taker is looking for acupuncture OR yoga (not both), then you only need to create a single variable called @modality for this question.
Note #1: You will always want to create a NUMBER variable for every matching question you decided on in step #1 (unless you are matching on location in which case it will be a TEXT variable).
Note #2: Remember to toggle “multiple select” ON if you want Typeform quiz takers to be able to select multiple options.
Step #3: Assign Tangram Values To Typeform Variables
Phew! Now that you have a Typeform variable for every matching question, you’ll need to update the value of the variable by adding the correct ID to it depending on which answers the quiz-taker selects.
If one of your matching questions is to match on your listing types in tangram (e.g. “What listing type are you looking for?”) you can find the Listing_Type_ID by navigating to “Settings” > “Roles” > Select the role who can list the service/listing type you are matching on (e.g. Provider) > “Listing Types” > Select the listing type that you are matching on (e.g. Private Session) and looking in the URL.
Once you have the Listing_Type_ID for “Private Session” from the URL in your Tangram admin account, add it to the @service_type variable we created in Typeform when a quiz-taker says they are looking for a “Private Session” in “Logic” > “Simple” > “Branching & Calculations”. Repeat this step for all answers to this question for every listing type.
For questions that are matching on “select fields” you will want to add the option_id from Tangram for each question answer to the @modality variable(s) we created in Typeform.
For a SINGLE-select question, if the quiz-taker says they are looking for yoga, use the same @modality variable for every rule in Typeform.
For a MULTIPLE-select question, if the quiz-taker says they are looking for acupuncture AND yoga, map @modality1, @modality2, @modality3, @modality4, @modality5 to a different answer each.
If you want to filter by a listings location with Typeform, the location question has to currently be a multiple choice SINGLE-select question due to a limitation on Typform’s end. You can make the location multiple choice answers for cities, zip codes, neighborhoods, or exact addresses.
Once you have turned your location matching question into a multiple choice question you will need to replace the location variable text with the text of each answer in “Logic” > “Simple” > “Branching & Calculations”. Click “Save”.
Step #4: Redirect Typeform Quiz To Tangram Directory On Completion
Once you have Typeform custom variables and values setup for all your matching questions and their answers you are ready to use them to redirect the quiz-taker to a pre-filtered version of the Tangram listing directory. To do so, you will need to set the “Redirect On Completion” link in your Typeform quiz settings to:
If modality question is SINGLE-select:
If modality question is MULTIPLE-select:
Note: Location and ListingType are special fields that do not follow the category 1,2,3,etc pattern. If you are matching on listing type use “flow=@variable”. If you are matching on location use “location=@variable”
How to filter a directory based on whether a keyword is found anywhere on a listing info page (not just if the listing has it as a tag):
You can also use the search bar in Tangram to pre-filter not just by the listing’s tags, but by whether or not keywords appear anywhere on the listing info page. For example, if I search for “Private Yoga” in the search bar of my Tangram listing directory it will give me all the listings that contain the keyword “Private Yoga” in the title or description of the listing (not just as an input/tag).
To pre-filter the directory by a specific search/keyword like “Private Yoga” you can tack on &search=private+yoga to the end of your “Redirect On Completion” URL which will search for listings with both the keyword "private" AND "yoga" anywhere in the listing info page.
If you would rather the search result in any listing with either "private" OR "yoga" anywhere in the listing info page tack on &search=private|yoga