Skip to content

Connect to the websocket server

After successful authentication and getting client UUID along with actor profile ID1, you can connect to the Tallyfy Manufactory websocket server: wss://collector.tallyfy.com/ws

Once a websocket connection is established, you’ll receive a message Manufactory Collector ✅

WebSocket authentication flow

This diagram shows the authentication handshake between your client and the Manufactory WebSocket server.

Diagram

What to notice

  • Two-phase authentication: First the WebSocket connection itself, then the authentication message exchange
  • Required credentials: The auth message must include all five required keys (type, org_id, project_id, client_uuid, actor_profile_id)
  • Sequential flow: Each step must complete successfully before proceeding. The connection won’t accept events until authentication succeeds

Next, we need to pair the connection with the client/end-user. That’s where the actor profile ID and client UUID become active.

Required keys

  • type (required) string - The message type, in this case we will be using auth.
  • org_id (required) string - Manufactory org ID.
  • project_id (required) number - The project ID associated with this schema.
  • actor_profile_id (required) number - The actor profile ID we got after authentication.
  • client_uuid (required) string - the generated UUID we got after authentication.

Websocket message example

{
"type": "auth",
"org_id": "xyz",
"project_id": 12345,
"client_uuid": "e17a56a9-596f-40e6-b01c-d37136df1de8",
"actor_profile_id": 1
}

Websocket reply example

{
"type": "auth",
"status": "ok"
}

Now you can send the actor’s generated events through the open websocket channel.

Footnotes

  1. A unique identifier for the authenticated user within the Tallyfy organization context