Delete components in Blueprint Asset via Editor Scripting

Hi folks, I´ve already done some research but haven´t found a solution yet.

Basically I´m trying what the title says. I´ve got sent a blueprint asset which contains a huge hierarchy with thousands of scene components and at the lowest level there are some static mesh components. All i want to do is to edit the asset via an editor blueprint script to delete all scene components so that the static mesh components remain.

All the tutorials I´ve found edit other asset classes like Texture or Static Mesh and none a Blueprint asset.

Can you help me?