---
title: "Authenticate stream user"
url: https://docs.gleap.ai/en/reference/rest-api/user-auth
method: POST
path: "/s2s/stream/user-auth"
api: "API Reference"
tag: "S2S Stream"
operationId: "UserAuth"
updatedAt: "2026-11-01T18:40:15.677Z"
language: en
---

# Authenticate stream user

`POST https://api.gleap.io/v3/s2s/stream/user-auth`

User authentication (Pusher signin) — REQUIRED for server-side takeover termination to reach your connection. Configure it as the client's userAuthentication endpoint.

## Authorization

- `Authorization` (header, required): `Bearer <token>`

## Request body (`application/json`, required)

- `socket_id` (string, required)
- `consumerId` (string, required)

## Example request

```bash
curl --request POST \
  --url https://api.gleap.io/v3/s2s/stream/user-auth \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "socket_id": "<socket_id>",
  "consumerId": "<consumerId>"
}'
```

## Responses

### 200 (`application/json`)

Ok
