# at.postgame.badge

> Published by [postgame.at](https://lexicon.garden/identity/did:plc:crwol3wvv2w2lvvognhvd5cm)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:crwol3wvv2w2lvvognhvd5cm/at.postgame.badge)
- [Documentation](https://lexicon.garden/lexicon/did:plc:crwol3wvv2w2lvvognhvd5cm/at.postgame.badge/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:crwol3wvv2w2lvvognhvd5cm/at.postgame.badge/examples)

## Definitions

### `at.postgame.badge`

**Type**: `record`

A badge earned by a user, awarded by the postgame system based on activity

**Key**: `any`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `badgeId` | `string` | Yes | Unique identifier for the badge type, used as the record key. Badge types and their criteria are defined by the postgame system |
| `subject` | `string` (at-uri) | No | Optional AT-URI of the record that triggered this badge (e.g. the game entry) |
| `createdAt` | `string` (datetime) | Yes | When the badge was earned |

## Raw Schema

```json
{
  "id": "at.postgame.badge",
  "defs": {
    "main": {
      "key": "any",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "badgeId",
          "createdAt"
        ],
        "properties": {
          "badgeId": {
            "type": "string",
            "maxLength": 128,
            "description": "Unique identifier for the badge type, used as the record key. Badge types and their criteria are defined by the postgame system"
          },
          "subject": {
            "type": "string",
            "format": "at-uri",
            "description": "Optional AT-URI of the record that triggered this badge (e.g. the game entry)"
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "When the badge was earned"
          }
        }
      },
      "description": "A badge earned by a user, awarded by the postgame system based on activity"
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
