I am trying to insert data into MongoLab using
if (Meteor.is_server) {
Meteor.startup(function () {
var result = Meteor.http.call("POST", "url",
{params:{"name" : "def"},headers:{"content-type":"application/json"}}, function (error,result) {
console.log(result);
});
});
}
I get a
data error : {message: 'Could not parse JSON, please double check the syntax and encoding: \ nname = def \ n ^'}
source
share