Conditional error handling using the Remove.bg module

Hi there,

How to handle errors conditionally?

In my image processing workflow, I am using the Remove.bg module to remove backgrounds from images.

If the module returns “[400] Could not identify foreground in image. For details and recommendations see https://www.remove.bg/supported-images.” I want the scenario to continue with the next module, using different input (from the output of the module before the remove.bg module instead of the remove.bg module). If it returns any other error, such as “[402] Insufficient credits”, I want the a message to be sent to a Slack channel and it is ok for the scenario to stop execution in that case.

:raised_hands:

1 Like

Hi @cd,

When you add an error handler to a module, you can add any module you like on the error route. This includes routers, and between each module you can add filters just like you are able to in the main route. This way you can assign different actions for different error messages.

Please read the documentation for the error directives: https://www.make.com/en/help/errors/how-to-handle-errors-in-make/overview-of-error-handling-in-make

Cheers,
Henk

1 Like

Hi @cd

Please find the solution here.

Regards,
Msquare Automation - Gold Partner of Make

Book a Free Consultation | Connect Live

Explore our YouTube Channel for valuable insights and updates!