Server programming but how

Hi, I wanted to ask how it is with the server programming. For example, I would like the server to save the players into a file every 5 minutes. So the stats Water, Huger, Life, etc. Or I would like to have a console command that kills a specific player for example. I can’t find anything on the Internet about this, can anyone tell me anything?