Pair Registration

MatchingEngine contract manages API for trading on orderbook exchange. To trade on Standard, Solidity developers use IMatchingEngine interface to call its functions.

pragma solidity ^0.8.24;
import {IMatchingEngine} from "standard3.0-contracts/src/exchange/interfaces/IMatchingEngine.sol";

contract CLOB {
    IMatchingEngine public matchingEngine;
 
    constructor(address _engine) {
        matchingEngine = IMatchingEngine(_engine);
    }

    function addPair(address base, address quote, uint256 listingPrice) public {
        matchingEngine.addPair(
            base,
            quote,
            listingPrice
        );
    }
}

Pair registration

Pair Infos

Last updated