REST: Support the 'templated' property in links
REST: Refactor / improve link handling