Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: wsxdrfv on April 10, 2018, 04:40:34 AM



Title: How pool payout to multiple users?
Post by: wsxdrfv on April 10, 2018, 04:40:34 AM
Pool payout periodically, when time come, it payout to hundreds address at once.

How pool implement this part?

Are there bitcoind (or -cli) command that can do this?



Title: Re: How pool payout to multiple users?
Post by: achow101 on April 10, 2018, 05:23:59 AM
If you are using Bitcoin Core, you use the sendmany command to send to multiple recipients (note that this applies to more than just mining pools).


Title: Re: How pool payout to multiple users?
Post by: bob123 on April 10, 2018, 08:59:01 AM
A Bitcoin transaction consists of Inputs and Outputs. Inputs of a transaction are unspent transaction outputs from previous transactions.
A transaction can be made of multiple inputs and multiple outputs.

In fact, you can chose as much inputs/outputs as you want (as long the size of the TX is smaller than 100Kb - i think).

Electrum for example lets you easily send coins to many addresses within the GUI.


For the sendmany command mentioned by achow101, you can look up the syntax here: http://chainquery.com/bitcoin-api/sendmany (http://chainquery.com/bitcoin-api/sendmany)


An example:

Code:
bitcoin-cli sendmany "" "{\"1D1ZrZNe3JUo7ZycKEYQQiQAWd9y54F4XX\":0.01,\"1353tsE8YMTA4EuV7dgUXGjNFf9KpVvKHz\":0.02}"

This command sends 0.01 btc to 1D1ZrZNe3JUo7ZycKEYQQiQAWd9y54F4XX and 0.02 btc to 1353tsE8YMTA4EuV7dgUXGjNFf9KpVvKHz.


Title: Re: How pool payout to multiple users?
Post by: nc50lc on April 10, 2018, 09:25:33 AM
I am sure that this thread is a continuation of his thread: When new coin mined, if some address receives share of it (https://bitcointalk.org/index.php?topic=3214640.msg34213740#msg34213740).
That's why he mentioned "How Pool implement this part?"

What they answered you is "How to send Bitcoin to two or more addresses" because of the incomplete/incomprehensible information you provided in the OP.

Sorry to day this but, I'm noticing a lot of thread started by you here in the D&TD Board which seems like in broken pieces or in continuation of the rest of it.
My advice for you is to read the rest of the Bitcoin Wiki (https://en.bitcoin.it/wiki/Main_Page) and compile all your related questions in one thread, ask a follow-up reply if you need more information.
You can always bump the thread every 24hrs if you need to display it in the first page as "unread" topic.