sbx-load-handler
v0.1.0
Published
sbx-load-handler
Downloads
376
Readme
sbx-server-service
sbx-socket-gateway module
Requirements
- node >= 10
- sbx >=0.9.1
Peer dependencies
"geoip-lite": "^1.4.2",
"jsonwebtoken": "^8.5.1",
"lodash": "^4.17.20",
"sbx-rest-gateway": "0.0.4",
"socket.io": "^2.3.0"
Installation
$ npm install sbx-socket-gateway
Use package:
const { RestService } = require('sbx-socket-gateway');
//Mixin to service
{
mixins: [
SocketService(broker, {
events: {
'quote.tick.:symbol': {
name: 'Quotes stream',
// access: ['user'],
params: {
symbol: {type: 'string', optional: true},
bid: {type: 'number', optional: true},
ask: {type: 'number', optional: false},
volume: {type: 'number', optional: false}
},
room: 'quote.tick'
},
'quote.candle.:symbol': {
name: 'Candles stream',
params: {
symbol: {type: 'string', optional: true},
data: {type: 'array', optional: true}
},
room: 'quote.candle'
}
}
})
]
}
Developers
- Viktor Fischer
FAQ
License
Copyright (c) 2020 Sobix Group LLC