Skip to content
Daniel edited this page Mar 20, 2016 · 12 revisions

First, you can open the socket connection

wss://api.thepathfinder.xyz

The server then sends a connection id message

{ "message":"ConnectionId",
  "id":"this is a unique identifier"}

After receiving this message, a post request with the following jwt should be made to authentication-server/connection

{
   "iss":"my_app_id",
   "sub":"connection id",
   "aud":"https://auth.thepathfinder.xyz",
   "exp":12345678,
   "email":"[email protected]"
}

It should be signed using your application secret given to you when you create the app. Upon receiving an OK response, send the authenticate message through the web socket:

{"message":"Authenticate"}

Wait for the Authenticated message:

{"message":"Authenticated"}

now you are ready to go

Clone this wiki locally