I will help you clarify this.
Presence is data that passes via the 3CX Webserver which makes it Web Data.
When an APP Connects to 3CX, it connects like a browser (HTTP/HTTPS) and it connects like an IP Phone (SIP/TLS)
The connection it makes like a browser gets data like presence.
The connection it makes like a phone gets calls
So the web connection part, also implies that you need a web based protocol to allow apps and servers to exchange web data.
So you need to focus on 3CX "Web" ports - the ports you configured for the webservices at installation time - normally they are 80 HTTP 443 HTTPS or 5000 HTTP and 5001 HTTPS.
Now you should be able to understand that its not 5000.. Its 5000 AND 5001.
Now when do we use either port? Simple - depending on where you are (As in where you network related to the server)
As a rule, all external traffic is HTTPS (encrypted). So the webserver will not even offer http data if it sees that the app is coming from an external network.The socket is just closed.
If your machine is on the cloud, everything is external - so you will see only 5001 traffic...
Hope this helps