games.cavu.tier-madness.subscribeGame

chris.pardy.family

Documentation

A game's live channel. The socket is bidirectional: the client sends games.cavu.tier-madness.clientFrame frames (#auth then #create/#join to play, or just #spectate to watch); the server sends a #snapshot of the game as that viewer may see it whenever it changes.

main subscription

A game's live channel. The socket is bidirectional: the client sends games.cavu.tier-madness.clientFrame frames (#auth then #create/#join to play, or just #spectate to watch); the server sends a #snapshot of the game as that viewer may see it whenever it changes.

Message Types

Open union

Errors

GameNotFound
AuthRequired
BadFrame
IllegalAction
RateLimited
GameStarted
WriteFailed Couldn't record the move in the player's PDS; it wasn't applied.
View raw schema
{
  "description": "A game's live channel. The socket is bidirectional: the client sends games.cavu.tier-madness.clientFrame frames (#auth then #create/#join to play, or just #spectate to watch); the server sends a #snapshot of the game as that viewer may see it whenever it changes.",
  "errors": [
    {
      "name": "GameNotFound"
    },
    {
      "name": "AuthRequired"
    },
    {
      "name": "BadFrame"
    },
    {
      "name": "IllegalAction"
    },
    {
      "name": "RateLimited"
    },
    {
      "name": "GameStarted"
    },
    {
      "description": "Couldn't record the move in the player's PDS; it wasn't applied.",
      "name": "WriteFailed"
    }
  ],
  "message": {
    "schema": {
      "refs": [
        "#snapshot",
        "#created"
      ],
      "type": "union"
    }
  },
  "parameters": {
    "properties": {},
    "type": "params"
  },
  "type": "subscription"
}
created object

Reply to #create: the join code to share, and what goes in the host's games.cavu.tier-madness.lobby record.

Properties

code string Required

No description available.

maxLength: 4 bytesminLength: 4 bytes
codeHash string Required

No description available.

maxLength: 128 bytes
expiresAt string datetime Required

An RFC 3339 formatted timestamp.

game string Required

No description available.

maxLength: 64 bytes
spaceHost string did Optional

A decentralized identifier (DID).

View raw schema
{
  "description": "Reply to #create: the join code to share, and what goes in the host's games.cavu.tier-madness.lobby record.",
  "properties": {
    "code": {
      "maxLength": 4,
      "minLength": 4,
      "type": "string"
    },
    "codeHash": {
      "maxLength": 128,
      "type": "string"
    },
    "expiresAt": {
      "format": "datetime",
      "type": "string"
    },
    "game": {
      "maxLength": 64,
      "type": "string"
    },
    "spaceHost": {
      "format": "did",
      "type": "string"
    }
  },
  "required": [
    "game",
    "code",
    "codeHash",
    "expiresAt"
  ],
  "type": "object"
}
snapshot object

No description available.

Properties

now integer Required

Server time, ms since epoch.

seq integer Required

No description available.

minimum: 0
View raw schema
{
  "properties": {
    "now": {
      "description": "Server time, ms since epoch.",
      "type": "integer"
    },
    "seq": {
      "minimum": 0,
      "type": "integer"
    },
    "view": {
      "ref": "games.cavu.tier-madness.defs#gameView",
      "type": "ref"
    }
  },
  "required": [
    "seq",
    "now",
    "view"
  ],
  "type": "object"
}

Lexicon Garden

@