CrazyAPI: some cleanup and improvements for commands