`express` app - not able to test the `post` request using `postman`
<p>I have created a small <code>express</code> app. I just trying to test the <code>post</code> method. But it's not working at all. according to me all are fine. But I couln't figure out the issue. any one help me here please?</p>

<p>my server.js file :</p>

<pre><code>var express = require('express');
var bodyParser = require('body-parser');
var Post = require('./models/post');

var app = express();
app.use(bodyParser.urlencoded({
    extended: true
}));

app.use(bodyParser.json());

app.get('/api/posts', function( req, res) {
    res.json([
        {
            username:"dickeyxxx",
            body : "node rocksxx"
        }
    ])
});


app.post('/api/posts', function( req, res, next) {

    var post = new Post({
        username:req.body.username,
        body:req.body.body
    })

    post.save(function(err, post){
        if(err) { return next }
            res.json(201,post);
    })

})



app.listen(5000, function(){
    console.log('Server Listening on', 5000);
})
</code></pre>

<p>my post.js :</p>

<pre><code>var db = require('../db');
var Post = db.model('Post', {
    username:{type:String, required:true},
    body:{type:String,required:true},
    date:{type:Date, required:true,default:Date.now}
});

module.exports = Post;
</code></pre>

<p>my db.js:</p>

<pre><code>var mongoose = require('mongoose');
mongoose.connect('mongodb://localhost/social', function(){
    console.log( 'mongoose connected' ); //i am getting consoled
});

module.exports = mongoose;
</code></pre>

<p>my try with postman :</p>

<p><a href="https://i.stack.imgur.com/yY9IC.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yY9IC.jpg" alt="postman screen shot"></a></p>

<p>any one help me here?</p>