useWinningBid() function
This feature is currently in beta and may change based on feedback that we receive.
Use this to get a the winning bid for an auction listing from your marketplace contract.
Example
const { data: winningBid, isLoading, error } = useWinningBid(<YourMarketplaceContractInstance>, <listingId>);
Signature:
export declare function useWinningBid(
contract: RequiredParam<Marketplace>,
listingId: RequiredParam<BigNumberish>,
): import("@tanstack/react-query").UseQueryResult<
import("@thirdweb-dev/sdk/dist/browser").Offer | undefined,
unknown
>;
Parameters
Parameter | Type | Description |
---|---|---|
contract | RequiredParam<Marketplace> | an instance of a marketplace contract |
listingId | RequiredParam<BigNumberish> | the listing id to check |
Returns:
import("@tanstack/react-query").UseQueryResult<import("@thirdweb-dev/sdk/dist/browser").Offer | undefined, unknown>
a response object that includes the that is winning the auction