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

# serialize

> serialize — Kinetica Rust API

[gpudb\_api](https://docs.kinetica.com/content/api/rust/index.md)::<wbr />[avro\_schema\_builder](https://docs.kinetica.com/content/api/rust/avro_schema_builder/index.md)::<wbr />[option\_bool\_as\_int](https://docs.kinetica.com/content/api/rust/avro_schema_builder/option_bool_as_int/index.md)
[Source](https://github.com/kineticadb/kinetica-api-rust/blob/master/crates/gpudb-api/src/avro_schema_builder.rs#L102-L107)&#x20;

<pre>`pub fn serialize<S: Serializer>(    value: &Option<bool>,    serializer: S,) -> Result<S::Ok, S::Error>`</pre>

Writes `Some(true)` as 1, `Some(false)` as 0, and `None` as null.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.