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

# mongoc\_auto\_encryption\_opts\_set\_key\_vault\_namespace(3)

## SYNOPSIS

```
void
mongoc_auto_encryption_opts_set_keyvault_namespace (
   mongoc_auto_encryption_opts_t *opts, const char *db, const char *coll);
```

Set the database and collection name of the key vault. The key vault is the specially designated collection containing encrypted data keys for *In-Use Encryption*.

## PARAMETERS

- •

  **opts**: The *mongoc\_auto\_encryption\_opts\_t*

- •

  **db**: A **const char \*** representing the database name of the key vault collection.

- •

  **coll**: A **const char \*** representing the collection name of the key vault collection.

**SEE ALSO:**

```
mongoc_client_enable_auto_encryption()
```

```
In-Use Encryption
```

## AUTHOR

MongoDB, Inc

## COPYRIGHT

2009-present, MongoDB, Inc.
