Remote interaction. Gestures handling

Dear All,
I am working with VTK-based remote vis from this template and I have to implement a gesture support.
It seems that for this I have to extend code with rpcGestureEvent similarly to how it is done for rpcRemoteWheel in
js code and python RPC implementation

However, I am not sure how to write a python part, what the event type and other data will be transferred and etc. Do I understand correctly that for this I should reference a vtkInteractorStyleRemoteMouse class ?
Is there any example of handling gestures in remote visualisation such as pinch, tap?

Thank you very much in advance,
Best regards,

Sorry for the inconvenience. Turned out to be straightforward, according to data transmitted from vtkInteractorStyleRemoteMouse class.

For example, the pinch handling with camera zoom that worked for me:

def updateGesture(self, event):

  if 'StartPinch' in event["type"]:
    renderWindow = self.getView(event['view'])
    camera = renderWindow.GetRenderers().GetFirstRenderer().GetActiveCamera()
    self.fp = camera.GetFocalPoint()
    self.pos = camera.GetPosition()
  if 'Pinch' in event["type"]:
    renderWindow = self.getView(event['view'])
    if renderWindow and 'scale' in event:
       zoomFactor = event['scale']/scaleF;

       camera = renderWindow.GetRenderers().GetFirstRenderer().GetActiveCamera()

  if 'EndPinch' in event["type"]: