Skip to content
On this page

PRODUCTS

URLs

Filtering

In order to get products based on a filter, you can use one of the available filters. Product filtering is similar to the advanced search performed in the admin panel.

The request URL is as follows (separated into several lines for readability):

https://api.ichhabnemacke.de/products?

<filter>=Y&

<additional_param>=<value>&

<another_param>=<value>&

...

sort_by=<sorting>&

sort_order=<sort_order>&

q=<query>

  • filter is one of the available filters. It is possible to use any number of filters at a time by appending the URL with &<another_filter>=Y
  • additional_param is one of the available additional params. It is possible to use any number of additional params at a time by appending the URL with &<another_param>=<value>
  • sorting is one of the available sortings
  • sort_order is the sort direction; asc or desc for ascending and descending accordingly
  • query is the search query

Filters

Available filter attribute values:

FilterDescription
pnameProduct name
pshortShort description
pfullFull description
pkeywordsMeta keywords
pcodeProduct code
cidCategory ID
amount_fromIn stock lower range
amount_toIn stock higher range
price_fromPrice lower range
price_toPrice higher range

Additional Params

ParamDescriptionSupported values
subcatsInclude subcategories of the given category (the cid filter must be used) in the search scopeYN
order_idsIDs of the orders to search the products inComma-separated list of order IDs, e.g. 1,13,24
free_shippingFree shippingYN
statusProduct status:A for ActiveD for DisabledH for HiddenADH

Sorting

Sort paramDescription
statusProduct status
list_priceList price
productProduct name
pricePrice
codeProduct code
amountIn stock amount

It is possible to set the sort order by defining the sort_order URL param to asc or desc.

Pagination

To get a specific number of products or list of products from a concrete page in a response, use pagination parameters:

Pagination paramDescription
pageShows products on a page with the defined number
items_per_pageShows N products, where N - is a number defined in the parameter

Examples

GET-Requests

Response is an array with 10 products from the 5th page (10 is the default value of the items_per_page parameter).

Response is an array with 20 products from the first page.

Response is an array with 20 products from the 5th page.

(PUT) Update Stock-Amount from Product

sh
PUT  /products/:productID

Example JSON-Body: Update Product-Amount

js
{
    "code": "ART_32231",  //PRODUCT_ID
    "amount": "1"
}

Fields

A product has a number of properties, represented by fields.

The full list of supported fields is given below (mandatory fields are marked with *).

Any field not listed in the table below will be ignored if occurs in an API request JSON data.

Field nameDescriptionDefault valueSupported values
product*Product namestring
category_ids*IDs of the categories to which the product belongsArray of valid category IDs
main_category*ID of the main categoryExisting category ID
price*Price0float
status*Product status:A for ActiveD for DisabledH for HiddenAADH
amountProduct amount in stock1integer
avail_sinceDate from which the product is availableDate in UNIX format
box_heightBox height0integer
box_lengthBox length0integer
box_widthBox width0integer
details_layoutProduct details page layout‘default’Valid product template name
edp_shippingOnly for a downloadable product: Enable/disable shippingNYN
exceptions_typeException type (Allow/ Forbid products with certain option combinations)FAF
feature_comparisonEnable/disable adding the product to a feature comparison listNYN
free_shippingAllow free shippingNYN
full_descriptionFull product description‘’string
image_pairsAdditional image pairsempty arrayobject with image pair ID as key and image pair as value (see below)
is_edpDownloadable or notNYN
lang_codeLanguage codeDefault language codeenruetc.
list_priceManufacturer suggested price0float
list_qty_countNumber of items in the quantity select box0integer
localizationString of comma-separated localization IDs‘’string
low_avail_limitMinimal availability in stock value0integer
main_pairFull image and thumbnail pairempty arrayMain pair object (see below)
max_items_in_boxMaximal number of items per box0integer
max_qtyMaximal order quantity0integer
meta_descriptionMeta description‘’string
meta_keywordsMeta keywords‘’string
min_items_in_boxMinimal number of items per box0integer
min_qtyMinimal order quantity0integer
options_typeApply options simultaneously (P) or sequentially (S)PSP
out_of_stock_actionsOut of stock action:N for NoneB for Buy in advanceS for Sign up for notificationNNBS
product_codeProduct code‘’string
product_featuresProduct featuresempty arrayobject that contains product features with feature ID as key and feature data as value
product_idProduct IDSet automaticallyinteger
promo_textPromo text‘’string
qty_stepQuantity step0integer
return_periodReturn period in days10integer
sales_amountSales amount0integer
search_wordsSearch keywords for the product‘’string
seo_nameSEO name for the product page‘’string
shared_productShared or notNYN
shipping_freightShipping freight0float
shipping_paramsAggregated shipping dataAuto-generated string based on the shipping datastring
short_descriptionShort description‘’string
tax_idsArray of tax IDsempty arrayarray
timestampCreation timestampSet automaticallyValid timestamp in UNIX format
trackingInventory tracking modeB for TrackD for do not trackBBD
updated_timestampLast update timestampLast update timestamp in secondsValid timestamp in UNIX format
usergroup_idsUser group IDs‘0’String of comma-separated user group IDs
weightWeight0float
zero_price_actionZero price actionR for Do not allow customers to add product to cartP for Allow customers to add product to cartA for Ask customer to enter the priceRRPA

Main Pair (Product-Image)

A pair of the full product image and (optionally) a thumbnail.

Field nameDescriptionDefault valueSupported values
detailed_idID of the full imageSet automaticallyinteger
image_idID of the thumbnail0integer
pair_idID of the image pairSet automaticallyinteger
positionPosition of the image pair among others0integer
iconThumbnail dataobject (similar to detailed, see below)
detailedFull image dataobject (content explained below)
absolute_pathAbsolute filesystem path to the imageValid filesystem path
altAlternative text (show if the image fails to load)‘’string
http_image_pathHTTP path to the imageValid HTTP URL pointing to the image
image_pathActual image path (HTTP or HTTPS; may be the same as http_image_path)Valid URL pointing to the image
image_xImage width in pixelsinteger
image_yImage heightinteger

Copyright © Ich hab ne Macke GmbH 2024