Skip to content

How to Filter Out Events During Websocket Initialization? #73

@mkmoisen

Description

@mkmoisen

Hi @fbradyirl

How do we filter events during the websocket initialization, such that we only receive relevant events like messages:created or attachmentActions:created ?

I see in this code here:

            async with connect as _websocket:
                self.websocket = _websocket
                logger.info("WebSocket Opened.")
                msg = {'id': str(uuid.uuid4()),
                       'type': 'authorization',
                       'data': {'token': 'Bearer ' + self.access_token}}
                await self.websocket.send(json.dumps(msg))

This doesn't include a filter option, so it receives all events.

For example it even includes events when users are typing, which I would rather not receive and have to expend cycles processing.

It would be great to have these filtered out on Webex's server side before they ever hit our application.

The javascript JDK apparently has a way to only listen for specific events.

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions