From 8cad39252c73285235bf669df586fef91342471e Mon Sep 17 00:00:00 2001 From: Bartlomiej Tarczynski Date: Mon, 15 Apr 2024 13:33:34 +0200 Subject: [PATCH] Update abi to the latest version --- .../frontend/src/blockchain/abi/auction.ts | 786 +++++++++++++++--- 1 file changed, 652 insertions(+), 134 deletions(-) diff --git a/packages/frontend/src/blockchain/abi/auction.ts b/packages/frontend/src/blockchain/abi/auction.ts index d6f4dd5e..ffa66ab9 100644 --- a/packages/frontend/src/blockchain/abi/auction.ts +++ b/packages/frontend/src/blockchain/abi/auction.ts @@ -1,258 +1,776 @@ export const AUCTION_ABI = [ + { + "inputs": [], + "name": "InvalidInputs", + "type": "error" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "have", + "type": "address" + }, + { + "internalType": "address", + "name": "want", + "type": "address" + } + ], + "name": "OnlyCoordinatorCanFulfill", + "type": "error" + }, { "anonymous": false, - "inputs": [{"indexed": false, "internalType": "uint256", "name": "bidderID", "type": "uint256"}], + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + } + ], "name": "NewAuctionWinner", "type": "event" - }, { + }, + { "anonymous": false, - "inputs": [{"indexed": false, "internalType": "address", "name": "bidder", "type": "address"}, { - "indexed": false, - "internalType": "uint256", - "name": "bidderID", - "type": "uint256" - }, {"indexed": false, "internalType": "uint256", "name": "bidAmount", "type": "uint256"}], + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "bidder", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "bidAmount", + "type": "uint256" + } + ], "name": "NewBid", "type": "event" - }, { - "anonymous": false, - "inputs": [{"indexed": false, "internalType": "uint256", "name": "bidderID", "type": "uint256"}], - "name": "NewGoldenTicketWinner", - "type": "event" - }, { + }, + { "anonymous": false, - "inputs": [{"indexed": false, "internalType": "uint256", "name": "bidderID", "type": "uint256"}], - "name": "NewRaffleWinner", + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", "type": "event" - }, { + }, + { "anonymous": false, - "inputs": [{ - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, {"indexed": true, "internalType": "address", "name": "newOwner", "type": "address"}], - "name": "OwnershipTransferred", + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "randomSeed", + "type": "uint256" + } + ], + "name": "RaffleWinnersDrawn", "type": "event" - }, {"stateMutability": "payable", "type": "fallback"}, { + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "_randomSeed", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "auctionWinnersCount", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, {"inputs": [], "name": "bid", "outputs": [], "stateMutability": "payable", "type": "function"}, { + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "score", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "proof", + "type": "bytes" + } + ], + "name": "bid", + "outputs": [], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [], + "name": "bidVerifier", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "biddingEndTime", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "biddingStartTime", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { - "inputs": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}], - "name": "claim", + }, + { + "inputs": [], + "name": "bump", "outputs": [], - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function" - }, { - "inputs": [{"internalType": "uint256", "name": "bidsCount", "type": "uint256"}], - "name": "claimFees", + }, + { + "inputs": [], + "name": "callbackGasLimit", + "outputs": [ + { + "internalType": "uint32", + "name": "", + "type": "uint32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + } + ], + "name": "claim", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { + }, + { "inputs": [], "name": "claimProceeds", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { + }, + { "inputs": [], "name": "claimingEndTime", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "gasLaneKeyHash", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getAuctionWinners", - "outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}], + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], "stateMutability": "view", "type": "function" - }, { - "inputs": [{"internalType": "address", "name": "bidder", "type": "address"}], + }, + { + "inputs": [ + { + "internalType": "address", + "name": "bidder", + "type": "address" + } + ], "name": "getBid", - "outputs": [{ - "components": [{ + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isAuctionWinner", + "type": "bool" + }, + { + "internalType": "bool", + "name": "claimed", + "type": "bool" + }, + { + "internalType": "uint240", + "name": "raffleParticipantIndex", + "type": "uint240" + } + ], + "internalType": "struct BidModel.Bid", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { "internalType": "uint256", "name": "bidderID", "type": "uint256" - }, {"internalType": "uint256", "name": "amount", "type": "uint256"}, { - "internalType": "enum BidModel.WinType", - "name": "winType", - "type": "uint8" - }, {"internalType": "bool", "name": "claimed", "type": "bool"}], - "internalType": "struct BidModel.Bid", - "name": "", - "type": "tuple" - }], + } + ], + "name": "getBidByID", + "outputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isAuctionWinner", + "type": "bool" + }, + { + "internalType": "bool", + "name": "claimed", + "type": "bool" + }, + { + "internalType": "uint240", + "name": "raffleParticipantIndex", + "type": "uint240" + } + ], + "internalType": "struct BidModel.Bid", + "name": "", + "type": "tuple" + } + ], "stateMutability": "view", "type": "function" - }, { - "inputs": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}], - "name": "getBidByID", - "outputs": [{ - "components": [{ + }, + { + "inputs": [ + { "internalType": "uint256", "name": "bidderID", "type": "uint256" - }, {"internalType": "uint256", "name": "amount", "type": "uint256"}, { + } + ], + "name": "getBidWinType", + "outputs": [ + { "internalType": "enum BidModel.WinType", - "name": "winType", + "name": "", "type": "uint8" - }, {"internalType": "bool", "name": "claimed", "type": "bool"}], - "internalType": "struct BidModel.Bid", - "name": "", - "type": "tuple" - }], + } + ], "stateMutability": "view", "type": "function" - }, { - "inputs": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}], + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + } + ], "name": "getBidWithAddress", - "outputs": [{ - "components": [{ - "internalType": "address", - "name": "bidder", - "type": "address" - }, { - "components": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}, { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, {"internalType": "enum BidModel.WinType", "name": "winType", "type": "uint8"}, { - "internalType": "bool", - "name": "claimed", - "type": "bool" - }], "internalType": "struct BidModel.Bid", "name": "bid", "type": "tuple" - }], "internalType": "struct BidModel.BidWithAddress", "name": "", "type": "tuple" - }], + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "bidder", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isAuctionWinner", + "type": "bool" + }, + { + "internalType": "bool", + "name": "claimed", + "type": "bool" + }, + { + "internalType": "uint240", + "name": "raffleParticipantIndex", + "type": "uint240" + } + ], + "internalType": "struct BidModel.Bid", + "name": "bid", + "type": "tuple" + } + ], + "internalType": "struct BidModel.BidWithAddress", + "name": "", + "type": "tuple" + } + ], "stateMutability": "view", "type": "function" - }, { - "inputs": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}], + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + } + ], "name": "getBidderAddress", - "outputs": [{"internalType": "address payable", "name": "", "type": "address"}], + "outputs": [ + { + "internalType": "address payable", + "name": "", + "type": "address" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getBiddersCount", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getBidsWithAddresses", - "outputs": [{ - "components": [{ - "internalType": "address", - "name": "bidder", - "type": "address" - }, { - "components": [{"internalType": "uint256", "name": "bidderID", "type": "uint256"}, { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, {"internalType": "enum BidModel.WinType", "name": "winType", "type": "uint8"}, { - "internalType": "bool", - "name": "claimed", - "type": "bool" - }], "internalType": "struct BidModel.Bid", "name": "bid", "type": "tuple" - }], "internalType": "struct BidModel.BidWithAddress[]", "name": "", "type": "tuple[]" - }], + "outputs": [ + { + "components": [ + { + "internalType": "address", + "name": "bidder", + "type": "address" + }, + { + "components": [ + { + "internalType": "uint256", + "name": "bidderID", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "bool", + "name": "isAuctionWinner", + "type": "bool" + }, + { + "internalType": "bool", + "name": "claimed", + "type": "bool" + }, + { + "internalType": "uint240", + "name": "raffleParticipantIndex", + "type": "uint240" + } + ], + "internalType": "struct BidModel.Bid", + "name": "bid", + "type": "tuple" + } + ], + "internalType": "struct BidModel.BidWithAddress[]", + "name": "", + "type": "tuple[]" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getRaffleParticipants", - "outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}], + "outputs": [ + { + "internalType": "uint256[]", + "name": "", + "type": "uint256[]" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getRaffleWinners", - "outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}], + "outputs": [ + { + "internalType": "uint256[]", + "name": "winners", + "type": "uint256[]" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "getState", - "outputs": [{"internalType": "enum StateModel.State", "name": "", "type": "uint8"}], + "outputs": [ + { + "internalType": "enum StateModel.State", + "name": "", + "type": "uint8" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { + "inputs": [], + "name": "juels", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "linkPremium", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "linkToken", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "minBidIncrement", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { + "inputs": [], + "name": "minConfirmations", + "outputs": [ + { + "internalType": "uint16", + "name": "", + "type": "uint16" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "owner", - "outputs": [{"internalType": "address", "name": "", "type": "address"}], + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "raffleWinnersCount", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "requestId", + "type": "uint256" + }, + { + "internalType": "uint256[]", + "name": "randomWords", + "type": "uint256[]" + } + ], + "name": "rawFulfillRandomWords", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { "inputs": [], "name": "renounceOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { - "inputs": [{"internalType": "address", "name": "tokenAddress", "type": "address"}], + }, + { + "inputs": [], + "name": "requestId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "tokenAddress", + "type": "address" + } + ], "name": "rescueTokens", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { + }, + { "inputs": [], "name": "reservePrice", - "outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}], + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], "stateMutability": "view", "type": "function" - }, { + }, + { "inputs": [], "name": "settleAuction", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { - "inputs": [{"internalType": "uint256[]", "name": "randomNumbers", "type": "uint256[]"}], + }, + { + "inputs": [], "name": "settleRaffle", - "outputs": [], + "outputs": [ + { + "internalType": "uint256", + "name": "requestId", + "type": "uint256" + } + ], "stateMutability": "nonpayable", "type": "function" - }, { - "inputs": [{"internalType": "address", "name": "newOwner", "type": "address"}], + }, + { + "inputs": [], + "name": "subId", + "outputs": [ + { + "internalType": "uint64", + "name": "", + "type": "uint64" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], "name": "transferOwnership", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, { + }, + { + "inputs": [], + "name": "vrfCoordinator", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { "inputs": [], "name": "withdrawUnclaimedFunds", "outputs": [], "stateMutability": "nonpayable", "type": "function" - }, {"stateMutability": "payable", "type": "receive"} + }, + { + "stateMutability": "payable", + "type": "receive" + } ] as const