Skip to content

MongoDB ​

The MongoDB block is another storage type block. It's a fully cloud managed MongoDB instance. This article will explain some relevant implementation details in the Codedraw core.

Authentication ​

MongoDB Atlas supports different kinds of authentication. Currently the only implemented authentications service in Codedraw are:

Opening a connection ​

The InstallMongoDBGateway middleware will perform the authentication and open a connection to your database instance. The object is saved as a context variable and will be available across the app via:

typescript
const dataGateway = context.get('dataGateway')!

New Authentication methods and integration features will be released with updated SDK versions.

When editing a MongoDB block you can set:

  • the name mostly an identifier within the Codedraw board.
  • the description.
  • the DB Name the actual name of your db. This will be set to your configuration file.