Insert Document
POST {{URL_ENDPOINT}}/action/insertOne
Using the /insertOne
endpoint, you can add a document to a collection. Use the document
property in the request body to specify the document that should be created.
Request Body
{"dataSource"=>"{{DATA_SOURCE}}", "database"=>"{{DATABASE}}", "collection"=>"{{COLLECTION}}", "document"=>{"name"=>"John Sample", "age"=>42}}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Access-Control-Request-Headers | string | ||
api-key | string |