docs: function getAttachment(binaryKey) {
      // console.log('Adding binary attachment', binaryKey);
      const index = attachments.findIndex((att) => (att.key === binaryKey));
      if (index !== -1) {
        const result = attachments[index].data;
        // TODO if attachment is sent mulitple times, we shouldn't remove it yet.
        attachments.splice(index, 1);
        return result;
      }
      console.error('Binary attachment key found without matching attachment');
      return null;
    }