From betfair forum: I’d like to саnсеl а bеt thаt І'vе рlасеd thе nіght bеfоrе а rасе, іf іt dоеsn't gеt mаtсhеd bу 6аm, is there any way to do this automatically without a person needing to manually cancel it themselves?
First we need to add bot by clicking on Add a new bot in the Bots to Execute view, in the dialog we search for: “Stop Bots and Cancel Bets”. Clicking on the Save button the bot is added.
We can list all markets on which we have got placed bets, by clicking on “Events with my bets” the events are displayed in Event Browser.
Clicking on the button “Execute in Bot Executor” the dialog “Open in Bot Executor” appears. In the field Bot to execute we select the bot we added in the point 1) set the time at which we want to cancel unmatched bets on the market, we set the time to -00:05:00, what is 5 minutes before official event start time.
Un-checking the field: Open only select the bot will be executed on all listed markets in the Event Browser view.
Clicking on Open button all listed markets will be added to Bot Executor tool. We leave bfexplorer app running and at set time unmatched bets will be automatically cancelled.