Reorganized the tests.
Added docs & improvements for custom endpoints.