Docs Menu
Docs Home
/ /
Atlas App Services
/

Edge Server MongoDB API Support

On this page

  • CRUD APIs
  • Read
  • Insert
  • Update
  • Delete

Atlas Edge Server natively implements a subset of the MongoDB Wire Protocol, which allows you to access your Atlas data on the Edge using standard MongoDB drivers and tools.

Clients use a specialized MongoDB URI connection string to connect and send requests. For more information about how to connect to the Edge Server using a MongoDB connection string, refer to Connect to the Edge Server with MongoDB Drivers and Tools.

Edge Server currently supports a subset of the MongoDB APIs over the Wire Protocol.

Edge Server currently supports using these MongoDB CRUD APIs over the Wire Protocol.

For examples of using these commands, refer to the documentation for the Driver or tool you're using to execute these commands.

Read operations take a query filter and find all documents in a collection that match the filter.

  • You can find a single document using the collection.findOne() method.

  • You can find multiple documents using the collection.find() method.

Insert operations take one or more documents and add them to a MongoDB collection.

  • You can insert a document or documents into a collection using the collection.insert() method.

  • You can insert a single document using the collection.insertOne() method.

  • You can insert multiple documents at the same time using the collection.insertMany() method.

Update operations find existing documents in a MongoDB collection and modify their data. You use standard MongoDB query syntax to specify which documents to update and update operators to describe the changes to apply to matching documents.

  • You can update a document or documents in a collection using the collection.update() method.

  • You can update a single document using the collection.updateOne() method.

  • You can update multiple documents in a collection using the collection.updateMany() method.

  • You can find and update one or more documents in a collection using the collection.findAndModify() method. This action allows you to atomically find, modify, and return one or more documents with the same command. This avoids the risk of other update operations changing the documents between separate find and update operations.

Note

Edge Server does not currently support upsert.

Delete operations find existing documents in a MongoDB collection and remove them. You use standard MongoDB query syntax to specify which documents to delete.

  • You can delete a single document from a collection using the collection.deleteOne() method.

  • You can delete multiple items from a collection using the collection.deleteMany() method.

← Connect to Edge Server