v12.0.0 - initial commit
This commit is contained in:
commit
e2c49ea43c
1145 changed files with 97211 additions and 0 deletions
28
packages/server/lib/plugins/exchange/binanceus.js
Normal file
28
packages/server/lib/plugins/exchange/binanceus.js
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
const { COINS } = require('@lamassu/coins')
|
||||
const _ = require('lodash/fp')
|
||||
|
||||
const { ORDER_TYPES } = require('./consts')
|
||||
|
||||
const ORDER_TYPE = ORDER_TYPES.MARKET
|
||||
const { BTC, BCH, DASH, ETH, LTC, ZEC, USDT, USDT_TRON, LN, USDC } = COINS
|
||||
const CRYPTO = [BTC, ETH, LTC, DASH, ZEC, BCH, USDT, USDT_TRON, LN, USDC]
|
||||
const FIAT = ['USD']
|
||||
const DEFAULT_FIAT_MARKET = 'USD'
|
||||
const REQUIRED_CONFIG_FIELDS = ['apiKey', 'privateKey', 'currencyMarket']
|
||||
|
||||
const loadConfig = account => {
|
||||
const mapper = {
|
||||
privateKey: 'secret',
|
||||
}
|
||||
const mapped = _.mapKeys(key => (mapper[key] ? mapper[key] : key))(account)
|
||||
return { ...mapped, timeout: 3000 }
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
loadConfig,
|
||||
DEFAULT_FIAT_MARKET,
|
||||
REQUIRED_CONFIG_FIELDS,
|
||||
CRYPTO,
|
||||
FIAT,
|
||||
ORDER_TYPE,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue