Implemented lol768's request in #3 and made it simpler to declare API routes. Note that /api/ROUTE won't be registered unless you use the hybrid_route function.