GetProductList

From Wiki

Revision as of 12:20, 25 February 2014 by Nazar Yareshko (Talk | contribs)
(diff) ← Older revision | Current revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Retrieves a product list based on a product search query or advertiser ID (oActiveRefineByGroup)

Parameters


sQuery optional

The search query

Value Type: string
Example: jeans

iAdult optional

Allow adult content

Value Type: int
Example: 0

bHotPick optional

Include only the advertisers top products

Value Type: bool
Example: true

sSort optional

The order in which to return the product

Value Type: ProductListSortOption
Example: az

iOffset optional

From which point onwards in the list to return products from

Value Type: int
Example: 0

iLimit optional

The maximum number of products to return

Min: 0 Max: 100 Value Type: int
Example: 100

oActiveRefineByGroup optional

Objects containing any active refine bys

Value Type: RefineByGroup

iLimitRefineBy optional

Maximum number of refine bys to return

Value Type: int

sMode optional

The mode to perform server-side searches in

Value Type: SearchProductModeOption
Example: all

iEnabledRefineBy optional

The refine bys to return with our searches

Value Type: int

sColumnToReturn optional

Columns to return with each product. By default only required columns are returned. Add as many columns as you require from the Product_PSAPI data type to your API call to get more data.

Value Type: string/array
Example: array('sBrand','sDescription')


Response


oProduct

Array of product objects

Value Type: Product

iTotalCount

Total count of products found

Value Type: int

oActiveRefineByGroup

Objects containing any active refine bys

Value Type: RefineByGroup

oRefineByGroup

Objects containing any remaining available refine bys

Value Type: RefineByGroup


Example Request (parameters)


$oRefineByDefinition = new stdClass();
$oRefineByDefinition->sId = 1203;
$oRefineByDefinition->sName = '';
$oRefineBy->oRefineByDefinition = $oRefineByDefinition;

$aParams7 = array(
	"sQuery"		=>	"jeans",
	"bAdult"		=>	0,
	"iOffset"		=>	0,
	"iLimit"		=>	100,
	"oActiveRefineByGroup"	=>	$oRefineBy,
	"sColumnToReturn"	=>	array("sDescription","sBrand"));


Example Response


stdClass Object
(
    [oProduct] => Array
        (
            [0] => stdClass Object
                (
                    [iId] => ...
                    [iCategoryId] => ...
                    [iMerchantId] => ...
                    [iAdult] => 0
                    [sName] => ...
                    [sDescription] => ...
                    [sBrand] => ...
                    [sAwDeepLink] => ...
                    [sAwThumbUrl] => ...
                    [fPrice] => ...
                )

            [1] => stdClass Object
                (
                    [iId] => ...
                    [iCategoryId] => ...
                    [iMerchantId] => ...
                    [iAdult] => 0
                    [sName] => ...
                    [sDescription] => ...
                    [sBrand] => ...
                    [sAwDeepLink] => ...
                    [sAwThumbUrl] => ...
                    [fPrice] => ...
                )
...

Limitations/Notes

  • Maximum number of products to return is 1,000
    • The maximum 'iOffset' = 1,000 - 'iLimit'

Privacy

Due to new European legislation regarding how websites store information about you, AWIN is updating its privacy policy. You can see the new version of our policy here. If you would like to see the information we capture on this website, please click here for further details. In order to accept cookies on this site please click the 'I ACCEPT' button