Add API docstrings.