Refactorized to improve HATEOAS dynamic linking