Update api.php with more docs and doc generation command