async Encrypt({libraryId, objectId, writeToken, chunk}) {
    const conk = await this.EncryptionConk({libraryId, objectId, writeToken});
    const data = await Crypto.Encrypt(conk, chunk);

    // Convert to ArrayBuffer
    return data.buffer.slice(data.byteOffset, data.byteOffset + data.byteLength);
  }
/**
   * Encrypt the specified chunk for the specified object or draft
   *
   * @methodGroup Encryption
   *
   * @namedParams
   * @param {string} libraryId - ID of the library
   * @param {string} objectId - ID of the object
   * @param {string} writeToken - Write token of the content object draft
   * @param {Promise<(ArrayBuffer | Buffer)>} chunk - The data to encrypt
   *
   * @return {Promise<ArrayBuffer>}
   */
Encrypt the specified chunk for the specified object or draft
@methodGroup Encryption



@return {Promise}
Encrypt the specified chunk for the specified object or draft @methodGroup Encryption @return { Promise }
async Encrypt({libraryId, objectId, writeToken, chunk}) {
    const conk = await this.EncryptionConk({libraryId, objectId, writeToken});
    const data = await Crypto.Encrypt(conk, chunk);
    return data.buffer.slice(data.byteOffset, data.byteOffset + data.byteLength);
  }
async Encrypt ( { libraryId , objectId , writeToken , chunk } ) { const conk = await this . EncryptionConk ( { libraryId , objectId , writeToken } ) ; const data = await Crypto . Encrypt ( conk , chunk ) ; return data . buffer . slice ( data . byteOffset , data . byteOffset + data . byteLength ) ; }
Encrypt the specified chunk for the specified object or draft
 @methodGroup Encryption
Encrypt the specified chunk for the specified object or draft @methodGroup Encryption
// Convert to ArrayBuffer