question

zgrada-zgrada11937 avatar image
zgrada-zgrada11937 asked Tyler Liu commented

Why can I not establish a connection with RingCentral server?

Hi,

We promoted application to production, but from time to time (I can say very often) we get a connection error:


"A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 199.255.120.210:443"


Could you explain me why?


Thanks!


errors
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Phong Vu avatar image
Phong Vu answered pankaj-shrestha15154 commented
It's hard to say what could be the cause of this problem.

Had this problem happened before when you test it on sandbox? Is the app now running on the same system (browser, OS, internet connection, firewall etc.)

Can you give more details of what type of authentication (password flow or 3-legged authentication), APIs you call from the app etc.

+ Phong
2 comments
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

zgrada-zgrada11937 avatar image zgrada-zgrada11937 commented ·
Hi,

we didn't have the same problem on sandbox. Application is on the same server.
Actually, it's background windows service, which call ring central server and download fax attachments.
We are using Ring Central C# client.

It's a private, server-only (No UI) application and use password flow| Refresh access token authorization flow.

We use username and pass to authorize.

await rc.Authorize(RingCentralUsername, RingCentralExtension, RingCentralPassword);
0 Likes 0 ·
pankaj-shrestha15154 avatar image pankaj-shrestha15154 commented ·
I am having the similar issue. Were you able to fix it? could you please share?
0 Likes 0 ·
Tyler Liu avatar image
Tyler Liu answered Tyler Liu commented
It seems like network issue. Do you have stacktrace? Or which API call throws this exception?
2 comments
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

zgrada-zgrada11937 avatar image zgrada-zgrada11937 commented ·

System.Net.Sockets.SocketException

A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 199.255.120.210:443

Flurl.Http.FlurlHttpException: Call failed. An error occurred while sending the request. POST https://platform.ringcentral.com/restapi/oauth/token 

---> System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: Unable to connect to the remote server 

   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)

   at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception)

   --- End of inner exception stack trace ---

0 Likes 0 ·
Tyler Liu avatar image Tyler Liu ♦ commented ·
Are you trying to do password flow? Could you please try this app:  https://github.com/tylerlong/RingCentralPasswordFlow/blob/master/RingCentralPasswordFlow/Program.cs ?  Let's see if you can reproduce the issue.
0 Likes 0 ·
zgrada-zgrada11937 avatar image
zgrada-zgrada11937 answered Tyler Liu commented
We already use password flow:

await rc.Authorize(Username,Extension, Password);
1 comment
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Tyler Liu avatar image Tyler Liu ♦ commented ·
Did you try the project I mentioned? It is known to work. Let's see if it is your local network issue.
0 Likes 0 ·
pankaj-shrestha15154 avatar image
pankaj-shrestha15154 answered Tyler Liu commented
I am having the similar issue. Were you able to fix it? could you please share?
3 comments
1 |3000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Tyler Liu avatar image Tyler Liu ♦ commented ·

This thread is about network issue so it really depends on your network connection.


If you are unable to fix this issue and you think your network is fine, please submit a help ticket.

0 Likes 0 ·
pankaj-shrestha15154 avatar image pankaj-shrestha15154 commented ·
We are using Azure , and moreover we have two different apps (one has call log perms and other has sms perms used by two separate application). The call log api is working smoothly but the sms one is having issue.
0 Likes 0 ·
Tyler Liu avatar image Tyler Liu ♦ commented ·

That sounds strange. As I said, could you please submit a help ticket and include details about the issue? Do remember to include your clientId, clientSecret, error message and/or sample code.

0 Likes 0 ·

Developer sandbox tools

Using the RingCentral Phone for Desktop, you can dial or receive test calls, send and receive test SMS or Fax messages in your sandbox environment.

Download RingCentral Phone for Desktop:

Tip: switch to the "sandbox mode" before logging in the app:

  • On MacOS: press "fn + command + f2" keys
  • On Windows: press "Ctrl + F2" keys