Using the Platform API notification service, websocket connection, is there an expiry time ?
What does it mean when you stop receiving the heartbeat messages ?
Also, in order to resubscribe to the topics, to keep the channel active, do you use the
PUT /api/v2/notifications/channels/{id}/subscriptions
or the
POST /api/v2/notifications/channels/{id}/subscriptions
or is there another way ?
Thanks Tim for your reply.
I am resubscribing to the topics with PUT every 12 hours interval, but still see regular disconnects from the channel.
Sometimes I see that there was a POST to subscribe to topics, then within a couple hours, I stop receiving the heartbeats.
Is there anything else I need to do to maintain the channel connection ?
If you're creating too many channels, the oldest channel will be closed when a new one is created over the limit. Could also just be network connectivity issues for the clients having the issue.
If you need assistance troubleshooting why your sockets are closing, please open a case with PureCloud Care to investigate; customer-specific information (like your network details and packet captures) cannot be investigated via the forum.
Timestamps are in ISO-8601 format unless specified otherwise in the documentation. The standard in the API is to use UTC for timestamps, but there may be instances where a different offset is used. A well-formed application will parse the timestamp along with the offset.
The presence or absence of a heartbeat indicates whether or not your WebSocket is functioning properly; it does not indicate the validity of a channel, in either direction.
That's likely a networking issue on your end. Make sure your ports and firewalls are open to be able to establish a connection to the specified host/port/protocol.