>>

Server Payload

Pandemonium websocket payloads sent by the server to the client.

>>

Pong

A Client Payload PING payload response.

FieldTypeDescription
op“PONG”The op of this ServerPayload variant.
>>

Example

{
  "op": "PONG"
}
>>

Rate Limit

The event sent when the client gets gateway rate limited.

The client is supposed to wait wait milliseconds before sending any more events, otherwise they are disconnected.

FieldTypeDescription
op“RATE_LIMIT”The op of this ServerPayload variant.
dRate Limit DataThe data of this variant

With the data of this variant being:

FieldTypeDescription
waitNumberThe amount of milliseconds you have to wait before the rate limit ends
>>

Example

{
  "op": "RATE_LIMIT",
  "d": {
    "wait": 1010 // 1.01 seconds
  }
}
>>

Hello

The payload sent by the server when you initiate a new gateway connection.

FieldTypeDescription
op“HELLO”The op of this ServerPayload variant.
dHello DataThe data of this variant

With the data of this variant being:

FieldTypeDescription
heartbeat_intervalNumberThe amount of milliseconds your ping interval is supposed to be.
instance_infoInstanceInfoThe instance’s info.

This is the same payload you get from the Get Instance Info payload without ratelimits
pandemonium_infoPandemoniumConfThe pandemonium-related configuration and ratelimit info
>>

Example

{
  "op": "HELLO",
  "d": {
    "heartbeat_interval": 45000,
    "instance_info": {
      "instance_name": "EmreLand",
      "description": "More based than Oliver's instance (trust)",
      "version": "0.3.3",
      "message_limit": 2048,
      "oprish_url": "https://example.com",
      "pandemonium_url": "https://example.com",
      "effis_url": "https://example.com",
      "file_size": 20000000,
      "attachment_file_size": 100000000
    },
    "pandemonium_info": {
      "url": "https://example.com",
      "rate_limit": {
        "reset_after": 10,
        "limit": 5
      }
    }
  }
}
>>

Message Create

The event sent when the client receives a Message.

FieldTypeDescription
op“MESSAGE_CREATE”The op of this ServerPayload variant.
dMessageThe data of this variant
>>

Example

{
  "op": "MESSAGE_CREATE",
  "d": {
    "author": "A Certain Woo",
    "content": "Woo!"
  }
}