node-red-contrib-upbit
v1.0.0
Published
Node-RED node for upbit
Downloads
9
Maintainers
Readme
node-red-contrib-upbit
Node-RED node for upbit
Install
To install the stable version use the Menu - Manage palette - Install
option and search for node-red-contrib-upbit, or run the following
command in your Node-RED user directory, typically ~/.node-red
npm install node-red-contrib-upbit
Wrapper upbit API
https://docs.upbit.com/docs
Sample parameters
msg.params = {};
msg.params.markets = 'KRW-BTC'
msg.params.category = 'accounts'
return msg;
Sample Result
{"currency":"KRW","balance":"83871.9375","locked":"6128.0625","avg_buy_price":"0","avg_buy_price_modified":true,"unit_currency":"KRW"}
Sample flows
[{"id":"f9d5dd3a.a103c","type":"upbit","z":"2422d0a1.5c053","name":"accounts","category":"accounts","api":"","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1080,"y":340,"wires":[["4c48dde8.108d94"]]},{"id":"2497d1be.1c5b8e","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.markets = 'KRW-BTC'\nmsg.params.category = 'accounts'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":340,"wires":[["f9d5dd3a.a103c"]]},{"id":"9b7138b4.3f9578","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":340,"wires":[["2497d1be.1c5b8e"]]},{"id":"4c48dde8.108d94","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1290,"y":340,"wires":[]},{"id":"c5a79038.0be74","type":"upbit","z":"2422d0a1.5c053","name":"orders/chance","category":"orders","api":"chance","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1100,"y":380,"wires":[["39699a83.eb1fd6"]]},{"id":"ce063113.b7883","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":380,"wires":[["c5a79038.0be74"]]},{"id":"b6fdd37b.01f1a","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":380,"wires":[["ce063113.b7883"]]},{"id":"39699a83.eb1fd6","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1290,"y":380,"wires":[]},{"id":"2b0840af.c3b95","type":"upbit","z":"2422d0a1.5c053","name":"withdraws/chance","category":"withdraws","api":"chance","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1110,"y":420,"wires":[["dc697676.76aeb8"]]},{"id":"e1791d0f.b7de9","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nmsg.params.currency = 'BTC'\nmsg.params.currency = 'KRW'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":420,"wires":[["2b0840af.c3b95"]]},{"id":"63994c6.71e59b4","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":420,"wires":[["e1791d0f.b7de9"]]},{"id":"dc697676.76aeb8","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1290,"y":420,"wires":[]},{"id":"770d571e.8f96c8","type":"upbit","z":"2422d0a1.5c053","name":"deposits/coin_addresses","category":"deposits","api":"coin_addresses","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1130,"y":460,"wires":[["9ea8da66.5febe8"]]},{"id":"75825b8.78e62a4","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nmsg.params.currency = 'BTC'\nmsg.params.currency = 'KRW'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":460,"wires":[["770d571e.8f96c8"]]},{"id":"ab0fe3b7.0a428","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":460,"wires":[["75825b8.78e62a4"]]},{"id":"9ea8da66.5febe8","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1330,"y":460,"wires":[]},{"id":"1f5d3b47.e8d125","type":"upbit","z":"2422d0a1.5c053","name":"deposits/coin_address","category":"deposits","api":"coin_address","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1120,"y":500,"wires":[["6d07ee69.203fa"]]},{"id":"ab600fb2.7e6da","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nmsg.params.currency = 'BTC'\n// msg.params.currency = 'XRP'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":500,"wires":[["1f5d3b47.e8d125"]]},{"id":"f2216e8c.45df2","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":500,"wires":[["ab600fb2.7e6da"]]},{"id":"6d07ee69.203fa","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1330,"y":500,"wires":[]},{"id":"e737ca5c.971d28","type":"upbit","z":"2422d0a1.5c053","name":"status/wallet","category":"status","api":"wallet","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1090,"y":540,"wires":[["a389d854.add7f8"]]},{"id":"8285a95.401b258","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":540,"wires":[["e737ca5c.971d28"]]},{"id":"818976dd.ab99b8","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":540,"wires":[["8285a95.401b258"]]},{"id":"a389d854.add7f8","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1330,"y":540,"wires":[]},{"id":"caa6baea.c997c8","type":"upbit","z":"2422d0a1.5c053","name":"api_keys","category":"api_keys","api":"","order_currency":"","payment_currency":"","creds":"4357b226.3504ac","x":1080,"y":580,"wires":[["30a66185.4fe43e"]]},{"id":"678083f6.40b6bc","type":"function","z":"2422d0a1.5c053","name":"","func":"msg.params = {};\nmsg.params.market = 'KRW-BTC'\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":940,"y":580,"wires":[["caa6baea.c997c8"]]},{"id":"9566de70.ebfce","type":"inject","z":"2422d0a1.5c053","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":800,"y":580,"wires":[["678083f6.40b6bc"]]},{"id":"30a66185.4fe43e","type":"debug","z":"2422d0a1.5c053","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1330,"y":580,"wires":[]},{"id":"4357b226.3504ac","type":"upbitApiKey","name":""}]