swagger-jsdoc/GETTING-STARTED.md at master · Surnet/swagger-jsdoc

PHOTO EMBED

Tue Oct 20 2020 06:51:46 GMT+0000 (Coordinated Universal Time)

Saved by @duc.pt172483@gmail.com

/**
 * @swagger
 *
 * /login:
 *   post:
 *     description: Login to the application
 *     produces:
 *       - application/json
 *     parameters:
 *       - name: username
 *         description: Username to use for login.
 *         in: formData
 *         required: true
 *         type: string
 *       - name: password
 *         description: User's password.
 *         in: formData
 *         required: true
 *         type: string
 *     responses:
 *       200:
 *         description: login
 */
app.post('/login', (req, res) => {
  // Your implementation comes here ...
});
content_copyCOPY

https://github.com/Surnet/swagger-jsdoc/tree/master/docs