0.0.5 • Published 6 years ago

slushpool-stratum-proxy-interface v0.0.5

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

Slushpool Stratum Proxy Interface

npm package

Requeriment

To use the interface it will be necessary to install stratum-mining-proxy on a server

stratum-mining-proxy - https://github.com/slush0/stratum-mining-proxy

Interface use

const slushpoolProxy = require('slushpool-stratum-proxy-interface');

var client = slushpoolProxy({
    server: "yourproxyip",
    port: 3333,
    portGetWork: 8332,
    user: "andrehrf.1",
    pass: "x",
    debug: true,
    onConnect: () => console.log('Connected to server'),
    onClose: () => console.log('Connection closed'),
    onError: (error) => console.log('Error', error.message),
    onNewMiningWork: (newWork) => console.log('[New Work]', newWork),
    onAuthorize: () => {
        //client.submit("",  "", "", "");
    },
    onSubmitResponse: (err, res) => {
        console.log(res)
    }
});