How to add a c++ class to reading dedicated server without loading map

Hello guys
I’m working on online game, i wanted to make a offline system checking, for make that i need to call some function just in server, for example checking online player function,
i wrote my algorithm to checking offline players, and finally i understood the server just read script from default map or another map.
what i want to do, i want to remove default map for server because i do not need that, and instead of that put some c ++ class or blueprint.
can you give me some solution ?
thank you for regarding .