Delete defective backups in automation

I have an automation where I create a backup

service: backup.create
data: {}

Sometimes the Backup failes, like today:

Stopped because an error was encountered at 14. Februar 2024 um 00:17:09 (runtime: 429.33 seconds)
[Errno 28] No space left on device
Then I want to delete the defective backup.

Can someone Tell me how to do it in the automation?