Zakeke uses cookies to provide necessary site functionality and improve your experience. By using our website, you agree to our privacy policy and our cookie policy.   

API Integration

Shopping Cart page

The shopping cart page of your e-commerce website will have to manage the products with the designs created by the ZAKEKE customizer.

For each customised product in the shopping cart you will have to show, in addition to the basic product information:

Below is an example of a shopping cart with a Zakeke custom product (where the price includes the cost of design):

Each customised product added to your shopping cart must have, in addition to the basic model information (depending on the product size defined in your ecommerce website), the following properties:

Property Data type Description
designID string Unique design ID generated by Zakeke
tempPreviewImageUrl string Image Preview URL
designUnitPrice money Design unit price to be added to the basic product price

For example, the custom cart item will be modeled by CustomizedItemCart, which in turn inherits from ItemCart (C# language):

    public class CustomizedItemCart : ItemCart
    {
        public string designID {get;set;}        
        public string tempPreviewImageUrl {get;set;}        
        public decimal designUnitPrice {get;set;}
    }
    public class ItemCart
    {
        public string productID {get;set;}
        public string productName {get;set;}
        public decimal price {get;set;}
        public int quantity {get;set;}
        public int? color {get;set;}
        public int? size {get;set;}
    }

Additional information for a custom product in the shopping cart must be obtained by making an API REST request at the endpoint:

GET https://api.zakeke.com/v1/designs/{designID}

Where designID is the design ID obtained by the customizer (please refer to DESIGN API documentation).

Usually this request must be made in the server-side code of the "AddToCart" and "EditProductIntoCart" endpoints of the customizer (see examples in ASP. NET MVC C# in the reference section) in order to, respectively, add and modify a custom product.

Edit design button

Edit design button, for each product into shopping cart, consists in a html link to customizer as follows:

https://your.store.com/customizer.html?productid={productid}&quantity={quantity}&designid={designid}&selectedattributekey1={selectedattributevalue1}&..&selectedattributekeyn={selectedattributevaluen}

Where the parameters are defined in this table:

Parameter Data type Description
productid string Unique product identifier
quantity integer Customizable product quantity to be edited
designid string Unique design ID of design to be edited
selectedattributes key-value pair
selectedattributekey-selectedattributevalue
key-value pair of selected product attributes
N.B. the attribute keys match those imported from CSV

Example of link for editing:

https://your.store.com/customizer.html?productid=A100&quantity=1&designid=000-O3nyDBirb0a2XA49mnbmtQ&color=1&size=1