This is a locking cover for Dewalt brand batteries. I don't know how many of their batteries share the same geometry but this was specifically designed to fit their 20v Lithium-Ion batteries, part number N115985. This will wrap around the grooves in the side of the battery and use the existing locking mechanism. This will keep your battery terminals covered to prevent accidental arcing and also help protect them from the elements.
This is a tight fitting item. I'd recommend a small wood chisel to remove the support material as it's pretty deep into the print.