PiedTeam / DreameCloneTraining-BE-Project

0 stars 0 forks source link

DreameCloneTraining-BE-Project

Require to install

yarn add multer body-parser xlsx
yarn add @types/multer -D
{
  "fieldname": "myFile",
  "originalname": "demo.txt",
  "encoding": "7bit",
  "mimetype": "text/plain",
  "destination": "./uploads",
  "filename": "myFile-1712912837970",
  "path": "uploads/myFile-1712912837970",
  "size": 7
}
description: validate file format
method: POST
path: /file/upload
body{
  form-data: {
    myFile: file
  }
}

In this section, i've created a file upload API with the following features: