[
  {
    "inputs": [],
    "name": "ERC1155Base__ArrayLengthMismatch",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__BalanceQueryZeroAddress",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__BurnExceedsBalance",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__BurnFromZeroAddress",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__ERC1155ReceiverNotImplemented",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__ERC1155ReceiverRejected",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__MintToZeroAddress",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__NotOwnerOrApproved",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__SelfApproval",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__TransferExceedsBalance",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "ERC1155Base__TransferToZeroAddress",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "value",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "minimum",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "maximum",
        "type": "uint256"
      }
    ],
    "name": "Pool__AboveMaxSlippage",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "quoteSize",
        "type": "uint256"
      }
    ],
    "name": "Pool__AboveQuoteSize",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "user",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "sender",
        "type": "address"
      },
      {
        "internalType": "enum IUserSettings.Action",
        "name": "action",
        "type": "uint8"
      }
    ],
    "name": "Pool__ActionNotAuthorized",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__AgentNotAuthorized",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "cost",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "payout",
        "type": "uint256"
      }
    ],
    "name": "Pool__CostExceedsPayout",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "costInWrappedNative",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "authorizedCostInWrappedNative",
        "type": "uint256"
      }
    ],
    "name": "Pool__CostNotAuthorized",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "diff",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      }
    ],
    "name": "Pool__DifferenceOfSizeAndContractDeltaTooLarge",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__FlashLoanCallbackFailed",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__FlashLoanNotRepayed",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InsufficientAskLiquidity",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InsufficientBidLiquidity",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InsufficientFunds",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InsufficientLiquidity",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "SD59x18",
        "name": "deltaLongs",
        "type": "int256"
      },
      {
        "internalType": "SD59x18",
        "name": "deltaShorts",
        "type": "int256"
      }
    ],
    "name": "Pool__InvalidAssetUpdate",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "price",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "priceBelow",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidBelowPrice",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "month",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidMonth",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "balance",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "lastDeposit",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidPositionState",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InvalidQuoteOBSignature",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InvalidQuoteOBTaker",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidRange",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "crossings",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidReconciliation",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "depositSize",
        "type": "uint256"
      }
    ],
    "name": "Pool__InvalidSize",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InvalidTickPrice",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InvalidTickUpdate",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__InvalidTransfer",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "balance",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      }
    ],
    "name": "Pool__NotEnoughTokens",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "token",
        "type": "address"
      }
    ],
    "name": "Pool__NotPoolToken",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__NotWrappedNativeTokenPool",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "sender",
        "type": "address"
      }
    ],
    "name": "Pool__OperatorNotAuthorized",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__OptionExpired",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__OptionNotExpired",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "price",
        "type": "uint256"
      }
    ],
    "name": "Pool__OutOfBoundsPrice",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "longs",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "shorts",
        "type": "uint256"
      }
    ],
    "name": "Pool__PositionCantHoldLongAndShort",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "tokenId",
        "type": "uint256"
      }
    ],
    "name": "Pool__PositionDoesNotExist",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__QuoteOBCancelled",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__QuoteOBExpired",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "filledAmount",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "quoteOBSize",
        "type": "uint256"
      }
    ],
    "name": "Pool__QuoteOBOverfilled",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__SettlementFailed",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__SettlementPriceAlreadyCached",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "SD59x18",
        "name": "tickDelta",
        "type": "int256"
      }
    ],
    "name": "Pool__TickDeltaNotZero",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "price",
        "type": "uint256"
      }
    ],
    "name": "Pool__TickNotFound",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "price",
        "type": "uint256"
      }
    ],
    "name": "Pool__TickOutOfRange",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "price",
        "type": "uint256"
      }
    ],
    "name": "Pool__TickWidthInvalid",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__UseTransferPositionToTransferLPTokens",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "unlockTime",
        "type": "uint256"
      }
    ],
    "name": "Pool__WithdrawalDelayNotElapsed",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pool__ZeroSize",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Position__InvalidOrderType",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "currentBalance",
        "type": "uint256"
      },
      {
        "internalType": "SD59x18",
        "name": "amount",
        "type": "int256"
      }
    ],
    "name": "Position__InvalidPositionUpdate",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      }
    ],
    "name": "Position__LowerGreaterOrEqualUpper",
    "type": "error"
  },
  {
    "inputs": [],
    "name": "Pricing__PriceCannotBeComputedWithinTickRange",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "marketPrice",
        "type": "uint256"
      }
    ],
    "name": "Pricing__PriceOutOfRange",
    "type": "error"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      }
    ],
    "name": "Pricing__UpperNotGreaterThanLower",
    "type": "error"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "fee",
        "type": "uint256"
      }
    ],
    "name": "Annihilate",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "account",
        "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": "address",
        "name": "provider",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "bytes32",
        "name": "quoteOBHash",
        "type": "bytes32"
      }
    ],
    "name": "CancelQuoteOB",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "tokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "feesClaimed",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "lastFeeRate",
        "type": "int256"
      }
    ],
    "name": "ClaimFees",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "feeReceiver",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "feesClaimed",
        "type": "uint256"
      }
    ],
    "name": "ClaimProtocolFees",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "tokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "collateral",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "longs",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "shorts",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "lastFeeRate",
        "type": "int256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "claimableFees",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "marketPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "liquidityRate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "currentTick",
        "type": "uint256"
      }
    ],
    "name": "Deposit",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "holder",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "exerciseValue",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "settlementPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "fee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "operatorCost",
        "type": "uint256"
      }
    ],
    "name": "Exercise",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "bytes32",
        "name": "quoteOBHash",
        "type": "bytes32"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "user",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "provider",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "indexed": false,
        "internalType": "struct Position.Delta",
        "name": "deltaMaker",
        "type": "tuple"
      },
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "indexed": false,
        "internalType": "struct Position.Delta",
        "name": "deltaTaker",
        "type": "tuple"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "premium",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "protocolFee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "totalReferralRebate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "bool",
        "name": "isBuy",
        "type": "bool"
      }
    ],
    "name": "FillQuoteOB",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "initiator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "receiver",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "amount",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "fee",
        "type": "uint256"
      }
    ],
    "name": "FlashLoan",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "holder",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "exerciseValue",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "settlementPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "fee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "operatorCost",
        "type": "uint256"
      }
    ],
    "name": "Settle",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "tokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "collateral",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "exerciseValue",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "feesClaimed",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "settlementPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "fee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "operatorCost",
        "type": "uint256"
      }
    ],
    "name": "SettlePosition",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "settlementPrice",
        "type": "uint256"
      }
    ],
    "name": "SettlementPriceCached",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "user",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "indexed": false,
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "premium",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "takerFee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "protocolFee",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "marketPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "liquidityRate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "currentTick",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "totalReferralRebate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "bool",
        "name": "isBuy",
        "type": "bool"
      }
    ],
    "name": "Trade",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256[]",
        "name": "ids",
        "type": "uint256[]"
      },
      {
        "indexed": false,
        "internalType": "uint256[]",
        "name": "values",
        "type": "uint256[]"
      }
    ],
    "name": "TransferBatch",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "receiver",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "srcTokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "destTokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      }
    ],
    "name": "TransferPosition",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "value",
        "type": "uint256"
      }
    ],
    "name": "TransferSingle",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "UD60x18",
        "name": "tick",
        "type": "uint256"
      },
      {
        "indexed": true,
        "internalType": "UD60x18",
        "name": "prev",
        "type": "uint256"
      },
      {
        "indexed": true,
        "internalType": "UD60x18",
        "name": "next",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "delta",
        "type": "int256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "externalFeeRate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "longDelta",
        "type": "int256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "shortDelta",
        "type": "int256"
      },
      {
        "indexed": false,
        "internalType": "uint256",
        "name": "counter",
        "type": "uint256"
      }
    ],
    "name": "UpdateTick",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "uint256",
        "name": "tokenId",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "collateral",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "longs",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "shorts",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "SD59x18",
        "name": "lastFeeRate",
        "type": "int256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "claimableFees",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "marketPrice",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "liquidityRate",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "currentTick",
        "type": "uint256"
      }
    ],
    "name": "Withdrawal",
    "type": "event"
  },
  {
    "anonymous": false,
    "inputs": [
      {
        "indexed": true,
        "internalType": "address",
        "name": "underwriter",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "longReceiver",
        "type": "address"
      },
      {
        "indexed": true,
        "internalType": "address",
        "name": "taker",
        "type": "address"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "contractSize",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "collateral",
        "type": "uint256"
      },
      {
        "indexed": false,
        "internalType": "UD60x18",
        "name": "protocolFee",
        "type": "uint256"
      }
    ],
    "name": "WriteFrom",
    "type": "event"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "taker",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "premium",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isPremiumNormalized",
        "type": "bool"
      },
      {
        "internalType": "bool",
        "name": "isOrderbook",
        "type": "bool"
      },
      {
        "internalType": "UD60x18",
        "name": "strike",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isCallPool",
        "type": "bool"
      }
    ],
    "name": "_takerFeeLowLevel",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      }
    ],
    "name": "accountsByToken",
    "outputs": [
      {
        "internalType": "address[]",
        "name": "",
        "type": "address[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      }
    ],
    "name": "annihilate",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "owner",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      }
    ],
    "name": "annihilateFor",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "account",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      }
    ],
    "name": "balanceOf",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address[]",
        "name": "accounts",
        "type": "address[]"
      },
      {
        "internalType": "uint256[]",
        "name": "ids",
        "type": "uint256[]"
      }
    ],
    "name": "balanceOfBatch",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "bytes32[]",
        "name": "hashes",
        "type": "bytes32[]"
      }
    ],
    "name": "cancelQuotesOB",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      }
    ],
    "name": "claim",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      },
      {
        "internalType": "UD60x18",
        "name": "belowLower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "belowUpper",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "minMarketPrice",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "maxMarketPrice",
        "type": "uint256"
      }
    ],
    "name": "deposit",
    "outputs": [
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      },
      {
        "internalType": "UD60x18",
        "name": "belowLower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "belowUpper",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "minMarketPrice",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "maxMarketPrice",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isBidIfStrandedMarketPrice",
        "type": "bool"
      }
    ],
    "name": "deposit",
    "outputs": [
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "exercise",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "exerciseValue",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "exerciseFee",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address[]",
        "name": "holders",
        "type": "address[]"
      },
      {
        "internalType": "uint256",
        "name": "costPerHolder",
        "type": "uint256"
      }
    ],
    "name": "exerciseFor",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "exerciseValues",
        "type": "uint256[]"
      },
      {
        "internalType": "uint256[]",
        "name": "exerciseFees",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "provider",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "taker",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "price",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "size",
            "type": "uint256"
          },
          {
            "internalType": "bool",
            "name": "isBuy",
            "type": "bool"
          },
          {
            "internalType": "uint256",
            "name": "deadline",
            "type": "uint256"
          },
          {
            "internalType": "uint256",
            "name": "salt",
            "type": "uint256"
          }
        ],
        "internalType": "struct IPoolInternal.QuoteOB",
        "name": "quoteOB",
        "type": "tuple"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "uint8",
            "name": "v",
            "type": "uint8"
          },
          {
            "internalType": "bytes32",
            "name": "r",
            "type": "bytes32"
          },
          {
            "internalType": "bytes32",
            "name": "s",
            "type": "bytes32"
          }
        ],
        "internalType": "struct IPoolInternal.Signature",
        "name": "signature",
        "type": "tuple"
      },
      {
        "internalType": "address",
        "name": "referrer",
        "type": "address"
      }
    ],
    "name": "fillQuoteOB",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "premiumTaker",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "token",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "flashFee",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "contract IERC3156FlashBorrower",
        "name": "receiver",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "token",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      },
      {
        "internalType": "bytes",
        "name": "data",
        "type": "bytes"
      }
    ],
    "name": "flashLoan",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      }
    ],
    "name": "getClaimableFees",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      }
    ],
    "name": "getNearestTicksBelow",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "nearestBelowLower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "nearestBelowUpper",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "getPoolSettings",
    "outputs": [
      {
        "internalType": "address",
        "name": "base",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "quote",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "oracleAdapter",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "strike",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "maturity",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isCallPool",
        "type": "bool"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "taker",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isBuy",
        "type": "bool"
      }
    ],
    "name": "getQuoteAMM",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "premiumNet",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "takerFee",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "provider",
        "type": "address"
      },
      {
        "internalType": "bytes32",
        "name": "quoteOBHash",
        "type": "bytes32"
      }
    ],
    "name": "getQuoteOBFilledAmount",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "getSettlementPrice",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "getStrandedArea",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "lower",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "upper",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "getTokenIds",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "account",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "operator",
        "type": "address"
      }
    ],
    "name": "isApprovedForAll",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "user",
        "type": "address"
      },
      {
        "components": [
          {
            "internalType": "address",
            "name": "provider",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "taker",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "price",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "size",
            "type": "uint256"
          },
          {
            "internalType": "bool",
            "name": "isBuy",
            "type": "bool"
          },
          {
            "internalType": "uint256",
            "name": "deadline",
            "type": "uint256"
          },
          {
            "internalType": "uint256",
            "name": "salt",
            "type": "uint256"
          }
        ],
        "internalType": "struct IPoolInternal.QuoteOB",
        "name": "quoteOB",
        "type": "tuple"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "uint8",
            "name": "v",
            "type": "uint8"
          },
          {
            "internalType": "bytes32",
            "name": "r",
            "type": "bytes32"
          },
          {
            "internalType": "bytes32",
            "name": "s",
            "type": "bytes32"
          }
        ],
        "internalType": "struct IPoolInternal.Signature",
        "name": "sig",
        "type": "tuple"
      }
    ],
    "name": "isQuoteOBValid",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      },
      {
        "internalType": "enum IPoolInternal.InvalidQuoteOBError",
        "name": "",
        "type": "uint8"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "marketPrice",
    "outputs": [
      {
        "internalType": "UD60x18",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "token",
        "type": "address"
      }
    ],
    "name": "maxFlashLoan",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "bytes[]",
        "name": "data",
        "type": "bytes[]"
      }
    ],
    "name": "multicall",
    "outputs": [
      {
        "internalType": "bytes[]",
        "name": "results",
        "type": "bytes[]"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "name",
    "outputs": [
      {
        "internalType": "string",
        "name": "",
        "type": "string"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256[]",
        "name": "ids",
        "type": "uint256[]"
      },
      {
        "internalType": "uint256[]",
        "name": "amounts",
        "type": "uint256[]"
      },
      {
        "internalType": "bytes",
        "name": "data",
        "type": "bytes"
      }
    ],
    "name": "safeBatchTransferFrom",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "from",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "to",
        "type": "address"
      },
      {
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      },
      {
        "internalType": "bytes",
        "name": "data",
        "type": "bytes"
      }
    ],
    "name": "safeTransferFrom",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "operator",
        "type": "address"
      },
      {
        "internalType": "bool",
        "name": "status",
        "type": "bool"
      }
    ],
    "name": "setApprovalForAll",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "settle",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "collateral",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address[]",
        "name": "holders",
        "type": "address[]"
      },
      {
        "internalType": "uint256",
        "name": "costPerHolder",
        "type": "uint256"
      }
    ],
    "name": "settleFor",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      }
    ],
    "name": "settlePosition",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "collateral",
        "type": "uint256"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key[]",
        "name": "p",
        "type": "tuple[]"
      },
      {
        "internalType": "uint256",
        "name": "costPerHolder",
        "type": "uint256"
      }
    ],
    "name": "settlePositionFor",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "bytes4",
        "name": "interfaceId",
        "type": "bytes4"
      }
    ],
    "name": "supportsInterface",
    "outputs": [
      {
        "internalType": "bool",
        "name": "",
        "type": "bool"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "taker",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "uint256",
        "name": "premium",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isPremiumNormalized",
        "type": "bool"
      },
      {
        "internalType": "bool",
        "name": "isOrderbook",
        "type": "bool"
      }
    ],
    "name": "takerFee",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "ticks",
    "outputs": [
      {
        "components": [
          {
            "components": [
              {
                "internalType": "SD49x28",
                "name": "delta",
                "type": "int256"
              },
              {
                "internalType": "UD50x28",
                "name": "externalFeeRate",
                "type": "uint256"
              },
              {
                "internalType": "SD49x28",
                "name": "longDelta",
                "type": "int256"
              },
              {
                "internalType": "SD49x28",
                "name": "shortDelta",
                "type": "int256"
              },
              {
                "internalType": "uint256",
                "name": "counter",
                "type": "uint256"
              }
            ],
            "internalType": "struct IPoolInternal.Tick",
            "name": "tick",
            "type": "tuple"
          },
          {
            "internalType": "UD60x18",
            "name": "price",
            "type": "uint256"
          },
          {
            "internalType": "UD50x28",
            "name": "longRate",
            "type": "uint256"
          },
          {
            "internalType": "UD50x28",
            "name": "shortRate",
            "type": "uint256"
          }
        ],
        "internalType": "struct IPoolInternal.TickWithRates[]",
        "name": "",
        "type": "tuple[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "account",
        "type": "address"
      }
    ],
    "name": "tokensByAccount",
    "outputs": [
      {
        "internalType": "uint256[]",
        "name": "",
        "type": "uint256[]"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      }
    ],
    "name": "totalHolders",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "uint256",
        "name": "id",
        "type": "uint256"
      }
    ],
    "name": "totalSupply",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "",
        "type": "uint256"
      }
    ],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "bool",
        "name": "isBuy",
        "type": "bool"
      },
      {
        "internalType": "uint256",
        "name": "premiumLimit",
        "type": "uint256"
      },
      {
        "internalType": "address",
        "name": "referrer",
        "type": "address"
      }
    ],
    "name": "trade",
    "outputs": [
      {
        "internalType": "uint256",
        "name": "totalPremium",
        "type": "uint256"
      },
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "srcP",
        "type": "tuple"
      },
      {
        "internalType": "address",
        "name": "newOwner",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "newOperator",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      }
    ],
    "name": "transferPosition",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [],
    "name": "tryCacheSettlementPrice",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "components": [
          {
            "internalType": "address",
            "name": "owner",
            "type": "address"
          },
          {
            "internalType": "address",
            "name": "operator",
            "type": "address"
          },
          {
            "internalType": "UD60x18",
            "name": "lower",
            "type": "uint256"
          },
          {
            "internalType": "UD60x18",
            "name": "upper",
            "type": "uint256"
          },
          {
            "internalType": "enum Position.OrderType",
            "name": "orderType",
            "type": "uint8"
          }
        ],
        "internalType": "struct Position.Key",
        "name": "p",
        "type": "tuple"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "minMarketPrice",
        "type": "uint256"
      },
      {
        "internalType": "UD60x18",
        "name": "maxMarketPrice",
        "type": "uint256"
      }
    ],
    "name": "withdraw",
    "outputs": [
      {
        "components": [
          {
            "internalType": "SD59x18",
            "name": "collateral",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "longs",
            "type": "int256"
          },
          {
            "internalType": "SD59x18",
            "name": "shorts",
            "type": "int256"
          }
        ],
        "internalType": "struct Position.Delta",
        "name": "delta",
        "type": "tuple"
      }
    ],
    "stateMutability": "nonpayable",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "address",
        "name": "underwriter",
        "type": "address"
      },
      {
        "internalType": "address",
        "name": "longReceiver",
        "type": "address"
      },
      {
        "internalType": "UD60x18",
        "name": "size",
        "type": "uint256"
      },
      {
        "internalType": "address",
        "name": "referrer",
        "type": "address"
      }
    ],
    "name": "writeFrom",
    "outputs": [],
    "stateMutability": "nonpayable",
    "type": "function"
  }
]