HEre's my POST:
account_id 1231
limit 3
ordertype limit
quantity 1
symbol USDJPY
transaction_type buy
In my code, I have:
var account_id = req.param('account_id', null);
var symbol_pair = req.param('symbol', null);
var transaction_type = req.param('transaction_type', null);
var order_type = req.param('ordertype', null);
var amount = req.param('amount', null);
var limit = req.param('limit', null);
console.log(account_id + " | " + symbol_pair + " | " + transaction_type + " | " + order_type + " | " + amount + " | " + limit);return;
But for some reason ordertype
comes back market
. Any ideas what's going on?
make sure you have app.use(express.bodyParser());
and try with req.body.account_id
(and similar style for each one)
You are defining order_type and then trying to get it back with ordertype. Don't forget your: underscore!