Automation for delivering digital diliverables after successful payment through square (using square api, airtable for data log, and email stmp)

Since square doesn’t offer releasing any sort of digital product or download after payment I built my own

I’m a real estate photographer and was always delivering the digital deliverables and then the client could pay their invoice (which often was left unpaid for weeks)

This workflow checks for any new invoices created through square —> then checks if the invoices exist in airtable (if not it creates a new field) —> after that it checks if any invoices statuses have been changed from unpaid to paid —> if they have then they get sent further down the workflow to get an email sent to the client with their digital deliverables.

I know there is services that offer this currently but they charge per project and also this was a great opportunity for me to learn n8n. I couldn’t find anywhere online of an automation like this so maybe it will help someone else.

Also im sure someone will ask for the code for this can i just copy the entire workflow and paste it without it giving any personal data like Api/email details?

I later realized the above workflow wasn’t very effective as it took nearly 1 minute to run. With this new setup it takes 4.6 seconds to update the airtable as paid and send the client an email with their media once theyve paid their invoice.