HTTP Driver
POST /:object/db/bulk
Performs a bulk operation, consisting of 1 or more driver operations. Bulk operations may be nested. For more information and examples, see Bulk Operation in the scripting section.
Path Params
object
{ String } The object name.
Body Params
ops
{ Object[] } An array of bulk operations.operation
{ String } The operation name. Can be any one of the driver operations (bulk, readOne, cursor, etc.).object
{ String = undefined } Sets a new object target for the operation.name
{ String = undefined } Wrapped responses will be renamed to this from the operation name.halt
{Boolean = true } If false, an error will not halt the current bulk operation; Errors will instead be pushed to the output stream.output
{Boolean = true } If false, results are not pushed to the output stream.wrap
{ Boolean = true } If false, theoperationResult
wrapper is removed from output documents.*
{ * } Other individual operation options should be added to the operation object (ie.match
,where
,pipeline
,limit
, etc.)
Header Params
Accept
{ String = application-json } The client can requestapplication/x-ndjson
to stream newline-delimited JSON documents.
Response
{ List } A list result.
data
{ OperationResult[] } An array of wrapped results._id
{ ObjectID } The operation result identifier.data
{ * } The wrapped operation result.object
{ String } The object name,operationResult
.path
{ String } The operation path in the formoperationName[operationIndex][cursorPosition]
.timestamp
{ Number } The timestamp the operation result ws created, in milliseconds.
hasMore
{ Boolean }true
when more document exists past the cursor.object
{ String }"list"
.
POST /:object/db/count
Count object instances.
Path Params
object
{ String } The object name.
Body Params
accessLevel
{ String|Number } If set, limits the count to those documents where the caller has at leastaccessLevel
.limit
{ Number } If set, limits the maximum count.locale
{ String } Set the locale for the operation. This affect localized string matches.maxTimeMS
{ Number = 10000 } The maximum number of milliseconds the query is allowed to process before an initial cursor is opened.skip
{ Number } Skipsskip
documents.where
{ Object } A query match filter.
Response
{ Result } A result object.
data
{ Number } A document count.object
{ String }result
.
POST /:object/db/cursor
Stream a query or aggregation cursor.
Path Params
object
{ String } The object name.
Header Params
Accept
{ String = application-json } The client can requestapplication/x-ndjson
to stream newline-delimited JSON documents.
Body Params
accessLevel
{ Number }expand
{ String[] }group
{ Object }include
{ String[] }limit
{ Number }locale
{ String }map
{ String }maxTimeMS
{ Number = 10000 }paths
{ String[] }passive
{ Boolean = false }pipeline
{ Object[] }prefix
{ String } A path to use when retrieving a cursor to a List within a readThrough path.skip
{ Number }sort
{ Object }where
{ Object }
Response
{ List } A list result.
data
{ *[] } Array of results.hasMore
{ Boolean }true
when more document exists past the cursor.object
{ String }list
.
Last updated