nodejs PUT请求错误

error with nodejs PUT request

我在尝试使用节点 js 执行以下 PUT 请求时遇到错误。

var request = require('request');
request('http://1xx.xxx.xxx.xxx:8080/maintable/http%3A%2F%2Ftesturl.com
  %2F', 
method: 'PUT', 
json:{"Row":[{"key":"aHR0cHM6Ly9tYWt6ZW9uLndvcmRwcmVzcy5jb20v", "Cell": 
 [{"column":"YmxvZ3NfZGF0YTp1cmw=", "$":    
 "aHR0cHM6Ly9tYWt6ZW9uLndvcmRwcmVzcy5jb20v"},
 {"column":"YmxvZ3NfZGF0YTppbnNlcnREYXRl", "$": "MTQ5Njg3ODk1OA=="},    
 {"column":"YmxvZ3NfZGF0YTpzdGF0dXM=", "$": "QWN0aXZl"}], 
}]}, 
function (error, response, body) {
    console.log('error:', error);
    console.log('statusCode:', response && response.statusCode);
    console.log('body:', body);
}
);

错误:

 method: 'PUT',
    ^^^^^^
 SyntaxError: missing ) after argument list
 at createScript (vm.js:56:10)
 at Object.runInThisContext (vm.js:97:10)
 at Module._compile (module.js:542:28)
 at Object.Module._extensions..js (module.js:579:10)
 at Module.load (module.js:487:32)
 at tryModuleLoad (module.js:446:12)
 at Function.Module._load (module.js:438:3)
  at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:389:7)
at startup (bootstrap_node.js:149:9)

有没有人注意到错误在哪里?

请求函数的第一个参数缺少“{”

var request = require('request');
request({
    uri: 'http://1xx.xxx.xxx.xxx:8080/maintable/http%3A%2F%2Ftesturl.com', 
    method: 'PUT', 
    json:{
        "Row":[
            {
                "key":"aHR0cHM6Ly9tYWt6ZW9uLndvcmRwcmVzcy5jb20v", 
                "Cell": [
                    {
                        "column":"YmxvZ3NfZGF0YTp1cmw=", 
                        "$": "aHR0cHM6Ly9tYWt6ZW9uLndvcmRwcmVzcy5jb20v"
                    },
                    {
                        "column":"YmxvZ3NfZGF0YTppbnNlcnREYXRl", 
                        "$": "MTQ5Njg3ODk1OA=="
                    },    
                    {
                        "column":"YmxvZ3NfZGF0YTpzdGF0dXM=", 
                        "$": "QWN0aXZl"
                    }
                ], 
            }
        ]
    }
}, 
function (error, response, body) {
    console.log('error:', error);
    console.log('statusCode:', response && response.statusCode);
    console.log('body:', body);
});