Hey everyone!
I'm currently comparing my options for building a website for an event. It has to have functionality to vote for a team. Voting would be '1 vote/phone number' so is that possible with (maybe collection) hooks? It would use an external API for sending a SMS and verify the code that would be stored in another collection.
Thanks!
Hi there,
sounds like that should be easily possible! You could use a field
validate
to check if there have been multiple votes for that phone number, and if so, reject it there.
In an afterChange or beforeChange hook, you could then trigger the sending of an SMS, so that it would trigger whenever a new Vote has been created
Oh, thanks! Just wanted to confirm :)
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.