/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */

import { Contract, Interface, type ContractRunner } from "ethers";
import type {
  ILenderCommitmentForwarder,
  ILenderCommitmentForwarderInterface,
} from "../../../contracts/interfaces/ILenderCommitmentForwarder";

const _abi = [
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_principalAmount",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_collateralAmount",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_collateralTokenId",
        type: "uint256",
      },
      {
        internalType: "address",
        name: "_collateralTokenAddress",
        type: "address",
      },
      {
        internalType: "address",
        name: "_recipient",
        type: "address",
      },
      {
        internalType: "uint16",
        name: "_interestRate",
        type: "uint16",
      },
      {
        internalType: "uint32",
        name: "_loanDuration",
        type: "uint32",
      },
    ],
    name: "acceptCommitmentWithRecipient",
    outputs: [
      {
        internalType: "uint256",
        name: "bidId_",
        type: "uint256",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_principalAmount",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_collateralAmount",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "_collateralTokenId",
        type: "uint256",
      },
      {
        internalType: "address",
        name: "_collateralTokenAddress",
        type: "address",
      },
      {
        internalType: "address",
        name: "_recipient",
        type: "address",
      },
      {
        internalType: "uint16",
        name: "_interestRate",
        type: "uint16",
      },
      {
        internalType: "uint32",
        name: "_loanDuration",
        type: "uint32",
      },
      {
        internalType: "bytes32[]",
        name: "_merkleProof",
        type: "bytes32[]",
      },
    ],
    name: "acceptCommitmentWithRecipientAndProof",
    outputs: [
      {
        internalType: "uint256",
        name: "bidId_",
        type: "uint256",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        components: [
          {
            internalType: "uint256",
            name: "maxPrincipal",
            type: "uint256",
          },
          {
            internalType: "uint32",
            name: "expiration",
            type: "uint32",
          },
          {
            internalType: "uint32",
            name: "maxDuration",
            type: "uint32",
          },
          {
            internalType: "uint16",
            name: "minInterestRate",
            type: "uint16",
          },
          {
            internalType: "address",
            name: "collateralTokenAddress",
            type: "address",
          },
          {
            internalType: "uint256",
            name: "collateralTokenId",
            type: "uint256",
          },
          {
            internalType: "uint256",
            name: "maxPrincipalPerCollateralAmount",
            type: "uint256",
          },
          {
            internalType:
              "enum ILenderCommitmentForwarder.CommitmentCollateralType",
            name: "collateralTokenType",
            type: "uint8",
          },
          {
            internalType: "address",
            name: "lender",
            type: "address",
          },
          {
            internalType: "uint256",
            name: "marketId",
            type: "uint256",
          },
          {
            internalType: "address",
            name: "principalTokenAddress",
            type: "address",
          },
        ],
        internalType: "struct ILenderCommitmentForwarder.Commitment",
        name: "_commitment",
        type: "tuple",
      },
      {
        internalType: "address[]",
        name: "_borrowerAddressList",
        type: "address[]",
      },
    ],
    name: "createCommitment",
    outputs: [
      {
        internalType: "uint256",
        name: "",
        type: "uint256",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
    ],
    name: "getCommitmentAcceptedPrincipal",
    outputs: [
      {
        internalType: "uint256",
        name: "",
        type: "uint256",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
    ],
    name: "getCommitmentLender",
    outputs: [
      {
        internalType: "address",
        name: "",
        type: "address",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
    ],
    name: "getCommitmentMarketId",
    outputs: [
      {
        internalType: "uint256",
        name: "",
        type: "uint256",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_commitmentId",
        type: "uint256",
      },
    ],
    name: "getCommitmentMaxPrincipal",
    outputs: [
      {
        internalType: "uint256",
        name: "",
        type: "uint256",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
] as const;

export class ILenderCommitmentForwarder__factory {
  static readonly abi = _abi;
  static createInterface(): ILenderCommitmentForwarderInterface {
    return new Interface(_abi) as ILenderCommitmentForwarderInterface;
  }
  static connect(
    address: string,
    runner?: ContractRunner | null
  ): ILenderCommitmentForwarder {
    return new Contract(
      address,
      _abi,
      runner
    ) as unknown as ILenderCommitmentForwarder;
  }
}
