Quantcast
Channel: Mattermost Discussion Forums - Latest posts
Viewing all articles
Browse latest Browse all 25778

How to Pass Credentials to Websocket from external domain?

$
0
0

Hi @keithg,

New in Mattermost 3.5, you can authenticate your WebSocket by connecting and then providing the token in a JSON formatted authentication challenge over the WebSocket.

An example authentication challenge would look like this:

{
    "seq": 1,
    "action": "authentication_challenge",
    "data": {
        "token": "mattermosttokengoeshere"
    }
}

If the WebSocket authenticates correctly then you will receive a standard ok response looking like this:

{
    "status": "OK",
    "seq_reply": 1
}

All previous versions of Mattermost before 3.5 will require the token in the cookie. Mattermost 3.5 still supports authenticating through the cookie.


Viewing all articles
Browse latest Browse all 25778

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>