# cafe.thunderbird.sevenup.match

> Published by [thunderbird.cafe](https://lexicon.garden/identity/did:plc:6vxjigxrqizmbo56gojxico3)

✓ This is the authoritative definition for this NSID.

## Description

Seven-Up, a two-player dice game played with web tiles at thunderbird.cafe/webtiles/sevenup/.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:6vxjigxrqizmbo56gojxico3/cafe.thunderbird.sevenup.match)
- [Documentation](https://lexicon.garden/lexicon/did:plc:6vxjigxrqizmbo56gojxico3/cafe.thunderbird.sevenup.match/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:6vxjigxrqizmbo56gojxico3/cafe.thunderbird.sevenup.match/examples)

## Definitions

### `cafe.thunderbird.sevenup.match`

**Type**: `record`

One player's copy of a finished Seven-Up match. Each player saves their own; the record key is the match id (a TID made when the house flips the coin), so the two copies share it. A player against the bot saves alone.

**Key**: `tid`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `createdAt` | `string` (datetime) | Yes |  |
| `firstPlayer` | `integer` | Yes | Who the house's coin chose to start. |
| `handoffs` | `array` | Yes | How the dice changed hands between rounds: granted by the player holding them, or passed by the house after 10 seconds. |
| `house` | `ref` → `com.atproto.repo.strongRef` | No | The house tile that refereed the match (rolled the dice and kept the score). |
| `matchId` | `string` | Yes | The match id, also this record's key: a TID made when the house flipped the coin. (Matches saved before Oct 17 2026 have random 13-character ids.) |
| `players` | `array` | Yes |  |
| `rounds` | `array` | Yes | All six rounds in play order, three each, players taking turns. |
| `seat` | `integer` | Yes | Which player saved this record (1 or 2, an index into players). |
| `summary` | `array` | Yes | Each player's totals, in player order. Special rolls are worked out from the rolls. |

### `cafe.thunderbird.sevenup.match#player`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `bot` | `boolean` | No | True when this seat was played by the table's bot. |
| `diceStyle` | `string` | Yes |  |
| `did` | `string` (did) | Yes |  |
| `handle` | `string` (handle) | Yes | The handle at the time of the match, for display; the did is what counts. |

### `cafe.thunderbird.sevenup.match#round`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `player` | `integer` | Yes |  |
| `rolls` | `array` | Yes | Every roll of the round, two dice each, ending with the first 7. |

### `cafe.thunderbird.sevenup.match#summary`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `longest` | `integer` | Yes | Rolls in the player's longest round. |
| `quickest` | `integer` | Yes | Rolls in the player's quickest round. |
| `specials` | `integer` | Yes | Special rolls (snake eyes, yo-leven, boxcars and the doubles 2 to 5), never counting the closing 7. |

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "One player's copy of a finished Seven-Up match. Each player saves their own; the record key is the match id (a TID made when the house flips the coin), so the two copies share it. A player against the bot saves alone.",
      "key": "tid",
      "record": {
        "properties": {
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "firstPlayer": {
            "description": "Who the house's coin chose to start.",
            "maximum": 2,
            "minimum": 1,
            "type": "integer"
          },
          "handoffs": {
            "description": "How the dice changed hands between rounds: granted by the player holding them, or passed by the house after 10 seconds.",
            "items": {
              "knownValues": [
                "granted",
                "auto"
              ],
              "type": "string"
            },
            "maxLength": 5,
            "type": "array"
          },
          "house": {
            "description": "The house tile that refereed the match (rolled the dice and kept the score).",
            "ref": "com.atproto.repo.strongRef",
            "type": "ref"
          },
          "matchId": {
            "description": "The match id, also this record's key: a TID made when the house flipped the coin. (Matches saved before Oct 17 2026 have random 13-character ids.)",
            "maxLength": 13,
            "minLength": 13,
            "type": "string"
          },
          "players": {
            "items": {
              "ref": "#player",
              "type": "ref"
            },
            "maxLength": 2,
            "minLength": 2,
            "type": "array"
          },
          "rounds": {
            "description": "All six rounds in play order, three each, players taking turns.",
            "items": {
              "ref": "#round",
              "type": "ref"
            },
            "maxLength": 6,
            "minLength": 6,
            "type": "array"
          },
          "seat": {
            "description": "Which player saved this record (1 or 2, an index into players).",
            "maximum": 2,
            "minimum": 1,
            "type": "integer"
          },
          "summary": {
            "description": "Each player's totals, in player order. Special rolls are worked out from the rolls.",
            "items": {
              "ref": "#summary",
              "type": "ref"
            },
            "maxLength": 2,
            "minLength": 2,
            "type": "array"
          }
        },
        "required": [
          "matchId",
          "seat",
          "players",
          "firstPlayer",
          "rounds",
          "handoffs",
          "summary",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    },
    "player": {
      "properties": {
        "bot": {
          "description": "True when this seat was played by the table's bot.",
          "type": "boolean"
        },
        "diceStyle": {
          "knownValues": [
            "bone",
            "casino",
            "jade",
            "midnight",
            "glow",
            "brick"
          ],
          "type": "string"
        },
        "did": {
          "format": "did",
          "type": "string"
        },
        "handle": {
          "description": "The handle at the time of the match, for display; the did is what counts.",
          "format": "handle",
          "type": "string"
        }
      },
      "required": [
        "did",
        "handle",
        "diceStyle"
      ],
      "type": "object"
    },
    "round": {
      "properties": {
        "player": {
          "maximum": 2,
          "minimum": 1,
          "type": "integer"
        },
        "rolls": {
          "description": "Every roll of the round, two dice each, ending with the first 7.",
          "items": {
            "items": {
              "maximum": 6,
              "minimum": 1,
              "type": "integer"
            },
            "maxLength": 2,
            "minLength": 2,
            "type": "array"
          },
          "minLength": 1,
          "type": "array"
        }
      },
      "required": [
        "player",
        "rolls"
      ],
      "type": "object"
    },
    "summary": {
      "properties": {
        "longest": {
          "description": "Rolls in the player's longest round.",
          "minimum": 0,
          "type": "integer"
        },
        "quickest": {
          "description": "Rolls in the player's quickest round.",
          "minimum": 0,
          "type": "integer"
        },
        "specials": {
          "description": "Special rolls (snake eyes, yo-leven, boxcars and the doubles 2 to 5), never counting the closing 7.",
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "longest",
        "quickest",
        "specials"
      ],
      "type": "object"
    }
  },
  "description": "Seven-Up, a two-player dice game played with web tiles at thunderbird.cafe/webtiles/sevenup/.",
  "id": "cafe.thunderbird.sevenup.match",
  "lexicon": 1
}
```
