Fetches all winning bids from an auction bucket.
This async function retrieves the auction tree associated with a bucket and calculates the winning bids based on the bucket's clearing price and token allocation.
Promise resolving to an array of winning bids
Error if the auction tree is not found
const auctionBucket = await fetchAuctionBucketV1(umi, bucketPda);const winners = await getAuctionWinners(umi, auctionBucket);console.log(`${winners.length} winning bids found`);
Umi context containing RPC, programs, and eddsa for Solana interaction
The auction bucket containing clearing price and allocation info
Generated using TypeDoc
Fetches all winning bids from an auction bucket.
This async function retrieves the auction tree associated with a bucket and calculates the winning bids based on the bucket's clearing price and token allocation.
Returns
Promise resolving to an array of winning bids
Throws
Error if the auction tree is not found
Example