# email.atmos.calendar.revision

> ALPHA. Append-only accepted Calendar event revision. Host validates identity, permissions and causal history before accepting records.

- Kind: record
- Record key: any
- Authority: calendar.atmos.email
- Lexicon: 1
- Published by [comail.at](https://lexicon.garden/identity/did:plc:yu6rmwoemqfnmsdkljyvmuhg), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:yu6rmwoemqfnmsdkljyvmuhg/email.atmos.calendar.revision)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:yu6rmwoemqfnmsdkljyvmuhg/email.atmos.calendar.revision/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:yu6rmwoemqfnmsdkljyvmuhg/email.atmos.calendar.revision/analytics)

## Record (`email.atmos.calendar.revision`)

Type: record · key any

### Properties

- `payload` (ref, required)
  - Reference: `#payload`

## #event (`email.atmos.calendar.revision#event`)

Type: object

### Properties

- `description` (string, required)
  - Constraints: maxLength: 16384
- `duration` (string, required): ISO 8601 duration; zero is allowed.
- `id` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `participants` (array)
  - Constraints: maxLength: 100
  - `items` (ref)
    - Reference: `#participant`
- `recurrenceOverrides` (unknown): Map from local recurrence timestamps to partial event overrides. Validated by Host.
- `recurrenceRules` (array)
  - Constraints: minLength: 1, maxLength: 1
  - `items` (ref)
    - Reference: `#recurrenceRule`
- `showWithoutTime` (boolean, required)
- `start` (string, required): Local date and time, YYYY-MM-DDTHH:mm:ss, interpreted in timeZone.
- `status` (string, required)
  - Constraints: knownValues: confirmed | cancelled
- `timeZone` (string, required)
- `title` (string, required)
  - Constraints: minLength: 1, maxLength: 4096
- `uid` (string, required)
  - Constraints: minLength: 1, maxLength: 255

## #eventPatch (`email.atmos.calendar.revision#eventPatch`)

Type: object

### Properties

- `description` (string)
  - Constraints: maxLength: 16384
- `duration` (string): ISO 8601 duration; zero is allowed.
- `participants` (array)
  - Constraints: maxLength: 100
  - `items` (ref)
    - Reference: `#participant`
- `recurrenceOverrides` (unknown): Map from local recurrence timestamps to partial event overrides. Validated by Host.
- `recurrenceRules` (array)
  - Constraints: minLength: 1, maxLength: 1
  - `items` (ref)
    - Reference: `#recurrenceRule`
- `showWithoutTime` (boolean)
- `start` (string): Local date and time, YYYY-MM-DDTHH:mm:ss, interpreted in timeZone.
- `status` (string)
  - Constraints: knownValues: confirmed | cancelled
- `timeZone` (string)
- `title` (string)
  - Constraints: minLength: 1, maxLength: 4096

## #participant (`email.atmos.calendar.revision#participant`)

Type: object

### Properties

- `did` (string · did, required)
- `status` (string, required)
  - Constraints: knownValues: accepted | declined | tentative

## #payload (`email.atmos.calendar.revision#payload`)

Type: object

### Properties

- `accepted` (array, required)
  - Constraints: maxLength: 1
  - `items` (ref)
    - Reference: `#proposal`
- `committedAt` (string · datetime)
- `event` (ref, required)
  - Reference: `#event`
- `id` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `parent` (string)
  - Constraints: minLength: 1, maxLength: 256, nullable
- `policy` (string, required)
  - Constraints: minLength: 1, maxLength: 256

## #proposal (`email.atmos.calendar.revision#proposal`)

Type: object

### Properties

- `author` (string · did, required)
- `base` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `eventId` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `id` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `patch` (ref, required)
  - Reference: `#eventPatch`
- `policy` (string, required)
  - Constraints: minLength: 1, maxLength: 256
- `recurrenceId` (string)

## #recurrenceRule (`email.atmos.calendar.revision#recurrenceRule`)

Type: object

### Properties

- `count` (integer, required)
  - Constraints: minimum: 1, maximum: 1000
- `frequency` (string, required)
  - Constraints: knownValues: daily | weekly
- `interval` (integer)
  - Constraints: minimum: 1, maximum: 52

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "event": {
      "properties": {
        "description": {
          "maxLength": 16384,
          "type": "string"
        },
        "duration": {
          "description": "ISO 8601 duration; zero is allowed.",
          "type": "string"
        },
        "id": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "participants": {
          "items": {
            "ref": "#participant",
            "type": "ref"
          },
          "maxLength": 100,
          "type": "array"
        },
        "recurrenceOverrides": {
          "description": "Map from local recurrence timestamps to partial event overrides. Validated by Host.",
          "type": "unknown"
        },
        "recurrenceRules": {
          "items": {
            "ref": "#recurrenceRule",
            "type": "ref"
          },
          "maxLength": 1,
          "minLength": 1,
          "type": "array"
        },
        "showWithoutTime": {
          "type": "boolean"
        },
        "start": {
          "description": "Local date and time, YYYY-MM-DDTHH:mm:ss, interpreted in timeZone.",
          "type": "string"
        },
        "status": {
          "knownValues": [
            "confirmed",
            "cancelled"
          ],
          "type": "string"
        },
        "timeZone": {
          "type": "string"
        },
        "title": {
          "maxLength": 4096,
          "minLength": 1,
          "type": "string"
        },
        "uid": {
          "maxLength": 255,
          "minLength": 1,
          "type": "string"
        }
      },
      "required": [
        "id",
        "uid",
        "title",
        "description",
        "start",
        "timeZone",
        "duration",
        "showWithoutTime",
        "status"
      ],
      "type": "object"
    },
    "eventPatch": {
      "properties": {
        "description": {
          "maxLength": 16384,
          "type": "string"
        },
        "duration": {
          "description": "ISO 8601 duration; zero is allowed.",
          "type": "string"
        },
        "participants": {
          "items": {
            "ref": "#participant",
            "type": "ref"
          },
          "maxLength": 100,
          "type": "array"
        },
        "recurrenceOverrides": {
          "description": "Map from local recurrence timestamps to partial event overrides. Validated by Host.",
          "type": "unknown"
        },
        "recurrenceRules": {
          "items": {
            "ref": "#recurrenceRule",
            "type": "ref"
          },
          "maxLength": 1,
          "minLength": 1,
          "type": "array"
        },
        "showWithoutTime": {
          "type": "boolean"
        },
        "start": {
          "description": "Local date and time, YYYY-MM-DDTHH:mm:ss, interpreted in timeZone.",
          "type": "string"
        },
        "status": {
          "knownValues": [
            "confirmed",
            "cancelled"
          ],
          "type": "string"
        },
        "timeZone": {
          "type": "string"
        },
        "title": {
          "maxLength": 4096,
          "minLength": 1,
          "type": "string"
        }
      },
      "required": [],
      "type": "object"
    },
    "main": {
      "description": "ALPHA. Append-only accepted Calendar event revision. Host validates identity, permissions and causal history before accepting records.",
      "key": "any",
      "record": {
        "properties": {
          "payload": {
            "ref": "#payload",
            "type": "ref"
          }
        },
        "required": [
          "payload"
        ],
        "type": "object"
      },
      "type": "record"
    },
    "participant": {
      "properties": {
        "did": {
          "format": "did",
          "type": "string"
        },
        "status": {
          "knownValues": [
            "accepted",
            "declined",
            "tentative"
          ],
          "type": "string"
        }
      },
      "required": [
        "did",
        "status"
      ],
      "type": "object"
    },
    "payload": {
      "nullable": [
        "parent"
      ],
      "properties": {
        "accepted": {
          "items": {
            "ref": "#proposal",
            "type": "ref"
          },
          "maxLength": 1,
          "type": "array"
        },
        "committedAt": {
          "format": "datetime",
          "type": "string"
        },
        "event": {
          "ref": "#event",
          "type": "ref"
        },
        "id": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "parent": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "policy": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        }
      },
      "required": [
        "id",
        "policy",
        "accepted",
        "event"
      ],
      "type": "object"
    },
    "proposal": {
      "properties": {
        "author": {
          "format": "did",
          "type": "string"
        },
        "base": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "eventId": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "id": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "patch": {
          "ref": "#eventPatch",
          "type": "ref"
        },
        "policy": {
          "maxLength": 256,
          "minLength": 1,
          "type": "string"
        },
        "recurrenceId": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "eventId",
        "base",
        "policy",
        "patch",
        "author"
      ],
      "type": "object"
    },
    "recurrenceRule": {
      "properties": {
        "count": {
          "maximum": 1000,
          "minimum": 1,
          "type": "integer"
        },
        "frequency": {
          "knownValues": [
            "daily",
            "weekly"
          ],
          "type": "string"
        },
        "interval": {
          "maximum": 52,
          "minimum": 1,
          "type": "integer"
        }
      },
      "required": [
        "frequency",
        "count"
      ],
      "type": "object"
    }
  },
  "id": "email.atmos.calendar.revision",
  "lexicon": 1
}
```
