Fix url handling in apiHelper 2