How to create an https endpoint that can store files using GridFS

Hi. Hope someone can help me on this. I am trying to create a https endpoint in Atlas that can store files using GridFS.
Found out that node.js driver is not supported.

Hi :wave: @shan,

Welcome to the MongoDB Community forums :sparkles:

Please refer to the MongoDB Documentation to read more about GridFS + Node.js: https://www.mongodb.com/docs/drivers/node/current/fundamentals/gridfs/#std-label-gridfs-create-bucket.

Moreover, please share the specific requirements and what you specifically mean when you say “https endpoint.”

Best regards,
Kushagra

Hey @shan,

Though MongoDB’s drivers do support file storage directly within the database using GridFS, typically we’d recommend storing files somewhere like S3 and storing the associated metadata in MongoDB.

Is there a particular use case that you’re exploring? What types of files are you storing and are you looking to interact with them beyond just basic “storage and retrieval”?

If you can share further insight as to your use case it would help us guide you more effectively :slight_smile:

MongoDB Altas can provide the REST API can allow to interact with the GridFS. You can use HTTPS to upload and download the file in GridFS.

Hi @john_sam, can you please provide links to the appropriate documentation?

My use case is to store data for use in simulation. Example will be the OD matrix which size can be a few hundred mb in cvs format.
If there are better ways to store the data, do advice.

The https endpoint is created in Atlas. Atlas supports installing node.js modules but for gridfs module, its not able to install it’s dependencies without issue.