# radio.4000.defs

> Definitions shared by the records, and views of records served by the 4000.radio index. Each view carries the record as it is in its repo.

- Kind: defs
- Authority: 4000.radio
- Lexicon: 1
- Published by [4000.radio](https://lexicon.garden/identity/did:plc:hd34khf6wifegm23c2u3cv2d), not the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:hd34khf6wifegm23c2u3cv2d/radio.4000.defs)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:hd34khf6wifegm23c2u3cv2d/radio.4000.defs/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:hd34khf6wifegm23c2u3cv2d/radio.4000.defs/analytics)

## #author (`radio.4000.defs#author`)

Type: object

The account a record belongs to.

### Properties

- `did` (string · did, required)
- `handle` (string · handle, required)

## #broadcastView (`radio.4000.defs#broadcastView`)

Type: object

### Properties

- `author` (ref, required)
  - Reference: `#author`
- `indexedAt` (string · datetime, required)
- `record` (unknown, required): The radio.4000.broadcast record.

## #chatMessageView (`radio.4000.defs#chatMessageView`)

Type: object

### Properties

- `author` (ref, required)
  - Reference: `#author`
- `cid` (string · cid, required)
- `indexedAt` (string · datetime, required)
- `record` (unknown, required): The radio.4000.chat.message record.
- `uri` (string · at-uri, required)

## #link (`radio.4000.defs#link`)

Type: object

A link to elsewhere, with an optional label.

### Properties

- `title` (string)
  - Constraints: maxLength: 640, maxGraphemes: 64
- `url` (string · uri, required)
  - Constraints: maxLength: 2048

## #radioView (`radio.4000.defs#radioView`)

Type: object

### Properties

- `did` (string · did, required)
- `handle` (string · handle, required)
- `image` (string · uri): URL of the radio's image blob on its PDS.
- `indexedAt` (string · datetime, required)
- `latestTrackAt` (string · datetime)
- `record` (unknown): The radio.4000.profile record, when the account has one.
- `trackCount` (integer, required)
  - Constraints: minimum: 0
- `tracksUpdatedAt` (string · datetime): When the radio's tracks last changed: an app can keep them and load them again only when this moves.

## #trackView (`radio.4000.defs#trackView`)

Type: object

### Properties

- `author` (ref, required)
  - Reference: `#author`
- `cid` (string · cid, required)
- `indexedAt` (string · datetime, required)
- `record` (unknown, required): The radio.4000.track record.
- `uri` (string · at-uri, required)

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "author": {
      "description": "The account a record belongs to.",
      "properties": {
        "did": {
          "format": "did",
          "type": "string"
        },
        "handle": {
          "format": "handle",
          "type": "string"
        }
      },
      "required": [
        "did",
        "handle"
      ],
      "type": "object"
    },
    "broadcastView": {
      "properties": {
        "author": {
          "ref": "#author",
          "type": "ref"
        },
        "indexedAt": {
          "format": "datetime",
          "type": "string"
        },
        "record": {
          "description": "The radio.4000.broadcast record.",
          "type": "unknown"
        }
      },
      "required": [
        "author",
        "record",
        "indexedAt"
      ],
      "type": "object"
    },
    "chatMessageView": {
      "properties": {
        "author": {
          "ref": "#author",
          "type": "ref"
        },
        "cid": {
          "format": "cid",
          "type": "string"
        },
        "indexedAt": {
          "format": "datetime",
          "type": "string"
        },
        "record": {
          "description": "The radio.4000.chat.message record.",
          "type": "unknown"
        },
        "uri": {
          "format": "at-uri",
          "type": "string"
        }
      },
      "required": [
        "uri",
        "cid",
        "author",
        "record",
        "indexedAt"
      ],
      "type": "object"
    },
    "link": {
      "description": "A link to elsewhere, with an optional label.",
      "properties": {
        "title": {
          "maxGraphemes": 64,
          "maxLength": 640,
          "type": "string"
        },
        "url": {
          "format": "uri",
          "maxLength": 2048,
          "type": "string"
        }
      },
      "required": [
        "url"
      ],
      "type": "object"
    },
    "radioView": {
      "properties": {
        "did": {
          "format": "did",
          "type": "string"
        },
        "handle": {
          "format": "handle",
          "type": "string"
        },
        "image": {
          "description": "URL of the radio's image blob on its PDS.",
          "format": "uri",
          "type": "string"
        },
        "indexedAt": {
          "format": "datetime",
          "type": "string"
        },
        "latestTrackAt": {
          "format": "datetime",
          "type": "string"
        },
        "record": {
          "description": "The radio.4000.profile record, when the account has one.",
          "type": "unknown"
        },
        "trackCount": {
          "minimum": 0,
          "type": "integer"
        },
        "tracksUpdatedAt": {
          "description": "When the radio's tracks last changed: an app can keep them and load them again only when this moves.",
          "format": "datetime",
          "type": "string"
        }
      },
      "required": [
        "did",
        "handle",
        "trackCount",
        "indexedAt"
      ],
      "type": "object"
    },
    "trackView": {
      "properties": {
        "author": {
          "ref": "#author",
          "type": "ref"
        },
        "cid": {
          "format": "cid",
          "type": "string"
        },
        "indexedAt": {
          "format": "datetime",
          "type": "string"
        },
        "record": {
          "description": "The radio.4000.track record.",
          "type": "unknown"
        },
        "uri": {
          "format": "at-uri",
          "type": "string"
        }
      },
      "required": [
        "uri",
        "cid",
        "author",
        "record",
        "indexedAt"
      ],
      "type": "object"
    }
  },
  "description": "Definitions shared by the records, and views of records served by the 4000.radio index. Each view carries the record as it is in its repo.",
  "id": "radio.4000.defs",
  "lexicon": 1
}
```
