execute = async (logger, rawData) => {
  const data = rawData;

  const { symbol } = data;

  if (isExceedAPILimit(logger)) {
    logger.info('The API limit is exceed, do not try to ensure manual order.');
    return data;
  }

  const manualOrders = await getManualOrders(logger, symbol);

  if (_.isEmpty(manualOrders) === true) {
    logger.info(
      { manualOrders },
      'Could not find manual buy order, do not process ensure-manual-order.'
    );
    return data;
  }

  const removeStatuses = ['CANCELED', 'REJECTED', 'EXPIRED', 'PENDING_CANCEL'];

  // Check if manual-order is existing
  // eslint-disable-next-line no-restricted-syntax
  for (const rawOrder of manualOrders) {
    const { order } = rawOrder;
    logger.info({ order }, 'Start checking buy order');
    // If filled already, then calculate average price and save
    if (order.status === 'FILLED') {
      logger.info(
        { order, saveLog: true },
        'The manual order has already filled. Calculating last buy price...'
      );

      // Calculate last buy price if buy
      if (order.side === 'BUY') {
        await calculateLastBuyPrice(logger, symbol, order);
      }

      // Save grid trade to the database
      await saveGridTrade(logger, data, order);

      await deleteManualOrder(logger, symbol, order.orderId);

      slackMessageOrderFilled(logger, symbol, order.side, order);
    } else if (removeStatuses.includes(order.status)) {
      // If order is no longer available, then delete from cache
      await deleteManualOrder(logger, symbol, order.orderId);

      slackMessageOrderDeleted(logger, symbol, order.side, order);
    } else {
      logger.info(
        { order, currentTime: moment().format() },
        'Skip checking the order'
      );
    }
  }

  return data;
}
Ensure manual buy order is placed

@param {*} logger
@param {*} rawData