Finish implementing preliminary API endpoints (usable now, but you'll have to catch your own errors).
Add docstrings.