> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# lz4decompress

> Распаковывает raw LZ4 block bytes через LZ4 block decompression и возвращает raw decompressed bytes как строку Lua.

<div className="real-function-page">
  ```lua theme={null}
  lz4decompress(data: string, originalSize?: number): string
  ```

  ## Алиасы

  * `crypt.lz4decompress`
  * `crypt.lz4.decompress`
  * `lz4.decompress`

  ## Аргументы

  <ParamField path={"data"} type={"string"} required>
    Raw compressed bytes, передаваемые в LZ4 block decompression.
  </ParamField>

  <ParamField path={"originalSize"} type={"number"}>
    Output buffer size, передаваемый как dstCapacity. Для вывода lz4compress передайте исходную несжатую длину в bytes; если аргумент пропущен, используется длина сжатого ввода.
  </ParamField>

  ## Возвраты

  <ResponseField name={"decompressed"} type={"string"}>
    Raw decompressed bytes, возвращаемые как строка Lua. Вывод может быть короче originalSize.
  </ResponseField>

  ## Пример

  Распакуйте LZ4 bytes, передав исходный несжатый размер.

  ```lua theme={null}
  local source = "Real Docs"
  local compressed = lz4compress(source)
  local decompressed = lz4decompress(compressed, #source)

  print(decompressed)
  print(decompressed == source)
  ```
</div>
