Nado Typescript SDK Documentation
    Preparing search index...

    Variable CLEARINGHOUSE_ABIConst

    CLEARINGHOUSE_ABI: readonly [
        {
            anonymous: false;
            inputs: readonly [
                {
                    indexed: false;
                    internalType: "address";
                    name: "endpoint";
                    type: "address";
                },
                {
                    indexed: false;
                    internalType: "address";
                    name: "quote";
                    type: "address";
                },
            ];
            name: "ClearinghouseInitialized";
            type: "event";
        },
        {
            anonymous: false;
            inputs: readonly [
                {
                    indexed: true;
                    internalType: "bytes32";
                    name: "liquidatorSubaccount";
                    type: "bytes32";
                },
                {
                    indexed: true;
                    internalType: "bytes32";
                    name: "liquidateeSubaccount";
                    type: "bytes32";
                },
                {
                    indexed: false;
                    internalType: "uint32";
                    name: "productId";
                    type: "uint32";
                },
                {
                    indexed: false;
                    internalType: "bool";
                    name: "isEncodedSpread";
                    type: "bool";
                },
                {
                    indexed: false;
                    internalType: "int128";
                    name: "amount";
                    type: "int128";
                },
                {
                    indexed: false;
                    internalType: "int128";
                    name: "amountQuote";
                    type: "int128";
                },
            ];
            name: "Liquidation";
            type: "event";
        },
        {
            anonymous: false;
            inputs: readonly [
                {
                    indexed: false;
                    internalType: "int128";
                    name: "amount";
                    type: "int128";
                },
                {
                    indexed: true;
                    internalType: "bytes32";
                    name: "subaccount";
                    type: "bytes32";
                },
                {
                    indexed: false;
                    internalType: "uint32";
                    name: "productId";
                    type: "uint32";
                },
            ];
            name: "ModifyCollateral";
            type: "event";
        },
        {
            inputs: readonly [
                { internalType: "address"; name: "engine"; type: "address" },
                { internalType: "address"; name: "offchainExchange"; type: "address" },
                {
                    internalType: "enum IProductEngine.EngineType";
                    name: "engineType";
                    type: "uint8";
                },
            ];
            name: "addEngine";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "uint32"; name: "productId"; type: "uint32" },
                        { internalType: "uint128"; name: "amount"; type: "uint128" },
                        { internalType: "uint64"; name: "nonce"; type: "uint64" },
                    ];
                    internalType: "struct IEndpoint.BurnLp";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "burnLp";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "uint32"; name: "productId"; type: "uint32" },
                        { internalType: "uint128"; name: "amount"; type: "uint128" },
                        { internalType: "bytes32"; name: "recipient"; type: "bytes32" },
                    ];
                    internalType: "struct IEndpoint.BurnLpAndTransfer";
                    name: "txn";
                    type: "tuple";
                },
            ];
            name: "burnLpAndTransfer";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "subaccount"; type: "bytes32" },
                    ];
                    internalType: "struct IEndpoint.ClaimSequencerFees";
                    name: "tx";
                    type: "tuple";
                },
                { internalType: "int128[]"; name: "fees"; type: "int128[]" },
            ];
            name: "claimSequencerFees";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "uint32"; name: "productId"; type: "uint32" },
                        { internalType: "uint128"; name: "amount"; type: "uint128" },
                    ];
                    internalType: "struct IEndpoint.DepositCollateral";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "depositCollateral";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "uint128"; name: "amount"; type: "uint128" },
                    ];
                    internalType: "struct IEndpoint.DepositInsurance";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "depositInsurance";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getClearinghouseLiq";
            outputs: readonly [{ internalType: "address"; name: ""; type: "address" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getEndpoint";
            outputs: readonly [
                { internalType: "address"; name: "endpoint"; type: "address" },
            ];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [
                { internalType: "uint32"; name: "productId"; type: "uint32" },
            ];
            name: "getEngineByProduct";
            outputs: readonly [{ internalType: "address"; name: ""; type: "address" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    internalType: "enum IProductEngine.EngineType";
                    name: "engineType";
                    type: "uint8";
                },
            ];
            name: "getEngineByType";
            outputs: readonly [{ internalType: "address"; name: ""; type: "address" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [
                { internalType: "bytes32"; name: "subaccount"; type: "bytes32" },
                {
                    internalType: "enum IProductEngine.HealthType";
                    name: "healthType";
                    type: "uint8";
                },
            ];
            name: "getHealth";
            outputs: readonly [{ internalType: "int128"; name: ""; type: "int128" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getInsurance";
            outputs: readonly [{ internalType: "int128"; name: ""; type: "int128" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getQuote";
            outputs: readonly [{ internalType: "address"; name: ""; type: "address" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getSpreads";
            outputs: readonly [{ internalType: "uint256"; name: ""; type: "uint256" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [];
            name: "getVersion";
            outputs: readonly [{ internalType: "uint64"; name: ""; type: "uint64" }];
            stateMutability: "view";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "bytes32"; name: "liquidatee"; type: "bytes32" },
                        { internalType: "uint32"; name: "productId"; type: "uint32" },
                        { internalType: "bool"; name: "isEncodedSpread"; type: "bool" },
                        { internalType: "int128"; name: "amount"; type: "int128" },
                        { internalType: "uint64"; name: "nonce"; type: "uint64" },
                    ];
                    internalType: "struct IEndpoint.LiquidateSubaccount";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "liquidateSubaccount";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "uint32"; name: "productId"; type: "uint32" },
                        { internalType: "uint128"; name: "amountBase"; type: "uint128" },
                        { internalType: "uint128"; name: "quoteAmountLow"; type: "uint128" },
                        { internalType: "uint128"; name: "quoteAmountHigh"; type: "uint128" },
                        { internalType: "uint64"; name: "nonce"; type: "uint64" },
                    ];
                    internalType: "struct IEndpoint.MintLp";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "mintLp";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                { internalType: "uint32"; name: "productId"; type: "uint32" },
            ];
            name: "registerProduct";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        {
                            internalType: "bytes32[]";
                            name: "subaccounts";
                            type: "bytes32[]";
                        },
                        { internalType: "uint256[]"; name: "productIds"; type: "uint256[]" },
                    ];
                    internalType: "struct IEndpoint.SettlePnl";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "settlePnl";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    components: readonly [
                        { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                        { internalType: "bytes32"; name: "recipient"; type: "bytes32" },
                        { internalType: "uint128"; name: "amount"; type: "uint128" },
                        { internalType: "uint64"; name: "nonce"; type: "uint64" },
                    ];
                    internalType: "struct IEndpoint.TransferQuote";
                    name: "tx";
                    type: "tuple";
                },
            ];
            name: "transferQuote";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                {
                    internalType: "address";
                    name: "_clearinghouseLiq";
                    type: "address";
                },
            ];
            name: "upgradeClearinghouseLiq";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
        {
            inputs: readonly [
                { internalType: "bytes32"; name: "sender"; type: "bytes32" },
                { internalType: "uint32"; name: "productId"; type: "uint32" },
                { internalType: "uint128"; name: "amount"; type: "uint128" },
                { internalType: "address"; name: "sendTo"; type: "address" },
            ];
            name: "withdrawCollateral";
            outputs: readonly [];
            stateMutability: "nonpayable";
            type: "function";
        },
    ] = ...