Move URL-parsing utility functions out of the team.