---
name: "bson_oid_to_string"
section: "3"
platform: "linux"
package: "libbson-doc"
version: "1.30.4-1+deb13u3"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/bson_oid_to_string"
---

# bson\_oid\_to\_string(3)

## SYNOPSIS

```
void
bson_oid_to_string (const bson_oid_t *oid, char str[25]);
```

## PARAMETERS

- •

  **oid**: A *bson\_oid\_t*.

- •

  **str**: A location for the resulting string.

## DESCRIPTION

Converts **oid** into a hex encoded string.

## AUTHOR

MongoDB, Inc

## COPYRIGHT

2009-present, MongoDB, Inc.
