Forum Discussion

DavidJung's avatar
DavidJung
Qrew Assistant Captain
7 years ago

Can API_AddRecord complete if required field is blank? Help says no, my table says YES

I have a heavily modified version of the QB Wizard submission form I've been using for years. Spammers are now pinging our website every day, so I thought I'd simply turn on a field as required to slow them down, as I could see they weren't filling out ALL the fields.

So I turned on the phone number field as required. And I still get submissions with blank phone number field. My understanding from QB help, if the phone number doesn't validate, it errors out too. I'm guessing the spammers are submitting text in the field, and QB renders it as blank.

Most of the spammers successful submissions that do have 'phone numbers' are just a couple digits.

I was looking at setting up a more elaborate 'honeypot' field that is straightforward required text, but seeing these get thru made me wary of putting in the effort.

Here's my form header, for what it's worth. What do you think?


<form name=qdbform method=POST onsubmit='return validateForm(this)' encType='multipart/form-data' action=https://xxx.quickbase.com/db/my-db-table?act=API_AddRecord&apptoken=my-not-so-hidden-token>

  • The March release introduces Data Validation.  That means you can define any crazy rule hat you can write in any simple or complex formula to validate the data.  No validation = no save for you

    So you could validate that the phone number is all numeric
  • DavidJung's avatar
    DavidJung
    Qrew Assistant Captain
    Wow, that's a feature I might have otherwise overlooked. Thanks for the heads up. Bye bye spammers!
  • DavidJung's avatar
    DavidJung
    Qrew Assistant Captain
    Proud to report Day 1 with a "Custom Data Rule" the spam is blocked. Zero. Legit inquiries coming right thru. Woot! Thanks for he heads up on this new feature.
    • QuickBaseCoachD's avatar
      QuickBaseCoachD
      Qrew Captain
      Good to hear. I also got to test on a real app yesterday to see how it behaves in grid end.  If any records are invalid, it will block the save of all records and highlight in red the offending record(s).  
    • DavidJung's avatar
      DavidJung
      Qrew Assistant Captain
      I look forward to how I can use this tool to replace some form rules, one of the reasons I keep my users from using grid-edit.