<blockquote>
  <p>So server need to do more than one transaction: 2 BTC from his own deposit address and the rest 3 BTC from another address that server manages. In this scenario we must pay fee for at least 2 transaction. [..]? What is the solution for this problem?</p>
</blockquote>

<p>No, you can simply create one transaction, which spends the two UTXOs in question and pays to your customer (note: Bitcoin uses a UTXO-based model to keep track of coin ownership, not an account-based model). </p>

<blockquote>
  <p>How an I generate new address for ethereum and bitcoin cash in block chain.com api? </p>
</blockquote>

<p>Questions about altcoins, service-provider recommendations, and customer service issues are all off-topic here, sorry. </p>

CC BY-SA 4.0
2020-01-19T21:42:20.320Z
2020-01-19T21:42:20.320Z
chytrik
<p>In an exchange website we just book trades in our database and just when user want to withdraw his BTC balance we make a real transaction in bitcoin network for him. Consider a scenario that a user deposits 2 BTC and after some trades he now owns 5 BTC. His public address balance is 2 BTC and server must send 5 BTC to user's address. So server need to do more than one transaction: 2 BTC from his own deposit address and the rest 3 BTC from another address that server manages. In this scenario we must pay fee for at least 2 transaction. We usually in withdrawal take fee just for one transaction from user. The problem is now server must pay the other fees?
What is the solution for this problem?</p>

<p>In BTC scenario I want to use blockchain.com's wallet app api. As I understood, we can have lots of publuic address corresponding to one extended public key of wallet. So we assign each user to a different public address in time of deposit. In time of withdraw, we can pay from blockchain's wallet to withdraw address of user. Am I right about this approach?
I can generate new address of blockchain wallet with "<a href="http://localhost:3000/merchant/" rel="nofollow noreferrer">http://localhost:3000/merchant/</a>$guid/new_address" url. But this url just generte BTC address. How an I generate new address for ethereum and bitcoin cash in block chain.com api?</p>

<p>Is it possible to use such this solution for ethereum, litecoin and ...</p>

<p>If not, how can I manage the problem of many users deposits and withdraw in an exchange site?</p>

<p>Excuse me for number of questions</p>

<p>Thank you in advance</p>

<blockchain.info><ethereum><withdrawal><blockchain-wallet-app><exchange-software>
Withdraw and deposit in cryptocurrency exchange website
Reza Hedayati
# Withdraw and deposit in cryptocurrency exchange website

(Asked by: username_0 on 2020-01-19)

In an exchange website we just book trades in our database and just when user want to withdraw his BTC balance we make a real transaction in bitcoin network for him. Consider a scenario that a user deposits 2 BTC and after some trades he now owns 5 BTC. His public address balance is 2 BTC and server must send 5 BTC to user's address. So server need to do more than one transaction: 2 BTC from his own deposit address and the rest 3 BTC from another address that server manages. In this scenario we must pay fee for at least 2 transaction. We usually in withdrawal take fee just for one transaction from user. The problem is now server must pay the other fees?
What is the solution for this problem?

In BTC scenario I want to use blockchain.com's wallet app api. As I understood, we can have lots of publuic address corresponding to one extended public key of wallet. So we assign each user to a different public address in time of deposit. In time of withdraw, we can pay from blockchain's wallet to withdraw address of user. Am I right about this approach?
I can generate new address of blockchain wallet with "<http://localhost:3000/merchant/>$guid/new\_address" url. But this url just generte BTC address. How an I generate new address for ethereum and bitcoin cash in block chain.com api?

Is it possible to use such this solution for ethereum, litecoin and ...

If not, how can I manage the problem of many users deposits and withdraw in an exchange site?

Excuse me for number of questions

Thank you in advance

**Tags:** blockchain.info, ethereum, withdrawal, blockchain-wallet-app, exchange-software


---

## 1 answers

### Answer by username_1 on 2020-01-19. Score: 1

> So server need to do more than one transaction: 2 BTC from his own deposit address and the rest 3 BTC from another address that server manages. In this scenario we must pay fee for at least 2 transaction. [..]? What is the solution for this problem?

No, you can simply create one transaction, which spends the two UTXOs in question and pays to your customer (note: Bitcoin uses a UTXO-based model to keep track of coin ownership, not an account-based model).

> How an I generate new address for ethereum and bitcoin cash in block chain.com api?

Questions about altcoins, service-provider recommendations, and customer service issues are all off-topic here, sorry.


---

