Refactor url joins into resources