WIP Multi entity/profile uploads

Copy and paste for now. Need to remove code from k.h.a.entities and k.h.a.profiles after rebasing on @annapawlicka's changes.