-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Description
This issue was reported by a customer. Could be reproduced here https://github.com/ringcentral/ringcentral-python/blob/master/ringcentral/demos/demo_subscription.py
WebSocketEvents.subscriptionCreated
even never triggered.
This is because, after susbscription created, server side returned:
[{'type': 'ClientRequest', 'messageId': '29588305-dd9b-4bc4-8d61-4bb7957f2f2f', 'status': 200, 'headers': {'Server': 'nginx', 'Date': 'Wed, 20 Aug 2025 22:23:55 GMT', 'Content-Type': 'application/json', 'RoutingKey': 'SJC01P07', 'RCRequestId': 'bedff5ae-9d68-4bc9-8653-7e34603ef562-2686696-1-19'}}, {'uri': '/restapi/v1.0/subscription/1b2a2e6b-2245-4278-b47c-16259ca003a8', 'id': '1b2a2e6b-2245-4278-b47c-16259ca003a8', 'creationTime': '2025-08-20T22:23:55.169Z', 'status': 'Active', 'eventFilters': ['/restapi/v1.0/account/809646016/extension/62264425016/presence'], 'expirationTime': '2025-08-21T22:23:55.169Z', 'expiresIn': 86399, 'deliveryMode': {'transportType': 'WebSocket', 'encryption': False}}]
Client side code:
if(message_json[0]['type'] == 'ClientRequest' and 'WSG-SubscriptionId' in message_json[0]['headers']):
self.set_subscription(message_json)
self._web_socket_client.trigger(WebSocketEvents.subscriptionCreated, self)
But server returned json data doesn't have header "WSG-SubscriptionId".
Metadata
Metadata
Assignees
Labels
No labels