A successful trade

escrow-success.png (Note: This flowchart includes the escrow actions but they may not apply to a specific listing and can in some circumstances be omitted from the general flow)

The buyer initiates the message to the seller with two objects: MPA-BID is an object which carries the specifics of the buyer, this includes responses to the input objects and potential memos to the seller. The second object is `MPA-LOCK containing the inputs of the buyer, the change address and the buyers address for the multisignature. In the case of an escrow, this is an unsigned transaction with merely the inputs and outputs to be used in the escrow. In case no escrow applies, this is a signed transaction ready for broadcast to the network.

Signature Input Output
empty Buyer input /
/ / Escrow output
/ / Change output (buyer)

The seller can either accept the bid with MPA-ACCEPT or reject it with MPA-REJECT. In case the seller accepts, and an escrow system is used, he also responds with an MPA-LOCK object, which contains his inputs, his change outputs and the common escrow output.

Signature Input Output
empty Buyer input /
signed! Seller input /
/ / Escrow output
/ / Change output (buyer)
/ / Change output (seller)

The seller also responds with an MPA-RELEASE object which contains a partially-signed (by the seller) multisignature transaction, spending the common escrow output from the previous transaction. The release transaction builds on top of the unbroadcasted/unmined transaction which was recently made possible due to Segwit, fixing the transaction malleability bugs.

Signature Input Output
empty Escrow input (buyer) /
signed! Escrow input (seller) /
/ / Return output (buyer)
/ / Return output (seller)

Given that the buyer signs and broadcasts the transaction provided by MPA-LOCK, he is also instantly able to broadcast the release transaction in one go.

The buyer is by no means forced to sign and broadcast the release transaction, and should only do so if the item has arrived and works as expected.

Before the buyer even thinks about releasing the escrow output to the network, he first has to lock the multisignature transaction by signing it and broadcasting it.

Signature Input Output
signed! Buyer input /
signed! Seller input /
/ / Escrow output
/ / Change output (buyer)
/ / Change output (seller)

The buyer broadcasts the above transaction.

The seller should not send the item without confirming that the escrow creation transaction (as created by MPA-LOCK) has been mined into the corresponding blockchain.

Seller goes missing (before locking the escrow)

escrow-seller-missing.png

In case the seller goes missing and doesn't accept nor reject the listing then the buyer isn't obligated to do anything. His funds are secure yet exposed to the seller. Given that the underlying blockchain provides any privacy enhancing features, then we recommend that those are applied to prevent honeypots.

Buyer goes missing (before locking the escrow)

escrow-buyer-missing.png

In the case that the buyer goes missing after responding with a partially signed multisignature transaction, then the seller should spend those inputs to prevent the buyer from suddenly broadcasting the transaction to the network unexpectedly.

The seller can send a message with an MPA-REJECT object to warn the buyer that the offer has expired.

Buyer or seller go missing (after lock)

escrow-burned.png

The money is locked in and thus can't be recovered.

Extend

escrow-extend.png

In the case that there is an issue between the seller and buyer, and the escrow output is timelocked (thus self-destructing at a specific blockheight), then they may chose to extend the escrow by spending the escrow output and creating a new escrow transaction with a new self-destruct time.

Refund

escrow-refund.png

In the case there is an issue with the item, then both seller and buyer can initiate a MPA-REFUND, which contains a partially signed multisignature transaction that spend the escrow output, returning the respective amounts locked into the escrow to the buyer and seller.