Services Plugins FAQs

Square Card Form- trying to configure

I’m working with the Square Card Form. Just trying to do a credit card transaction. I’ve configured everything (I thought) but I keep getting this error. How can I determine which field is blank? As far as I can see, none of them are blank…

Plugin action Square Payments - Create Card Payment error:
Error: “Field must not be blank”
at eval (eval at build_function (/var/task/util/util_harness.js:37:12), :89:11)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async /var/task/plugin_api_v4_alpha.js:198:29
at async harness (/var/task/harness.js:115:15)
at async /var/task/harness.js:154:64
at async withGlobalHandlers (/var/task/harness.js:66:10)
at async Runtime.myHandler [as handler] (/var/task/harness.js:154:10)

Hi @altfeder,

Could you please show me how you’ve set up the plugin functionality in the Bubble editor? Additionally, it would be helpful if you could use the step-by-step tool in Bubble’s debug mode to show what data the “Create Card Payment” has when it triggers :pray:

I’ll do my best to help resolve this behavior!

Best regards :sunflower:

Thanks you Dorel, I really appreciate your help.

1- installed square card form (web payments sdk)
2- dropped it on a form
3- created a workflow. When “SquareCardForm A” button clicked,
- create card token (source id) from SquareCardForm A (this appears to be ok)
- Square Payments- Create Card Payment. I have the sourceID "This SquareCardForm’s Card Toke (sourceID).

When I step into the code, the source ID is blank, and I get an error for having a blank field.

Hi @altfeder,

The error you’re encountering is likely due to triggering the “Create Card Payment” action before the plugin has successfully generated the card token from the “Create Card Token” action.

To resolve this, please remove the “Create Card Payment” action from your current workflow and create a new “Do only when condition is true” workflow. For the workflow’s condition, use “SquareCardForm’s Card Token (Source ID) is not empty” and add the “Create Card Payment” action. This ensures that the “Create Card Payment” action will only trigger when the Source ID is not empty.

After making these changes, please test your setup to see if it resolves the issue. For further guidance, I recommend checking out the demo page and page editor to see how we’ve set up the plugin, as well as reviewing the documentation for additional details.

If you have any other questions or concerns about our plugins, feel free to reach out here on the forum or at support@zeroqode.com.

Best regards :hibiscus:

Hi @altfeder,

I wanted to check in and see if my suggestion above has resolved the behavior you encountered with our plugin. Please send me a quick message to confirm if everything is okay or if you’re still experiencing any issues :pray:

Hope to hear back from you soon!

Best regards :sunflower: