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

# MongoDB Atlas collection observations and changes

> Read one collection from an Atlas replica set through MongoDB wire protocol and X.509.

Follow the [MongoDB Documents mount](https://docs.bijection.com/integrations/native-mongodb.md). Bind
`mongodbCollection(endpoint, credential, data)` to a fixed Atlas
replica-set member's DNS host and port from the standard connection
details. Use an Atlas cluster that offers X.509 database authentication
and allow the deployment's egress addresses. Seal the Atlas database
user subject and the client PEM chain and key, along with the database
and collection. Bind the receiver and the mount under the same [label](https://docs.bijection.com/integrations/native-connectors.md#installer-bound-labels).

Atlas uses the MongoDB wire protocol. This profile uses one direct
TLS socket, `MONGODB-X509` on `$external`, and the collection UUID from
`listCollections`. Atlas's SRV discovery, connection strings,
cluster routing, IAM authentication and Atlas Data API are outside
this profile. Select one reachable replica-set member that can serve
the mode. The operator reviews an endpoint change following failover.

* **Observations** use `{ selection: { mode: "mongo" } }`. Grant
  `find` on the collection and `listCollections` on the database.
  Bijection commits one ObjectId-keyed Extended JSON document with
  its exclusive position and restarts the sweep on an empty page.
  Missing documents stay published.
* **Changes** use `{ selection: { mode: "mongo-changes" } }`. Enable
  `changeStreamPreAndPostImages`, and grant `changeStream` and
  `find` on the collection. Bijection starts from the stream head,
  retains the opaque BSON resume token and applies one independently
  committed event per answer. Deletes apply by ObjectId; updates
  require exact post-images. Transactions, lost history and collection
  identity changes stop advancement.

Both modes allow up to 36 KiB of document JSON and 48 KiB of encoded
answer data. Adjust the provider's oplog and post-image retention
to cover the change reader's expected downtime.

[Atlas database users and X.509](https://www.mongodb.com/docs/atlas/security-add-mongodb-users/) ·
[MongoDB change streams](https://www.mongodb.com/docs/manual/changestreams/)


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