@@ -0,0 +1,2397 @@
+# -*- coding: UTF-8 -*-%0A'''%0A    magento.checkout%0A%0A    Checkout API for magento%0A    Allows you to manage shopping carts and the checkout process.%0A%0A    :copyright: (c) 2010 by Sharoon Thomas.%0A    :copyright: (c) 2010 by Openlabs Technologies & Consulting (P) LTD.%0A%0A    :license: AGPLv3, see LICENSE for more details%0A'''%0A%0Afrom .api import API%0A%0A%0Aclass Cart(API):%0A    %22%22%22%0A    Allows you to manage shopping carts.%0A    %22%22%22%0A    __slots__ = ()%0A%0A    def create(self, store_view=None):%0A        %22%22%22%0A        Create an empty shopping cart (quote).%0A%0A        :param store_view: Store view ID or code%0A        :return: integer, ID of the created empty shopping cart%0A        %22%22%22%0A        return self.call('cart.create', %5Bstore_view%5D)%0A%0A    def info(self, quote_id, store_view=None):%0A        %22%22%22%0A        Retrieve full information about the shopping cart (quote).%0A%0A        :param quote_id: Shopping cart ID (quote ID)%0A        :param store_view: Store view ID or code%0A        :return: dict representing shopping cart info%0A        %22%22%22%0A        return self.call('cart.info', %5Bquote_id, store_view%5D)%0A%0A    def license(self, quote_id, store_view=None):%0A        %22%22%22%0A        Retrieve the website license agreement for the quote according to the%0A        website (store).%0A%0A        :param quote_id: Shopping cart ID (quote ID)%0A        :param store_view: Store view ID or code%0A        :return: dict representing shopping cart license%0A        %22%22%22%0A        return self.call('cart.license', %5Bquote_id, store_view%5D)%0A%0A    def order(self, quote_id, store_view=None, license_id=None):%0A        %22%22%22%0A        Allows you to create an order from a shopping cart (quote).%0A        Before placing the order, you need to add the customer, customer%0A        address, shipping and payment methods.%0A%0A        :param quote_id: Shopping cart ID (quote ID)%0A        :param store_view: Store view ID or code%0A        :param license_id: Website license ID%0A        :return: string, result of creating order%0A        %22%22%22%0A        return self.call('cart.order', %5Bquote_id, store_view, license_id%5D)%0A%0A    def totals(self, quote_id, store_view=None):%0A        %22%22%22%0A        Allows you to retrieve total prices for a shopping cart (quote).%0A%0A        :param quote_id: Shopping cart ID (quote ID)%0A        :param store_view: Store view ID or code%0A        :return: dict representing shopping cart totals%0A        %22%22%22%0A        return self.call('cart.totals', %5Bquote_id, store_view%5D)%0A

Add checkout.py class Cart