@@ -96,7 +96,7 @@ import { HIDDEN_COMMANDS } from '@mongosh/history';
9696import PlanCache from './plan-cache' ;
9797import ChangeStreamCursor from './change-stream-cursor' ;
9898import { ShellApiErrors } from './error-codes' ;
99- import type { MQLQuery , MQLPipeline } from './mql-types' ;
99+ import type { MQLDocument , MQLQuery , MQLPipeline } from './mql-types' ;
100100
101101export type CollectionWithSchema <
102102 M extends GenericServerSideSchema = GenericServerSideSchema ,
@@ -758,7 +758,7 @@ export class Collection<
758758 @serverVersions ( [ ServerVersions . earliest , '3.6.0' ] )
759759 @apiVersions ( [ 1 ] )
760760 async insert (
761- docs : Document | Document [ ] ,
761+ docs : MQLDocument | MQLDocument [ ] ,
762762 options : BulkWriteOptions = { }
763763 ) : Promise < InsertManyResult > {
764764 await this . _instanceState . printDeprecationWarning (
@@ -802,7 +802,7 @@ export class Collection<
802802 @serverVersions ( [ '3.2.0' , ServerVersions . latest ] )
803803 @apiVersions ( [ 1 ] )
804804 async insertMany (
805- docs : Document [ ] ,
805+ docs : MQLDocument [ ] ,
806806 options : BulkWriteOptions = { }
807807 ) : Promise < InsertManyResult > {
808808 assertArgsDefinedType ( [ docs ] , [ true ] , 'Collection.insertMany' ) ;
@@ -838,7 +838,7 @@ export class Collection<
838838 @serverVersions ( [ '3.2.0' , ServerVersions . latest ] )
839839 @apiVersions ( [ 1 ] )
840840 async insertOne (
841- doc : Document ,
841+ doc : MQLDocument ,
842842 options : InsertOneOptions = { }
843843 ) : Promise < InsertOneResult > {
844844 assertArgsDefinedType ( [ doc ] , [ true ] , 'Collection.insertOne' ) ;
0 commit comments