Search code examples
c++boostwebsocketrequest-headersbeast

How can I put a custom header for websocket handshake with boost beast


How to send custom headers in the first handshake that occurs in the WebSocket protocol with boost beast ?

I want to use custom header in my initial request "x-custome-id : xxxxx".


Solution

  • I've found the candidate solution as https://github.com/boostorg/beast/issues/70.
    But, this occurs compiler error with boost 1.69.
    This issue also fixed with the solution https://github.com/boostorg/beast/issues/1470.