ACCEPTING QUOTES
1 LP ACTIVE

LP DESK

Whitelisted market makers connect to the coordinator, quote privately against live RFQs, and settle via Jupiter Swap V2. Losing quotes stay sealed — competitors never learn your price.

SOLANA DEVNET
localhost:3001
2QNpH2F…mNU
MAGICBLOCK TEE
01
REGISTER ON-CHAIN
LP pubkey added to the LpRegistry PDA by protocol admin. One-time whitelist step. Only registered LPs receive RFQ events.
02
CONNECT + AUTH
Connect to /ws/lp and sign an Ed25519 challenge from the coordinator. Signature verified on-chain against the whitelist.
03
PRICE VIA JUPITER + DFLOW
On NewRfq, call Jupiter Swap V2 /order and DFlow /order in parallel. Higher outAmount wins. Jupiter requestId is cached for instant execution.
04
SUBMIT SEALED COMMITMENT
sha256(rfq_pubkey ‖ price ‖ lp_pubkey) posted on-chain via submit_quote_commitment. Price stays sealed. Prevents last-second bid changes.
05
REVEAL AFTER CLOSE
Coordinator broadcasts AuctionClosed. LPs send RevealQuote with plaintext price. Coordinator verifies hash inside TEE and picks the best bid.
06
SIGN SETTLEMENT TX
Winner receives SettleTx with MagicBlock PER private transfer payload. Co-sign and broadcast. Jupiter /execute fires with cached requestId — no re-quoting.
ws://coordinator:3001/ws/lp · JSON · tagged union on "type"
LP → SERVER
Auth
{ "type": "Auth",
  "lp_pubkey": "CJt2...",
  "signature": "3xKp..." }
IntentToQuote
{ "type": "IntentToQuote",
  "rfq_pubkey": "abc123...",
  "commitment_hash": "d1db8f..." }
RevealQuote
{ "type": "RevealQuote",
  "rfq_pubkey": "abc123...",
  "price": 82036,
  "fill_size": 400000,
  "per_token": "eyJ..." }
SettleTxSubmitted
{ "type": "SettleTxSubmitted",
  "rfq_pubkey": "abc123...",
  "tx_signature": "5YNq..." }
SERVER → LP
NewRfq
{ "type": "NewRfq",
  "rfqPubkey": "abc123...",
  "sellMint": "JUPy...",
  "sellAmount": 400000,
  "buyMint": "EPjF...",
  "expiryTs": 1746684090 }
AuctionClosed// winner="" = reveal now
{ "type": "AuctionClosed",
  "rfq_pubkey": "abc123...",
  "winner": "",
  "price": 0 }
SettleTx// winner only
{ "type": "SettleTx",
  "rfq_pubkey": "abc123...",
  "winner_lp": "CJt2...",
  "tx_base64": "AQAA...",
  "send_to": "https://..." }
lp_sim — bash
$cd shield_rfq/scripts
$npm install
added 4 packages
$export JUPITER_API_KEY=your_key # optional
$PROGRAM_ID=2QNpH2FgW91EybZjaNpaeWvtW49Sr8ZS9ZLgV1eDHmNU node lp_sim.js
════ Velum LP Simulator ════
LP pubkey : CJt2BSyyKTZkQedLs3woTCACp6uQg8G8nDgjNkuVcS7g
Pricing : Jupiter Swap V2 + DFlow /order (best-of-both)
[✓] PER auth: token obtained
[✓] Connected to coordinator
[LP] Sent Auth. Waiting for RFQ events
Best-of-both routing on every quote
Jupiter Swap V2
  • — /order returns requestId cached for instant /execute
  • — No re-quoting at settlement, price locked at bid time
  • — MEV protection via managed landing built in
DFlow
  • — Parallel request, compared to Jupiter on every RFQ
  • — Winner automatically selected by outAmount
  • — Taker benefits from venue competition, not just LP competition
CJt2BSyyKTZkQedLs3woTCACp6uQg8G8nDgjNkuVcS7g
seeds: ["lp", pubkey]
Active
Devnet
To register a new LP: run node scripts/init_protocol.js with the target pubkey. Requires the protocol admin keypair.