connection time out after 10000 millisec

I have created a app which is calling an API for JSON data.
at local machine app is working fine. But while publishing in, in logs it showing error as below ;
Error in curl::curl_fetch_memory(url, handle = handle) :
2020-06-19T14:35:56.565769+00:00 shinyapps[2478107]: Timeout was reached: [XXXXXXXXXXXX] Connection timed out after 10000 milliseconds.

How to fix this issue?
Any help on this issue greatly appreciable.