Skip to content

Simulate Users While Testing

Use the Muxy sandbox to create deterministic viewer, broadcaster, or admin JWTs without using production credentials.

Request one viewer token

Your Twitch Extension Client ID must already be registered with Muxy.

curl --request POST \
  --url https://sandbox.api.muxy.io/v1/e/authtoken \
  --header 'content-type: application/json' \
  --data '{
    "extension_id": "your-extension-client-id",
    "channel_id": "12345678",
    "user_id": "87654321",
    "role": "viewer"
  }'

The response contains one token:

{
  "token": "<sandbox JWT>"
}

For a broadcaster session, set role to broadcaster and make user_id equal channel_id. For administrator-only operations, use admin only in a controlled test environment.

Request several viewers

Use user_ids instead of user_id:

{
  "extension_id": "your-extension-client-id",
  "channel_id": "12345678",
  "user_ids": ["1001", "1002", "1003"],
  "role": "viewer"
}

The response uses the plural tokens field in the same order as user_ids.

Use a token with REST

curl --request GET \
  --url https://sandbox.api.muxy.io/v1/e/config \
  --header "Authorization: ${MUXY_CLIENT_ID} ${MUXY_SANDBOX_JWT}"

Sandbox JWTs are valid only against sandbox.api.muxy.io; never send them to production.

See the generated sandbox authorization reference for the complete request and response schema.