ORDER

Prepare

if(!process.env.MNEMONIC) {
    throw new Error('MNEMINIC IS REQUIRED!');
}

// init wallet
const mnemonic = process.env.MNEMONIC.split(" ");
const keys = await mnemonicToPrivateKey(mnemonic);

const wallet = tonClient.open(
    WalletContractV4.create({
        workchain: 0,
        publicKey: keys.publicKey
    })
);

// get config
const apiConfig = await getApiConfig();

// get listed assets
const apiAssets = await getApiAssets();

// init order factory
const orderFactory = tonClient.open(OrderFactory.createFromAddress(apiConfig.order_factory));

Create order

Fill order

Cancel order

Vesting trigger

Getters

Last updated