---
name: "mongoc_client_session_get_operation_time"
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_client_session_get_operation_time"
---

# mongoc\_client\_session\_get\_operation\_time(3)

## SYNOPSIS

```
void
mongoc_client_session_get_operation_time (const mongoc_client_session_t *session,
                                          uint32_t *timestamp,
                                          uint32_t *increment);
```

Get the session's operationTime, expressed as a BSON Timestamp with timestamp and increment components. If the session has not been used for any operations, the timestamp and increment are 0.

## PARAMETERS

- •

  **session**: A *mongoc\_client\_session\_t*.

- •

  **timestamp**: A pointer to a **uint32\_t** to receive the timestamp component.

- •

  **increment**: A pointer to a **uint32\_t** to receive the increment component.

## AUTHOR

MongoDB, Inc

## COPYRIGHT

2009-present, MongoDB, Inc.
