kohin-js
Version:
The Kohin JS is a comprehensive developer toolkit designed to integrate Kohin's decentralized insurance system seamlessly into your applications. It enables efficient interaction with Kohin smart contracts and backend APIs, facilitating management and ana
1,992 lines (1,991 loc) • 46.6 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.insurancePoolAbi = void 0;
exports.insurancePoolAbi = [
{
inputs: [],
name: "BetAlreadyInsured",
type: "error",
},
{
inputs: [],
name: "BetStillActive",
type: "error",
},
{
inputs: [],
name: "CallerNotOwner",
type: "error",
},
{
inputs: [],
name: "CoverAlreadyClaimed",
type: "error",
},
{
inputs: [],
name: "CoverAlreadyExpired",
type: "error",
},
{
inputs: [],
name: "CoverStateManual",
type: "error",
},
{
inputs: [],
name: "DepositDoesNotExist",
type: "error",
},
{
inputs: [],
name: "ERC721EnumerableForbiddenBatchMint",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "sender",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
{
internalType: "address",
name: "owner",
type: "address",
},
],
name: "ERC721IncorrectOwner",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "operator",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "ERC721InsufficientApproval",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "approver",
type: "address",
},
],
name: "ERC721InvalidApprover",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "operator",
type: "address",
},
],
name: "ERC721InvalidOperator",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "owner",
type: "address",
},
],
name: "ERC721InvalidOwner",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "receiver",
type: "address",
},
],
name: "ERC721InvalidReceiver",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "sender",
type: "address",
},
],
name: "ERC721InvalidSender",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "ERC721NonexistentToken",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "owner",
type: "address",
},
{
internalType: "uint256",
name: "index",
type: "uint256",
},
],
name: "ERC721OutOfBoundsIndex",
type: "error",
},
{
inputs: [],
name: "EnforcedPause",
type: "error",
},
{
inputs: [],
name: "ExpectedPause",
type: "error",
},
{
inputs: [],
name: "FeeExceedsMaxPercentage",
type: "error",
},
{
inputs: [],
name: "IncorrectMaxDepo",
type: "error",
},
{
inputs: [],
name: "IncorrectMinDepo",
type: "error",
},
{
inputs: [],
name: "IncorrectPercent",
type: "error",
},
{
inputs: [],
name: "IncorrectPoolCap",
type: "error",
},
{
inputs: [],
name: "InsufficientBalanceForFees",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "availableAmount",
type: "uint256",
},
{
internalType: "uint256",
name: "requiredAmount",
type: "uint256",
},
],
name: "InsufficientLiquidity",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "amountToWithdraw",
type: "uint256",
},
{
internalType: "uint256",
name: "balance",
type: "uint256",
},
{
internalType: "uint256",
name: "totalLiquidity",
type: "uint256",
},
],
name: "InsufficientTotalLiquidity",
type: "error",
},
{
inputs: [],
name: "InvalidAccessControl",
type: "error",
},
{
inputs: [],
name: "InvalidCoverId",
type: "error",
},
{
inputs: [],
name: "InvalidFeesCollectorAddress",
type: "error",
},
{
inputs: [],
name: "InvalidInitialization",
type: "error",
},
{
inputs: [],
name: "InvalidMlrRatio",
type: "error",
},
{
inputs: [
{
internalType: "uint40",
name: "percent",
type: "uint40",
},
],
name: "InvalidPercent",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "percent",
type: "uint256",
},
],
name: "InvalidSlippagePercent",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "lockedLiquidity",
type: "uint256",
},
{
internalType: "uint256",
name: "totalLiquidity",
type: "uint256",
},
{
internalType: "uint256",
name: "newMlrRatio",
type: "uint256",
},
],
name: "InvalidStateForCurrentLiquidity",
type: "error",
},
{
inputs: [],
name: "InvalidWithdrawTimeout",
type: "error",
},
{
inputs: [],
name: "InvalidWithdrawnAmount",
type: "error",
},
{
inputs: [],
name: "LargeDeposit",
type: "error",
},
{
inputs: [],
name: "LeafNotExist",
type: "error",
},
{
inputs: [
{
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
internalType: "address",
name: "sender",
type: "address",
},
],
name: "LiquidityNotOwned",
type: "error",
},
{
inputs: [
{
internalType: "uint128",
name: "totalLiquidity",
type: "uint128",
},
{
internalType: "uint128",
name: "requiredLiquidity",
type: "uint128",
},
],
name: "MLRViolation",
type: "error",
},
{
inputs: [],
name: "MaxPoolCapacityTooLow",
type: "error",
},
{
inputs: [],
name: "NoFeesCollected",
type: "error",
},
{
inputs: [],
name: "NotBetSlipOwner",
type: "error",
},
{
inputs: [],
name: "NotClaimable",
type: "error",
},
{
inputs: [],
name: "NotInitializing",
type: "error",
},
{
inputs: [],
name: "PremiumExceedsSlippageTolerance",
type: "error",
},
{
inputs: [
{
internalType: "uint128",
name: "totalLiquidity",
type: "uint128",
},
],
name: "ReachedMaxPoolLimit",
type: "error",
},
{
inputs: [],
name: "ReentrancyGuardReentrantCall",
type: "error",
},
{
inputs: [
{
internalType: "address",
name: "token",
type: "address",
},
],
name: "SafeERC20FailedOperation",
type: "error",
},
{
inputs: [
{
internalType: "uint256",
name: "settlementAmount",
type: "uint256",
},
{
internalType: "uint256",
name: "coverageAmount",
type: "uint256",
},
],
name: "SettlementExceedsCoverage",
type: "error",
},
{
inputs: [],
name: "SmallDeposit",
type: "error",
},
{
inputs: [],
name: "SmallDonation",
type: "error",
},
{
inputs: [
{
internalType: "uint64",
name: "",
type: "uint64",
},
],
name: "WithdrawalTimeout",
type: "error",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "newAccessControl",
type: "address",
},
],
name: "AccessControlUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "owner",
type: "address",
},
{
indexed: true,
internalType: "address",
name: "approved",
type: "address",
},
{
indexed: true,
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "Approval",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "owner",
type: "address",
},
{
indexed: true,
internalType: "address",
name: "operator",
type: "address",
},
{
indexed: false,
internalType: "bool",
name: "approved",
type: "bool",
},
],
name: "ApprovalForAll",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "uint256",
name: "coverId",
type: "uint256",
},
{
indexed: true,
internalType: "address",
name: "user",
type: "address",
},
{
indexed: true,
internalType: "uint256",
name: "betId",
type: "uint256",
},
{
indexed: false,
internalType: "enum IPolicyManager.BetType",
name: "betType",
type: "uint8",
},
{
indexed: false,
internalType: "uint128",
name: "amount",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "odds",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "premium",
type: "uint128",
},
{
indexed: false,
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
indexed: false,
internalType: "address",
name: "affiliate",
type: "address",
},
],
name: "CoverBooked",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "uint256",
name: "coverId",
type: "uint256",
},
],
name: "CoverExpired",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "uint256",
name: "coverId",
type: "uint256",
},
{
indexed: false,
internalType: "enum IPolicyManager.CoverState",
name: "newState",
type: "uint8",
},
{
indexed: false,
internalType: "uint128",
name: "premiumAmount",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "settlementAmount",
type: "uint128",
},
],
name: "CoverSettled",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "uint256",
name: "coverId",
type: "uint256",
},
{
indexed: false,
internalType: "enum IPolicyManager.CoverState",
name: "newState",
type: "uint8",
},
{
indexed: false,
internalType: "uint128",
name: "amount",
type: "uint128",
},
],
name: "CoverStateUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "address",
name: "feesCollector",
type: "address",
},
{
indexed: false,
internalType: "uint128",
name: "totalFees",
type: "uint128",
},
],
name: "FeesCollected",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint64",
name: "version",
type: "uint64",
},
],
name: "Initialized",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "account",
type: "address",
},
{
indexed: true,
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
indexed: false,
internalType: "uint256",
name: "amount",
type: "uint256",
},
{
indexed: false,
internalType: "address",
name: "affiliate",
type: "address",
},
],
name: "LiquidityAdded",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "account",
type: "address",
},
{
indexed: true,
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
indexed: false,
internalType: "uint256",
name: "amount",
type: "uint256",
},
],
name: "LiquidityDonated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "account",
type: "address",
},
{
indexed: true,
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
indexed: false,
internalType: "uint256",
name: "amount",
type: "uint256",
},
{
indexed: false,
internalType: "uint128",
name: "withdrawalFee",
type: "uint128",
},
],
name: "LiquidityRemoved",
type: "event",
},
{
anonymous: false,
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: false,
internalType: "address",
name: "account",
type: "address",
},
],
name: "Paused",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint128",
name: "newMinDepo",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "newMaxDepo",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "newMaxPoolCap",
type: "uint128",
},
{
indexed: false,
internalType: "uint128",
name: "newProtocolFee",
type: "uint128",
},
{
indexed: false,
internalType: "address",
name: "collectorFeesAddress",
type: "address",
},
{
indexed: false,
internalType: "uint64",
name: "newWithdrawTimeout",
type: "uint64",
},
{
indexed: false,
internalType: "uint48",
name: "newMlrRatio",
type: "uint48",
},
{
indexed: false,
internalType: "bool",
name: "isEarlyWithdrawalEnabledFlag",
type: "bool",
},
{
indexed: false,
internalType: "uint128",
name: "newEarlyWithdrawalFee",
type: "uint128",
},
],
name: "PoolConfigUpdated",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint128",
name: "distributedAmount",
type: "uint128",
},
{
indexed: false,
internalType: "uint48",
name: "depositId",
type: "uint48",
},
],
name: "ProfitDistributedToLP",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint128",
name: "feesCollected",
type: "uint128",
},
],
name: "ProtocolFeesCollected",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint128",
name: "removedAmount",
type: "uint128",
},
],
name: "ReserveRemoved",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: true,
internalType: "address",
name: "from",
type: "address",
},
{
indexed: true,
internalType: "address",
name: "to",
type: "address",
},
{
indexed: true,
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "Transfer",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "address",
name: "account",
type: "address",
},
],
name: "Unpaused",
type: "event",
},
{
anonymous: false,
inputs: [
{
indexed: false,
internalType: "uint128",
name: "feesCollected",
type: "uint128",
},
],
name: "WithdrawFeesCollected",
type: "event",
},
{
inputs: [],
name: "FeesCollector",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "accessControl",
outputs: [
{
internalType: "contract IAccessControl",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint128",
name: "amount",
type: "uint128",
},
{
internalType: "address",
name: "affiliate",
type: "address",
},
],
name: "addLiquidity",
outputs: [
{
internalType: "uint48",
name: "depositId",
type: "uint48",
},
],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "to",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "approve",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "owner",
type: "address",
},
],
name: "balanceOf",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "betId",
type: "uint256",
},
{
internalType: "enum IPolicyManager.BetType",
name: "betType",
type: "uint8",
},
{
internalType: "uint128",
name: "uPremiumAmount",
type: "uint128",
},
{
internalType: "uint256",
name: "slippagePercent",
type: "uint256",
},
{
internalType: "address",
name: "affiliate",
type: "address",
},
],
name: "buyCover",
outputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "account",
type: "address",
},
],
name: "checkOwner",
outputs: [],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "collectAllFees",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint128",
name: "amount",
type: "uint128",
},
{
internalType: "uint48",
name: "depositId",
type: "uint48",
},
],
name: "donateLiquidity",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [],
name: "earlyWithdrawalFee",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "getApproved",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "getReserve",
outputs: [
{
internalType: "uint128",
name: "reserve",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint48",
name: "depositId",
type: "uint48",
},
],
name: "getWithdrawAfter",
outputs: [
{
internalType: "uint64",
name: "",
type: "uint64",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "_token",
type: "address",
},
{
internalType: "address",
name: "_policyManager",
type: "address",
},
{
internalType: "address",
name: "_accessControl",
type: "address",
},
],
name: "initialize",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "owner",
type: "address",
},
{
internalType: "address",
name: "operator",
type: "address",
},
],
name: "isApprovedForAll",
outputs: [
{
internalType: "bool",
name: "",
type: "bool",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "isEarlyWithdrawalEnabled",
outputs: [
{
internalType: "bool",
name: "",
type: "bool",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "lockedLiquidity",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "maxDepo",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "maxPoolCap",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "minDepo",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "mlrRatio",
outputs: [
{
internalType: "uint64",
name: "",
type: "uint64",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "name",
outputs: [
{
internalType: "string",
name: "",
type: "string",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "nextNode",
outputs: [
{
internalType: "uint48",
name: "",
type: "uint48",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint48",
name: "leaf",
type: "uint48",
},
],
name: "nodeWithdrawView",
outputs: [
{
internalType: "uint128",
name: "withdrawAmount",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "owner",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "ownerOf",
outputs: [
{
internalType: "address",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "pause",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [],
name: "paused",
outputs: [
{
internalType: "bool",
name: "",
type: "bool",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "policyManager",
outputs: [
{
internalType: "contract IPolicyManager",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "protocolFees",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "protocolFeesCollected",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint48",
name: "depositId",
type: "uint48",
},
{
internalType: "uint40",
name: "percent",
type: "uint40",
},
],
name: "removeLiquidity",
outputs: [
{
internalType: "uint128",
name: "withdrawnAmount",
type: "uint128",
},
],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint128",
name: "tokenId",
type: "uint128",
},
{
internalType: "enum IPolicyManager.CoverState",
name: "newCoverState",
type: "uint8",
},
{
internalType: "uint128",
name: "settlementAmount",
type: "uint128",
},
],
name: "restrictedSettleClaim",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "from",
type: "address",
},
{
internalType: "address",
name: "to",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "safeTransferFrom",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "from",
type: "address",
},
{
internalType: "address",
name: "to",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
{
internalType: "bytes",
name: "data",
type: "bytes",
},
],
name: "safeTransferFrom",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "_destination",
type: "address",
},
{
internalType: "address",
name: "_token",
type: "address",
},
{
internalType: "uint256",
name: "_amount",
type: "uint256",
},
],
name: "salvage",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "newAccessControl",
type: "address",
},
],
name: "setAccessControl",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "operator",
type: "address",
},
{
internalType: "bool",
name: "approved",
type: "bool",
},
],
name: "setApprovalForAll",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint128",
name: "tokenId",
type: "uint128",
},
],
name: "settleClaim",
outputs: [
{
internalType: "bool",
name: "success",
type: "bool",
},
{
internalType: "uint128",
name: "amount",
type: "uint128",
},
],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint128[]",
name: "tokenIds",
type: "uint128[]",
},
],
name: "settleClaimBatch",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "bytes4",
name: "interfaceId",
type: "bytes4",
},
],
name: "supportsInterface",
outputs: [
{
internalType: "bool",
name: "",
type: "bool",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "symbol",
outputs: [
{
internalType: "string",
name: "",
type: "string",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "token",
outputs: [
{
internalType: "contract IERC20",
name: "",
type: "address",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "index",
type: "uint256",
},
],
name: "tokenByIndex",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "owner",
type: "address",
},
{
internalType: "uint256",
name: "index",
type: "uint256",
},
],
name: "tokenOfOwnerByIndex",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "tokenURI",
outputs: [
{
internalType: "string",
name: "",
type: "string",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "totalSupply",
outputs: [
{
internalType: "uint256",
name: "",
type: "uint256",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "from",
type: "address",
},
{
internalType: "address",
name: "to",
type: "address",
},
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
name: "transferFrom",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "address",
name: "newOwner",
type: "address",
},
],
name: "transferOwnership",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint48",
name: "",
type: "uint48",
},
],
name: "treeNode",
outputs: [
{
internalType: "uint64",
name: "updateId",
type: "uint64",
},
{
internalType: "uint128",
name: "amount",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "unpause",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [],
name: "updateId",
outputs: [
{
internalType: "uint64",
name: "",
type: "uint64",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint128",
name: "newMinDepo",
type: "uint128",
},
{
internalType: "uint128",
name: "newMaxDepo",
type: "uint128",
},
{
internalType: "uint128",
name: "newMaxPoolCap",
type: "uint128",
},
{
internalType: "uint128",
name: "newProtocolFee",
type: "uint128",
},
{
internalType: "address",
name: "collectorFeesAddress",
type: "address",
},
{
internalType: "uint64",
name: "newWithdrawTimeout",
type: "uint64",
},
{
internalType: "uint48",
name: "newMlrRatio",
type: "uint48",
},
{
internalType: "bool",
name: "isEarlyWithdrawalEnabledFlag",
type: "bool",
},
{
internalType: "uint128",
name: "newEarlyWithdrawalFee",
type: "uint128",
},
],
name: "updatePoolConfig",
outputs: [],
stateMutability: "nonpayable",
type: "function",
},
{
inputs: [
{
internalType: "uint48",
name: "",
type: "uint48",
},
],
name: "withdrawAfter",
outputs: [
{
internalType: "uint64",
name: "",
type: "uint64",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [],
name: "withdrawalFeesCollected",
outputs: [
{
internalType: "uint128",
name: "",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
stateMutability: "payable",
type: "receive",
},
{
inputs: [
{
internalType: "uint256",
name: "betId",
type: "uint256",
},
{
internalType: "enum IPolicyManager.BetType",
name: "betType",
type: "uint8",
},
],
name: "calculateCoverPremium",
outputs: [
{
internalType: "uint128",
name: "calculatedPremium",
type: "uint128",
},
{
internalType: "uint128",
name: "amount",
type: "uint128",
},
{
internalType: "uint128",
name: "odds",
type: "uint128",
},
],
stateMutability: "view",
type: "function",
},
{
inputs: [
{
internalType: "uint256",
name: "betId",
type: "uint256",
},
{
internalType: "enum IPolicyManager.BetType",
name: "betType",
type: "uint8",
},
{
internalType: "uint128",
name: "uPremiumAmount",
type: "uint128",
},
{
internalType: "uint256",
name: "slippagePercent",
type: "uint256",
},
],
name: "buyCover",
outputs: [
{
internalType: "uint256",
name: "tokenId",
type: "uint256",
},
],
stateMutability: "nonpayable",
type: "function",
},
];