import type { Maybe } from "@rarible/types"; import type { Ethereum } from "@rarible/ethereum-provider"; import type { BigNumber } from "@rarible/types"; import type { Binary, Part } from "@rarible/ethereum-api-client"; import type { BigNumberValue } from "@rarible/utils"; import type { EVMAddress } from "@rarible/types"; import type { SendFunction } from "../../common/send-transaction"; import type { SimpleOrder } from "../types"; import type { EthereumNetwork } from "../../types"; import type { RaribleEthereumApis } from "../../common/apis"; import type { SimpleLooksrareV2Order } from "../types"; import type { GetConfigByChainId } from "../../config"; import type { PreparedOrderRequestDataForExchangeWrapper, OrderFillSendData, LooksrareOrderV2FillRequest } from "./types"; import { ExchangeWrapperOrderType } from "./types"; export declare class LooksrareV2OrderHandler { private readonly ethereum; private readonly send; private readonly getConfig; private readonly getBaseOrderFeeConfig; private readonly env; private readonly getApis; constructor(ethereum: Maybe, send: SendFunction, getConfig: GetConfigByChainId, getBaseOrderFeeConfig: (type: SimpleOrder["type"]) => Promise, env: EthereumNetwork, getApis: () => Promise); convertMakerOrderToLooksrare(makerOrder: SimpleLooksrareV2Order, amount: BigNumberValue): LooksrareV2RawOrder; prepareTransaction(request: LooksrareOrderV2FillRequest, originFees: Part[] | undefined): Promise<{ functionCall: import("@rarible/ethereum-provider").EthereumFunctionCall; rawOrder: LooksrareV2RawOrder; }>; getTransactionDataForExchangeWrapper(request: LooksrareOrderV2FillRequest, originFees: Part[] | undefined, encodedFeesValue: BigNumber): Promise; getTransactionData(request: LooksrareOrderV2FillRequest): Promise; prepareTransactionData(request: LooksrareOrderV2FillRequest, originFees: Part[] | undefined, encodedFeesValue?: BigNumber): Promise<{ requestData: { data: { marketId: ExchangeWrapperOrderType; amount: string; fees: import("@rarible/types").BigNumberLike; data: string; }; options: { value: string; }; }; feeAddresses: readonly [EVMAddress, EVMAddress]; }>; getFillOrderBaseFee(): Promise; } export type LooksrareV2RawOrder = { quoteType: QuoteType; globalNonce: string; subsetNonce: string; orderNonce: string; strategyId: number | string; collectionType: number; collection: string; currency: string; signer: string; startTime: number; endTime: number; price: string; itemIds: string[]; amounts: string[]; additionalParameters: Binary; }; export declare enum QuoteType { Bid = 0, Ask = 1 } export declare enum StrategyType { standard = 0, collection = 1, collectionWithMerkleTree = 2 } export declare enum CollectionType { ERC721 = 0, ERC1155 = 1 } export declare const getTakerParamsTypes: (strategy: StrategyType) => string[]; export declare enum OrderValidatorCode { ORDER_EXPECTED_TO_BE_VALID = 0, CURRENCY_NOT_ALLOWED = 101, STRATEGY_NOT_IMPLEMENTED = 111, STRATEGY_INVALID_QUOTE_TYPE = 112, STRATEGY_NOT_ACTIVE = 113, MAKER_ORDER_INVALID_STANDARD_SALE = 201, MAKER_ORDER_PERMANENTLY_INVALID_NON_STANDARD_SALE = 211, MAKER_ORDER_INVALID_CURRENCY_NON_STANDARD_SALE = 212, MAKER_ORDER_TEMPORARILY_INVALID_NON_STANDARD_SALE = 213, USER_SUBSET_NONCE_CANCELLED = 301, USER_ORDER_NONCE_EXECUTED_OR_CANCELLED = 311, USER_ORDER_NONCE_IN_EXECUTION_WITH_OTHER_HASH = 312, INVALID_USER_GLOBAL_BID_NONCE = 321, INVALID_USER_GLOBAL_ASK_NONCE = 322, ORDER_HASH_PROOF_NOT_IN_MERKLE_TREE = 401, MERKLE_PROOF_PROOF_TOO_LARGE = 402, INVALID_SIGNATURE_LENGTH = 411, INVALID_S_PARAMETER_EOA = 412, INVALID_V_PARAMETER_EOA = 413, NULL_SIGNER_EOA = 414, INVALID_SIGNER_EOA = 415, MISSING_IS_VALID_SIGNATURE_FUNCTION_EIP1271 = 421, SIGNATURE_INVALID_EIP1271 = 422, START_TIME_GREATER_THAN_END_TIME = 501, TOO_LATE_TO_EXECUTE_ORDER = 502, TOO_EARLY_TO_EXECUTE_ORDER = 503, SAME_ITEM_ID_IN_BUNDLE = 601, ERC20_BALANCE_INFERIOR_TO_PRICE = 611, ERC20_APPROVAL_INFERIOR_TO_PRICE = 612, ERC721_ITEM_ID_DOES_NOT_EXIST = 621, ERC721_ITEM_ID_NOT_IN_BALANCE = 622, ERC721_NO_APPROVAL_FOR_ALL_OR_ITEM_ID = 623, ERC1155_BALANCE_OF_DOES_NOT_EXIST = 631, ERC1155_BALANCE_OF_ITEM_ID_INFERIOR_TO_AMOUNT = 632, ERC1155_IS_APPROVED_FOR_ALL_DOES_NOT_EXIST = 633, ERC1155_NO_APPROVAL_FOR_ALL = 634, POTENTIAL_INVALID_COLLECTION_TYPE_SHOULD_BE_ERC721 = 701, POTENTIAL_INVALID_COLLECTION_TYPE_SHOULD_BE_ERC1155 = 702, NO_TRANSFER_MANAGER_APPROVAL_BY_USER_FOR_EXCHANGE = 801, TRANSFER_MANAGER_APPROVAL_REVOKED_BY_OWNER_FOR_EXCHANGE = 802, BUNDLE_ERC2981_NOT_SUPPORTED = 901, CREATOR_FEE_TOO_HIGH = 902 }