# app.racethesky.teamMembership

> Published by [racethesky.app](https://lexicon.garden/identity/did:plc:37slmbx2v4gh6sa4ncfz7yid)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:37slmbx2v4gh6sa4ncfz7yid/app.racethesky.teamMembership)
- [Documentation](https://lexicon.garden/lexicon/did:plc:37slmbx2v4gh6sa4ncfz7yid/app.racethesky.teamMembership/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:37slmbx2v4gh6sa4ncfz7yid/app.racethesky.teamMembership/examples)

## Definitions

### `app.racethesky.teamMembership`

**Type**: `record`

A player's claim to be on a Race the Sky team. Only the account holder can write to their own repo, so the presence of this record is the proof of membership — and its absence is the proof of departure. A player races for one team at a time, so the record key is always 'self'.

**Key**: `literal:self`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `teamId` | `string` | Yes | The team being joined. Deliberately not the team's join code: records are public, and a published join code would let anyone onto the squad. |
| `teamName` | `string` | No | The team's display name when the player joined, so the record reads as something human without a lookup. Advisory — the team's own record is authoritative and the name may since have changed. |
| `createdAt` | `string` (datetime) | Yes | Client-reported time the player joined. |

## Raw Schema

```json
{
  "id": "app.racethesky.teamMembership",
  "defs": {
    "main": {
      "key": "literal:self",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "teamId",
          "createdAt"
        ],
        "properties": {
          "teamId": {
            "type": "string",
            "maxLength": 64,
            "description": "The team being joined. Deliberately not the team's join code: records are public, and a published join code would let anyone onto the squad."
          },
          "teamName": {
            "type": "string",
            "maxLength": 64,
            "description": "The team's display name when the player joined, so the record reads as something human without a lookup. Advisory — the team's own record is authoritative and the name may since have changed."
          },
          "createdAt": {
            "type": "string",
            "format": "datetime",
            "description": "Client-reported time the player joined."
          }
        }
      },
      "description": "A player's claim to be on a Race the Sky team. Only the account holder can write to their own repo, so the presence of this record is the proof of membership — and its absence is the proof of departure. A player races for one team at a time, so the record key is always 'self'."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
