Socket server behind the authkeeper proxy


I have a server which has REST API and Socketio WebSockets. I have put this server behind the proxy and set up a rule for REST API

Server URL:
Proxy URL:

and my rules are as follow:

    "id": "server-1",
    "description": "server -1 rest api",
    "match": {
        "methods": [
        "url": "<.*>"
    "authenticators": [
            "handler": "oauth2_introspection",
            "config": {}
    "authorizer": {
        "handler": "allow",
        "config": null
    "credentials_issuer": {
        "handler": "headers",
        "config": {
            "headers": {
                "auth-user": "{{ print .Subject }}"
    "upstream": {
        "preserve_host": true,
        "strip_path": "server1",
        "url": ""

But websocket connections use wss protocol and I have tried but unable to get any result.

So my question is how to work with websocket behind the oathkeeper proxy if it is possible and how to write rules and connect the client?