fix $apiUrl to $apiHost.$apiPath