Network Automation 2019.05 - clean Diagnostic istory

Hi all,

is there a way to periodically clean, in a automated way, the diagnostic history of a diagnostic for certain device groups ?

Thanks in advance,

Giacomo