Just want to point out my background conscience with God on all this.
I had similar ideas of integrating an exchange into BBP a couple years ago and when I prayed about it I always got a "No, dont do it" from the Holy Spirit - and I think the reason was-- the SEC started to go after many US exchanges and launched strict rules and threw people in jail for violating anti money transmitter laws. However I did pray about this more and got a green light for programming this inside the wallet. I feel the reason for the change is Trump is in and all the pro crypto laws are about to take effect. Im not interested in creating a centralized exchange that holds funds and is hosted on a US domain. Im only interested in writing one in wallet, because I feel that is what God approved.
Expanding on this idea a little more, I have worked out the technical requirements to improve this idea way more than we have now imho. And I also did a little research on existing DEXs. Almost every existing DEX, if not every one, is based on non BTC (ETH or Solana or smart contract compatible chains). There is one called BISQ that works with BTC, but, it is not really what we are doing, its a P2P where the order must match exactly and it clears a multisig tx.
So thats exciting because it means if we do this in a way that may be multi-coin-compatible, this could really be useful.
Heres what I plan on doing next:
- There will be 3 major places the crypto goes: "INGATE", "TRADING", "OUTGATE".
- To standardize this idea, we will support more than one crypto by symbol. The symbol must be listed on a BTC style chain (IE btc,doge,dash etc) to work with this DEX. (Future state we look at XRP XLM ETH etc).
- A community hosts a node, and a BX, and gives us the BX URL, the Node RPC, the symbol and PNG graphics file, and a blurb about the coin.
- Our wallet will start locking foreign currencies on the chain by adding a new standard: a new type of colored coin.
A colored coin has a special address that ends in the foreign ticker and ZZ.
There will be new rules where colored coins can only be sent from a colored address to a colored address. Example:
If you own 100 WDOGE (Wrapped BBP DOGE), you can only send it from a WDOGE address to a WDOGE address.
- The ingate will provide a receive address, so you type something like
wrap WDOGE 2.25
The wallet gives you an address to send the DOGE to, once you send it, your atomic tx will receive WDOGE for the same amount.
We will make it so the block CANNOT BE MINED, unless the DOGE is received and signed by the receiving sanc.
- Once you have these colored assets in your wallet, we can make them trade in a trading room, with high liquidity.
Because then we can do fractional fills. Also, you will get the strong deterministic BBP transactions on those when they are filled.
Meaning that if you had 2.25 WDOGE, and you send those to another BBP wallet each wallet is adjusted with a standard colored tx immediately.
- The Outgate will allow you to perform a BURN of the tx to our BURN address, and this tx will not be mined unless you receive back your exit collateral.
This will be for withdrawals.
- The security will be increased on the Sanc to store the collateral on the chain this way:
We will make a new transaction Type that will only unlock the foreign funds when the colored recipient signs plus a sanc signs. This will prevent any security issues for every transaction as if a rogue temple comes online and tries to steal a collateral tx that is live in the trades, they wont have the sig of the person with the colored coin. Also, we will store the collateral in individual deterministic addresses that relate to the original deposit. Another words, no big hot wallet building up, but instead hundreds of little cold wallets that can only be liquidated using this special type of liquidation transaction.
- The users can trade 24-7 because of the liquidity of the wrapped funds.
- People can go in and out of the funds at any time - they can trade for a couple hours and withdraw etc.
- UI: We can make a trading room that will have the ticker banner, a buy order book and a sell orderbook, volume and totals. A buy and sell button.
This would probably increase the usage of the feature so I'm willing to do it, God willing.
Would this be cool to do?