SOLVED

Form | Only allow option to be selected once

Go to solution
Brendan_Burk
Level 1

Form | Only allow option to be selected once

I'm trying to limit the number of times an option can be selected on a form, and haven't been able to find much of anything. Anyone have any ideas?

Ex: I have 5 options (A, B, C, D, E). I have 5 individuals I intend to provide the form to. I'm trying to set this form to only allow A to be selected by a single individual. Same for B, and so on...

Thanks in advance.  

Brendan Burk
Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
SanfordWhiteman
Level 10 - Community Moderator

Re: Form | Only allow option to be selected once

There's no built-in feature for sharing a single pool of options among different leads like this.

You'd need to use a webhook to update a central repository (which can be a different Resource Lead in Marketo, a program token in Marketo, or a totally 3rd-party db of some sort).  Then as you render the form always check the current contents of the pool.

It's really just another form of the same concept of restricting the # of leads who can register for an event.

Not hard to roll out if you understand the moving parts and/or have someone on hand who does, but outside the usual Marketo box for sure.

View solution in original post

3 REPLIES 3
SanfordWhiteman
Level 10 - Community Moderator

Re: Form | Only allow option to be selected once

There's no built-in feature for sharing a single pool of options among different leads like this.

You'd need to use a webhook to update a central repository (which can be a different Resource Lead in Marketo, a program token in Marketo, or a totally 3rd-party db of some sort).  Then as you render the form always check the current contents of the pool.

It's really just another form of the same concept of restricting the # of leads who can register for an event.

Not hard to roll out if you understand the moving parts and/or have someone on hand who does, but outside the usual Marketo box for sure.

Brendan_Burk
Level 1

Re: Form | Only allow option to be selected once

Thanks Sanford. That makes sense. Can you give me a bit of insight, or point me to a related conversation, that explains how to use the webhook with a program token? I appreciate any help.

Brendan Burk
SanfordWhiteman
Level 10 - Community Moderator

Re: Form | Only allow option to be selected once

Sorry for the delay, Brendan Burk​.

When we speak of updating tokens via webhook, that means calling a webhook gateway: a webhook-compatible service that loops back and uses Marketo's REST API to update program-level token text. Usually, the token is in the same program from which the webhook was called, so you can include the {{Program.Id}} in the outgoing webhook payload so the remote service knows where to write back to.

There are existing webhook endpoints that have this logic built-in, or at least close to built-in. (Because of Community rules I won't name them.)

Note that although outbound webhook calls themselves are not metered, each webhook call uses one API call on the way back in, so this is not something to do in huge quantities. (You need to make sure this "loopback" integration can only use a certain max # of calls per day.) I would sooner have my webhook manage the data on its own, really. It's less wear-and-tear on Marketo, as it doesn't use the API, and the program token isn't key to a working setup, it's just a way -- the most clumsy way, though- -- to have a persistent place to save data.