# gtv.fromBytes · Rell standard library · Chromia Docs (concept)

> pure static function fromBytes(bytes: byte_array ): gtv Deprecated (for removal): Use 'from_bytes' instead Decode a GTV from a byte array. Inverse of gtv.t

Source: https://docs.chromia.com/pages/rell-stdlib/-rell-system-library/root/gtv/from-bytes/

FUNCTION

# gtv.fromBytes

```signature
pure static function fromBytes(bytes: byte_array): gtv
```

**Deprecated** (for removal): Use 'from\_bytes' instead

Decode a GTV from a byte array.

Inverse of `gtv.to_bytes()`.

**Parameters**

* **bytes** — the byte array to decode

**Returns**

the decoded GTV

**Throws**

* `exception` — if the byte array does not encode a well-formed GTV; i.e. if a GTV cannot be decoded

Since 0.9.0

**Alias of** [gtv.from\_bytes](https://docs.chromia.com/pages/rell-stdlib/-rell-system-library/root/gtv/from_bytes/)

[View this page on docs.chromia.com](https://docs.chromia.com/pages/rell-stdlib/-rell%20-system%20-library/%5Broot%5D/gtv/from-bytes.html)Generated API reference, mirrored from the live docs
