utils for API doc generation