script failover with 3 ISP

Hello everybody.

I have the following problem, if anyone knows please help me.

I have a hex which has 3 ISP router.
1 ISP Metronet
1 ADSL ISP
1 ISP VODAFONE (on USB)

I need to do failover level script to check in 8.8.8.8 is interrupted when an ISP to give the next.
The order would be
Metronet distance = 1
ADSL 2 = distance
Vodafone stik = distace3

Thank you,

You can achieve this with Netwatch.

https://wiki.mikrotik.com/wiki/Manual:Tools/Netwatch

Make a static route for 8.8.8.8 with each gateway and mark check-gateway with ping to determine if the ISP is UP.

/ip route add dst-address=8.8.8.8 gateway=METRONET distance=1 check-gateway=ping
/ip route add dst-address=8.8.8.8 gateway=ADSL distance=2 check-gateway=ping
/ip route add dst-address=8.8.8.8 gateway=VODAFONE distance=3 check-gateway=ping

With this when one of the gateways is off the default route will be disable.

/ip route add dst-address=0.0.0.0/0 gateway=METRONET distance=1
/ip route add dst-address=0.0.0.0/0 gateway=ADSL distance=2
/ip route add dst-address=0.0.0.0/0 gateway=VODAFONE distance=3

You will see only one black the others will be blue and inactive.

Testing the gateway accessibility does not say anything about Internet access.