Error handling in workflows / Conditional actions

This workflow includes a Webhook (Zapier, in this case) that creates an invoice in Quickbooks.
The API step marks the items that were included in the invoice as “Invoiced”

The issue is the Webhook step fails often enough due to a Quickbooks error (roughly once a week) that I need to handle the process better, and NOT run the API step to update the items unless the invoice creation step actually ran successfully.

I’d be able to write to a Glide row from the Zapier action that creates the invoice, for example, right before this Gmail step

Since I don’t know exactly how long it will take for Zapier to either create the invoice or fail, I don’t want to use a time-based waiting step, and I don’t really understand how to set up wait for condition.

What would be a good way to set this up?