Difference between revisions of "Trading GRIN"

From Bisq Wiki
Jump to navigation Jump to search
(Created page with "'''[https://github.com/mimblewimble/grin/blob/master/doc/grin4bitcoiners.md GRIN]''' is a minimalistic, lightweight cryptocurrency, implementing the Mimblewimble protocol for...")
 
Line 10: Line 10:
 
When buying, you should keep your GRIN wallet open to receive the payment.  More information about GRIN transactions can be found [https://docs.grin.mw/about-grin/transactions here].
 
When buying, you should keep your GRIN wallet open to receive the payment.  More information about GRIN transactions can be found [https://docs.grin.mw/about-grin/transactions here].
  
Once you have recieved the GRIN you should confirm the Bisq trade to release BTC funds and escrow to both parties.
+
Once you have recieved the GRIN you should confirm the Bisq trade to release BTC funds and escrow to the counterparty and yourself.
  
  
Line 40: Line 40:
 
The price of GRIN is determined by the marketplace within Bisq.   
 
The price of GRIN is determined by the marketplace within Bisq.   
  
Trade price is chosen by offer maker (which can be the buyer or seller).  Offers are by default arranged in the marketplace with the most attractive ones shown at the top of the list.
+
Trade price is chosen by offer maker (which can be the buyer or seller).  Offers are by default arranged in the marketplace with the best prices shown at the top of the list.
  
 
The last traded price is shown in at the top right of the screen as "Price of latest Bisq trade".
 
The last traded price is shown in at the top right of the screen as "Price of latest Bisq trade".
Line 85: Line 85:
 
Note that amounts are shown without a decimal place and there are 9 digits after the decimal  
 
Note that amounts are shown without a decimal place and there are 9 digits after the decimal  
  
e.g. <code>"amount": "10123456789" means 10.123456789 GRIN</code>
+
e.g. <code>"amount": "10123456789"</code> means 10.123456789 GRIN
  
 
2) Run the <code>verify_proof</code> command to check that the transaction is recorded on the blockchain.
 
2) Run the <code>verify_proof</code> command to check that the transaction is recorded on the blockchain.
Line 110: Line 110:
 
</pre>
 
</pre>
  
 +
Output:
  
 
<pre>
 
<pre>

Revision as of 00:16, 10 November 2021

GRIN is a minimalistic, lightweight cryptocurrency, implementing the Mimblewimble protocol for a unique balance of privacy and scalability.



Buying GRIN

Buying GRIN is like buying any other altcoin. It requires a GRIN payment account in Bisq. The GRIN slatepack address to be used is issued by your grin wallet.

When buying, you should keep your GRIN wallet open to receive the payment. More information about GRIN transactions can be found here.

Once you have recieved the GRIN you should confirm the Bisq trade to release BTC funds and escrow to the counterparty and yourself.


Selling GRIN

The trader selling GRIN (BTC buyer) will send GRIN to the counterparty's slatepack address using their wallet of choice once the Bisq trade deposit is confirmed.

The amount and recipient address is displayed on-screen when you are prompted to do the transfer.

Example of sending using grin-wallet:

./grin-wallet -r "https://grinnode.live:3413" send -d grin1dxnzk3gfnqz69va64ut7jafs7u72dtyswpzxekdgmlurkng9ctfqf9yqu5 10.123456789


The GRIN buyer will confirm the trade in Bisq once they are satisfied that they received the correct amount of GRIN.


You must be able to generate proof of payment in case of a dispute. Otherwise, Confidential Transactions make it impossible for a third party to verify if a payment was made — so GRIN sellers must be able to generate a transaction's proof for mediators or arbitrators in case of disputes.

Warn
Failing to provide the proof to a dispute agent will likely result in losing the dispute case.

See below for instructions to generate payment proof.


FAQ

How is the price of GRIN determined?

The price of GRIN is determined by the marketplace within Bisq.

Trade price is chosen by offer maker (which can be the buyer or seller). Offers are by default arranged in the marketplace with the best prices shown at the top of the list.

The last traded price is shown in at the top right of the screen as "Price of latest Bisq trade".


Generate payment proof

The person sending the GRIN funds can create payment proof.

First, list your transactions using txs, look for the one you want to issue proof on.

The command export_proof will generate a file containing information to prove the details to the recipient or a mediator.

Example:

    ./grin-wallet -r "https://grinnode.live:3413" txs

    ./grin-wallet -r "https://grinnode.live:3413" export_proof -i 2 proof2.txt

Contents of proof2.txt:

   {
     "amount": "10123456789",
     "excess": "0924ca1b69531aa9abcf85ff7a2bf0d494bc1d85440339332fb62374aabaddf1d6",
     "recipient_address": "grin1dxnzk3gfnqz69va64ut7jafs7u72dtyswpzxekdgmlurkng9ctfqf9yqu5",
     "recipient_sig": "710d58fe9e728077dad9494c0d0e15ba5e883e863477aa471c753282a838d9c45966bc57d21f078c226576b6189b293eed3534b755674284a90bb99a128a7d02",
     "sender_address": "grin1ephxt0u33rz9zpl7exer2awfr9s9ae28qsx7908q2zq03uv3sj7suqdule",
     "sender_sig": "f054a71d5791532364b3267d44601531cdd6730e1eb487142ae798aa3de6e3551c4f756caec09d17901c5e6e08946f04d9d03d04af525567b6df14e25158160c"
   }

The proof file is to be sent to a mediator in case of a dispute over payment not received or incorrect amount.


Guidance for dispute agents

There are two steps for verifying the correct payment was made.

1) Check that the proof file supplied by the GRIN seller matches the details you have for the Bisq trade.

This is just basic fact checking, did the sender proof show the correct recipient address and amount?

Note that amounts are shown without a decimal place and there are 9 digits after the decimal

e.g. "amount": "10123456789" means 10.123456789 GRIN

2) Run the verify_proof command to check that the transaction is recorded on the blockchain.


Warn
There's no reason to verify a proof if the amount or recipient is wrong.



Running the verify_proof wallet tool

In order to verify GRIN trades, you'll need grin-wallet installed on your PC. Install the grin wallet software from https://github.com/mimblewimble/grin-wallet/releases, and then:

./grin-wallet -r "https://grinnode.live:3413" init

The wallet is just used as a tool to verify transactions. You do not need a node, Tor or a seedphrase for this. To verify, use the command verify_proof with the details provided by the GRIN seller, e.g.

./grin-wallet -r "https://grinnode.live:3413" verify_proof ./proof2.txt

Output:

Payment proof's signatures are valid.
Neither the proof's sender nor recipient address belongs to this wallet.
Command 'verify_proof' completed successfully

This proves that the amount was sent to recipient address shown in the proof and recorded in the GRIN ledger.