Now picking api location based on hostname