thread:
  author: A
changes:
  - id: A.1.1
    identity: A
    aclSnapshot:
      userStates:
        - identity: A
          encryptionKey: key.Enc.A
          encryptedReadKeys: [key.Read.1]
          permission: admin
    snapshot:
      text: "some text"
    aclChanges:
      - userAdd:
          identity: A
          permission: admin
          encryptionKey: key.Enc.A
          encryptedReadKeys: [key.Read.1]
    changes:
      - textAppend:
          text: "some text"
    readKey: key.Read.1
  - id: A.1.2
    identity: A
    aclChanges:
      - userInvite:
          acceptKey: key.Sign.Onetime1
          encryptionKey: key.Enc.Onetime1
          encryptedReadKeys: [key.Read.1]
          permissions: writer
          inviteId: A.1.2
    readKey: key.Read.1
  - id: A.1.3
    identity: A
    aclChanges:
      - userRemove:
          removedIdentity: B
          newReadKey: key.Read.2
          identitiesLeft: [A]
    readKey: key.Read.2
  - id: A.1.4
    identity: A
    changes:
      - textAppend:
          text: "first"
    readKey: key.Read.2
  - id: B.1.1
    identity: B
    aclChanges:
      - userJoin:
          identity: B
          encryptionKey: key.Enc.B
          acceptSignature: key.Sign.Onetime1
          inviteId: A.1.2
          encryptedReadKeys: [key.Read.1]
    readKey: key.Read.1
  - id: B.1.2
    identity: B
    changes:
      - textAppend:
          text: "second"
    readKey: key.Read.1
keys:
  Enc:
    - A
    - B
    - Onetime1
  Sign:
    - A
    - B
    - Onetime1
  Read:
    - 1
    - 2
graph:
  - id: A.1.1
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
  - id: A.1.2
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
    aclHeads: [A.1.1]
    treeHeads: [A.1.1]
  - id: B.1.1
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
    aclHeads: [A.1.2]
    treeHeads: [A.1.2]
  - id: B.1.2
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
    aclHeads: [B.1.1]
    treeHeads: [B.1.1]
  - id: A.1.3
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
    aclHeads: [B.1.1]
    treeHeads: [B.1.1]
  - id: A.1.4
    baseSnapshot: A.1.1
    aclSnapshot: A.1.1
    aclHeads: [A.1.3]
    treeHeads: [A.1.3]
orphans:
  - "A.1.4"
  - "B.1.2"
header:
  firstChangeId: A.1.1
  isWorkspace: false
