added getApiUrl method