Sellers

Provides methods for liquidity providers (buyers) to interact with the validator marketplace

acceptQuote(rfqId: string, quoteId: string)**:

Accept RFQ quote

  const rfqId = 'rfq-id-1234'
  const quoteId = '1234'

  const result = await api.validatorMarketplaceSellers.acceptQuote(rfqId, quoteId)

  if (result.status === 200) {
    console.log('Quote accepted successful

createRFQ(rfq: CreateRFQRequest)**:

Create a new RFQ request

  const newRFQ: CreateRFQRequest = {
    validator_indices: [123, 456, 789],
    payment_wallet_id: 'uuid-of-linked-wallet',
  }

  const createdRFQ = await api.validatorMarketplaceSellers.createRFQ(newRFQ)

  console.log(createdRFQ)
}
  }

getRFQ(rfqId: string)**:

Retrieve a specific RFQ by ID for the seller


const { body: RFQ } = await api.validatorMarketplaceSellers.getRFQ('rfq-id-1234')

console.log(`
  RFQ id: ${RFQ.id}
  best quote: ${RFQ.best_quote}
  status: ${RFQ.status}
  settlement: ${RFQ.settlement_steps}
`)

listRFQs(status? : 'open' | 'submitted' | 'accepted' |'outbid' | 'rejected' | 'expired')**:

List all RFQs posted by the seller with optional status filter


const {body: allRfqs} = await api.validatorMarketplaceSellers.listRFQs('open')

for (const rfq of allRfqs) {
  console.log(`
  RFQ id: ${rfq.id}
  best quote: ${rfq.best_quote}
  status: ${rfq.status}
  settlement: ${rfq.settlement_steps}
`)

registerWithdrawalRecipientSettlement(rfqId: string, {transaction_hash: string)**:

Register withdrawal recipient settlement hash for an RFQ

  const rfqId = 'rfq-id-1234'
  const transaction_hash= '0x1234567890'

  await api.validatorMarketplaceSellers.registerWithdrawalRecipientSettlement(rfqId , {transaction_hash})

rejectQuote(rfqId: string, quoteId: string)**:

Reject a RFQ quote

  const rfqId = 'rfq-id-1234'
  const quoteId = '1234'

  const result = await api.validatorMarketplaceSellers.rejectQuote(rfqId, quoteId)

  if (result.status === 200) {
    console.log('Quote rejectedsuccessfully')
  }