ClankerSniperUtilV2
Source:Verified
Contract Overview

The ClankerSniperUtilV2 contract facilitates participation in auctions by allowing users to place bids using WETH and execute token swaps. It incorporates a reentrancy guard to enhance security and includes functions for calculating gas prices based on bid amounts. The contract is designed to interact with various external contracts, including auction and router contracts, to ensure seamless auction operations.

Calls (7D)
Wallets (7D)
Token Balances
Main Functionalities
  1. Auction Bidding:

    • bidInAuction: This function enables users to place bids in a specified auction round by validating various conditions such as round validity, block number, gas price, and bid amount. It processes the payment in WETH, performs a token swap, and emits the AuctionSuccessful event upon successful bidding. The function interacts with the IClankerSniperAuctionV0 interface to retrieve auction details and validate conditions, as well as the IERC20Minimal interface for token approval and transfer.
  2. Gas Price Calculation:

    • getTxGasPriceForBidAmount: This function calculates the required transaction gas price for a specified bid amount, ensuring the bid amount is valid. It retrieves the payment per gas unit from the IClankerSniperAuctionV0 interface to compute the necessary gas price.
  3. Contract Initialization:

    • constructor: Initializes the contract by setting key addresses for the Clanker Sniper Auction, Universal Router, Permit2, and WETH. It also establishes the reentrancy guard status to prevent reentrant calls.