ChangeStreamDocumentKey | mongodb (original) (raw)

Interface ChangeStreamDocumentKey

interface ChangeStreamDocumentKey<TSchema> {
documentKey: {
_id: InferIdType<TSchema>;
[shardKey: string]: any;
};
}

Type Parameters

Hierarchy (view full)

Index

Properties

documentKey

Properties

documentKey

documentKey: {
_id: InferIdType<TSchema>;
[shardKey: string]: any;
}

For unsharded collections this contains a single field _id. For sharded collections, this will contain all the components of the shard key