This is the API docs for LemonStand V1, which has been discontinued. LemonStand is now a cloud based platform, available at lemonstand.com.

LemonStand API

shop:onOrderBeforeCreate event

Triggered by Shop_Order
Author LemonStand eCommerce Inc.

Event handler signature

public void event_onOrderBeforeCreate(string $cart_name)
$cart_name string specifies the shopping cart name.
Allows you to alter the checkout information or cart content before an order is placed. This event is fired only when an order is placed from the front-end website.
public function subscribeEvents()
{
  Backend::$events->addEvent('shop:onOrderBeforeCreate', $this, 'process_order');
}

public function process_order($cart_name)
{
  $price = Shop_Cart::total_price($cart_name);
  if ($price < 100)
    throw new Phpr_ApplicationException('We are sorry, 
      you cannot place orders with total order amount less than 100 USD');
}