HTTP Request from Business Logic

I have tried numerous libraries to make HTTP request from my Business Logic code, however they’ve all ended up giving me different types of errors (namely calls that are designed to be synchronous actually making asynchronous calls and so unable to run on server side Java).

Are there any recommendations for making a simple HTTP GET request from Backendless business logic? Any examples of working code?

Thank you; I’ve spent many hours with this :confused:


You can use HttpURLConnection. But don’t forget to add host you are trying to call to external hosts in backendless application settings.



What exactly do you mean by “external host”? I’m just trying to retrieve data from the following API’s:

Do I have to add something related to those to be able to access their API’s from server side code?

Is that why I am getting this error:

SEVERE: access denied ("" "" "connect,resolve")

Thank you

Denys meant this:

Yes, I see but I am now wondering if the API’s I referenced are considered “external hosts”. When I try to add “” as an external host it does not let me enter it.


is a URL

but this:

is a hostname…

So add just the hostname and that will start the approval process.

I got the host name approved yet I still get the error:

SEVERE: access denied ("" "" "connect,resolve")


Internal ticked has been created for this issue.



Any update?

Okay well I don’t know how I’m supposed to use Backendless business logic if it doesn’t let me access any API’s. The previous BaaS I used did all this fine and there wasn’t even an approval process for every API I wanted to access.

Is this for debug mode or production?

If the former, the hostname must be added to bin/ file (see the property at the bottom of the file). If the latter, the problem might be related to the host responding with different IP addresses. This is what Denys referred when he said there is an internal ticket.

Added it to my properties file as you recommended:</img>
And still get the same error:

SEVERE: access denied ("" "" "connect,resolve")


Please, check the availability of this host using the following code: