Methods¶
Here’s a list of available methods to use with ePages Client. Each method accepts a single dict parameter called params. The more detailed description of the param is found in the usage document. Method descriptions have a link to the ePages API, too.
Customers¶
get_customers¶
This method fetches all customers from the shop.
Required parameters: none
get_customer¶
This method fetches single customer from the shop.
Required parameters: Customer id in param1
add_customer¶
This method adds a customer to the shop.
Required parameters: Instance of CustomerCreate in object
Note: When adding a customer, only the Address object must have something in some instance variable. It doesn’t matter which variable it is. The Address object is in the billingAddress instance variable of CustomerCreate.
update_customer¶
This method updates an existing customer in the shop.
Required parameters: Customer id in param1
Note: When updating customer, an instance of CustomerUpdate is not required. If the instance of CustomerUpdate is not sent or it is empty, nothing is updated.
Legal information¶
get_legal_information¶
This method gets hyperlinks of legal information for a shop.
Required parameters: none
get_contact_information¶
This method gets the contact information of a shop.
Required parameters: none
get_privacy_policy¶
This method gets the privacy policy of a shop.
Required parameters: none
get_terms_and_conditions¶
This method gets the terms and conditions of a shop.
Required parameters: none
get_rights_of_withdrawal¶
This method gets the customer rights of withdrawal of a shop.
Required parameters: none
get_shipping_information¶
This method gets the detailed information on possible shipping types and the costs incurred.
Required parameters: none
update_contact_information¶
This method updates the contact information of a shop.
Required parameters: locale must be set
update_privacy_policy¶
This method updates the privacy policy of a shop.
Required parameters: locale must be set
update_terms_and_conditions¶
This method updates the terms and conditions of a shop.
Required parameters: locale must be set
update_rights_of_withdrawal¶
This method updates the customer rights of withdrawal of a shop.
Required parameters: locale must be set
update_shipping_information¶
This method updates the shipping information of a shop.
Required parameters: locale must be set
Orders and carts¶
get_orders¶
This method gets the orders from a shop.
Required parameters: none
get_order¶
This method gets the information of a single order.
Required parameters: Order id in param1
get_order_documents¶
This method gets finalized invoice and credit note order documents of a single order.
Required parameters: Order id in param1
get_sales¶
This method gets the summary of sales figures.
Required parameters: none
get_cart¶
This method gets a single cart from a shop.
Required parameters: Cart id in param1
add_cart¶
This method adds a cart for a shop.
Required parameters: none
add_coupon¶
This method applies a coupon code on a cart of a shop.
Required parameters: Cart id in param1, coupon code in data
delete_coupon¶
This method deletes a coupon from a cart and recalculates cart.
Required parameters: Cart id in param1, coupon line item id in param2
add_cart_line_item¶
This method adds a product line item in a cart.
Required parameters: Cart id in param1, instance of ProductLineItemCreate in object
update_cart_line_item¶
This method updates a product line item in a cart.
Required parameters: Cart id in param1, product line item id in param2, instance of ProductLineItemUpdate in object
delete_cart_line_item¶
This method deletes a product line item from a cart.
Required parameters: Cart id in param1, product line item id in param2
add_order¶
This method adds an order to a shop.
Required parameters: Cart id in param1
Note: Before creating an order, the billing address must be set in a cart. Billing address can be set after cart creation using the update_billing_address method.
update_order¶
This method updates an order.
Required parameters: Order id in param1
update_billing_address¶
This method updates the billing address for a cart.
Required parameters: Cart id in param1
delete_billing_address¶
This method deletes the billing address from a cart.
Required parameters: Cart id in param1
update_shipping_address¶
This method updates the shipping address for a cart.
Required parameters: Cart id in param1
delete_shipping_address¶
This method deletes the shipping address from a cart.
Required parameters: Cart id in param1
Products¶
get_shop_info¶
This method gets the public information of a shop, like name, slogan and logo.
Required parameters: none
get_categories¶
This method gets the product categories of a shop.
Required parameters: none
get_category¶
This method gets a single product category of a shop.
Required parameters: Category id in param1
get_currencies¶
This method gets the currency information from a shop.
Required parameters: none
get_locales¶
This method gets the locale information from a shop.
Required parameters: none
get_products¶
This method gets all of the products from a shop.
Required parameters: none
get_product¶
This method gets a single product from a shop.
Required parameters: Product id in param1
get_product_variations¶
This method gets links to product variations.
Required parameters: Product id in param1
get_product_images¶
This method gets product images with links to different sizes of the images.
Required parameters: Product id in param1
get_product_image_names¶
This method gets product image names in the order they appear in a shop.
Required parameters: Product id in param1
get_product_custom_attributes¶
This method gets the user-defined product attributes with their values.
Required parameters: Product id in param1
get_product_lowest_price¶
This method gets the lowest price of all variations of a product.
Required parameters: Product id in param1
search_products¶
This method searches products with a query.
Required parameters: Query string in query
get_shipping_methods¶
This method gets the shipping methods of a shop.
Required parameters: none
get_shipping_method¶
This method gets a single shipping method of a shop.
Required parameters: Shipping method id in param1
get_tax_classes¶
This method gets the tax classes of a shop.
Required parameters: none
get_tax_class¶
This method gets a single tax class of a shop.
Required parameters: Tax class id in param1
get_tax_model¶
This method gets the tax model of a shop.
Required parameters: none
add_category¶
This method adds a subcategory to existing main category.
Required parameters: Main category id in param1, instance of CategoryCreate in object
update_category¶
This method updates a single category.
Required parameters: Category id in param1, instance of CategoryUpdate
Note: When updating a category, at least category id and category alias must be set. Category id must be the same that is set in param1, and alias can’t be the same than some other category has. So, alias must be set always and it must be the same it was or something else that other categories have.
delete_category¶
This method deletes a single category.
Required parameters: Category id in param1
get_subcategory_sequence¶
This method gets the order of subcategories for the main category.
Required parameters: Main category id in param1
update_subcategory_sequence¶
This method updates the order of subcategories.
Required parameters: Main category id in param1, instance of CategorySequenceUpdate in object
add_product¶
This method adds a new product for a shop.
Required parameters: Instance of ProductCreate
update_product¶
This method updates an existing product of a shop.
Required parameters: Product id in param1, instance of ProductUpdate
delete_product¶
This method deletes a product from a shop.
Required parameters: Product id in param1
upload_product_image¶
This method uploads an image for a product.
Required parameters: Product id in param1, image file in binary in data
Note: This doesn’t set the uploaded image in the main image of a product, even if uploaded image is the first image of the product. It must be set using update_product method.
delete_product_image¶
This method deletes a image from a product.
Required parameters: Product id in param1, image name in param2
update_product_image_sequence¶
This method updates the order of product images.
Required parameters: Product id in param1, instance of ProductSlideshowSequenceUpdate in object
get_updated_products¶
This method gets updated products by product attributes.
Required parameters: Product attribute in param1
Note: At the time of writing only stocklevel attribute works for this.
connect_category_and_product¶
This method connects categories and products.
Required parameters: Category and product id in data
Note: There can be more than one category or product id when connecting them to each other. Category id and product id values can be a list of ids, too.
disconnect_product_and_category¶
This method disconnects categories and products.
Required parameters: Category and product id in query
Note: There can be more than one category or product id when disconnecting them from each other. Category id and product id values can be a list of ids, too.
get_watched_products¶
This method lists products that are watched by customers.
Required parameters: none
get_product_csv¶
This method returns a CSV file with all products of the shop. This doesn’t work at the time of writing.
Required parameters: none