hal+json middleware for Koa