Some hacky codegen to allow generic webapi routing