# ink.resenha.ebookKey

> One per account. Written once, by the first device that makes a key, so two devices can't each make their own.

- Kind: record
- Record key: literal:self
- Authority: resenha.ink
- Lexicon: 1
- Published by [resenha.ink](https://lexicon.garden/identity/did:plc:v7itjf4h3sb5zuegiiskctqb), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:v7itjf4h3sb5zuegiiskctqb/ink.resenha.ebookKey)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:v7itjf4h3sb5zuegiiskctqb/ink.resenha.ebookKey/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:v7itjf4h3sb5zuegiiskctqb/ink.resenha.ebookKey/analytics)

## Record (`ink.resenha.ebookKey`)

Type: record · key literal:self

### Properties

- `createdAt` (string · datetime, required)
- `keyId` (string, required): A fingerprint of the key, derived from it, that can't be used to find the key.
  - Constraints: maxLength: 64
- `recovery` (bytes): The key, encrypted with a recovery key that only the reader holds. Absent until the reader saves a recovery key.
  - Constraints: maxLength: 256

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "One per account. Written once, by the first device that makes a key, so two devices can't each make their own.",
      "key": "literal:self",
      "record": {
        "properties": {
          "createdAt": {
            "format": "datetime",
            "type": "string"
          },
          "keyId": {
            "description": "A fingerprint of the key, derived from it, that can't be used to find the key.",
            "maxLength": 64,
            "type": "string"
          },
          "recovery": {
            "description": "The key, encrypted with a recovery key that only the reader holds. Absent until the reader saves a recovery key.",
            "maxLength": 256,
            "type": "bytes"
          }
        },
        "required": [
          "keyId",
          "createdAt"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "description": "Which key encrypts the account's ink.resenha.privateEbook files. The key itself stays on the reader's devices; this record only names it, and keeps a copy locked with a recovery key when the reader saved one.",
  "id": "ink.resenha.ebookKey",
  "lexicon": 1
}
```
