UNPKG

ib

Version:

Interactive Brokers TWS (or IB Gateway) API client library for Node.js

18 lines (14 loc) 427 B
var assert = require('assert'); var _ = require('lodash'); module.exports = function (symbol, expiry, currency, exchange, multiplier) { assert(_.isString(symbol), 'Symbol must be a string.'); assert(_.isString(expiry), 'Expiry must be a string.'); return { secType: 'FUT', symbol: symbol, expiry: expiry, currency: currency || 'USD', exchange: exchange || 'ONE', multiplier: multiplier }; };