javascript – Error: Bad Request

app.get ("/ contacts / loadInitialData", (req, res) => {
    var newContacts = [{name:"jose",phone:"12345",email:""},

     contacts.find ({}, {projection: {_id: 0}}). toArray ((err, contactsArray) => {
     if (err) {
         console.log (err);
     } else {
         var i;
         for (i = 0; i <newContacts.length; i ++) {
             contactsArray.push (newContacts[i]);
         res.sendStatus (200);


In this code what I try is to add new Contacts to the contacts that already exist, the problem that when I give Run to execute the code and I put in the url the / contacts / loadInitialData tells me that Bad Request. I understand that it may be a problem with the URL but I do not know, I do not see the fault.