clientNegotiation

open override fun clientNegotiation(negotiatedProtocols: List<WebSocketExtensionHeader>): Boolean

This method is called only for a client, when it receives the WebSocket upgrade response.

Return

true if the extension should be used by the client.

Parameters

negotiatedProtocols

contains list of negotiated extensions from server (can be empty).

It's up to extension to decide if it should be used or not.