-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buy and Sell Inscriptions/Rare Sats #2697
base: master
Are you sure you want to change the base?
Conversation
Heres a psbt for an inscription that available for purchase for 100k signet satoshis: 70736274ff01005e0200000001fa5f1d3331d995c479c64f761a715c435d6ed8b91cb39c46ff960af941566c1a0100000000fdffffff01a0860100000000002251208314a233ef8bcb98a027cc045b9d849a91310ee5ee5122db8c52b92c8cd2c96d000000000001012b22240000000000002251203adaaaa60a717a9ec4effb1282fb188db0a556de16ba0a07ec717023cbe9659201030483000000010843014167cc91babeacbe8e9a7658eb30b8b11a4fdd2222944c76ee66846e946de4fab44d1507179b87bfab0059534668b66a86ea4c4d1902a4993ec1913d663c756f9d830000 |
@@ -51,6 +53,10 @@ pub(crate) enum Wallet { | |||
Outputs, | |||
#[command(about = "List unspent cardinal outputs in wallet")] | |||
Cardinals, | |||
#[command(about = "List and ordinal for sale")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#[command(about = "List and ordinal for sale")] | |
#[command(about = "List an ordinal for sale")] |
I think before we can start reviewing this, we need to design and agree on the design of offer PSBTs. I created this #2706 to track this. See that issue for my thoughts. |
help = "The amount of sats to sell your inscription or rare sats for." | ||
)] | ||
pub amount: Amount, | ||
pub outgoing: Outgoing, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might be nice if you could optionally specify a particular address for the sales funds to go to.
|
||
let mut total_fees = 0; | ||
|
||
if bump_utxos.len() < 2 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of going with the bump pattern that market places use, it would be great if there was an option for the user to use any 2 random UTXOs for the first 2. That would allow UTXO consolidation as a nice byproduct of a purchase.
This PR introduces two new commands
ord wallet sell
andord wallet buy
. Sell will return a signed psbt that you can share with your friends or publish somewhere publicly. Purchase will take the signature from a signed psbt and fund a transaction to move the asset into your walletSell
Buy
Example
To sell an inscription for 100k sats:
Sell command returns signed psbt:
Buying the the inscription:
Results in a purchase:
Tested on signet
https://mempool.space/signet/tx/1a6c5641f90a96ff469cb31cb9d86e5d435c711a764fc679c495d931331d5ffa#vin=4