Calling the Personalized Searc...
Personalized Category Page Queries
a personalized category page request to the pesonalized search api can occur after a customer arrives on a product category page this request is similar to a personalized site search request, but instead of searching for products based on a search term, a personalized category page request searches for products based on products' category path(s) refer to returning content page records in personalized site search queries docid\ gwgtooic olmkssgmarow for information about including category page records in response to a customer's site search query to send this type of request, change the value of the typeofrequest key to "catnav" , and then add the categorypath key to the query object the value of categorypath is the search criterion the returned products must meet the response is also similar to a personalized site search response, but it also includes the monetate category key that indicates each record's product category all functions available in personalized site search queries—such as personalized site search queries and retrieve and apply facets —are available to use in personalized category page queries refer to omnichannel personalized site search action request for the information you must provide in an engine api request for a personalized category pages experience configured with an omnichannel personalized search action name personalized category page query request method post url https engine monetate net api search v1 site search name instance domain search description tab examples examples languages id x4g4buht43rh9x eqeatk language json code n searchtoken monetate 67899982122813608004 n recordqueries n n id categoryproducts n typeofrequest catnav n settings n query n categorypath sporting goods;outdoor recreation;camping hiking n n searchprefs n enablescores n n limit 5 n typeofrecords n monetate product n n n n n customlabel example personalized category page request selectedlanguageid x4g4buht43rh9x eqeatk results languages id zsjrgszt4o7wzo9skgfzx language 200 customlabel code n queryresults n n id categoryproducts n meta n qtime 9 n noofresults 5 n totalresultsfound 68 n typeofsearch and n offset 0 n debugginginformation n notificationcode 1 n searchedterm n ispersonalised false n n records n n color orange n discount n hidegroupprices n itemgroupid 8054252208375 n capacity 2 n score 0 057294395 n freeshipping n storebasecurrency usd n price 1300 n toprice n imageurl n currency usd n instock yes n id tent 006 n imagehover n sku n brand summitate n baseprice 1300 0 n startprice n image n deliveryinfo n quantity 23 n hideaddtocart n saleprice 1300 0 n swatchesinfo n weight n totalvariants 0 n handle tent 006 n groupprices n iscustomoptionsavailable n url n name stormking tent n shortdesc tents n category tents n monetate product boosting 1 011 n monetate category monetate product;;sporting goods;outdoor recreation;camping hiking;tents ku kucategory ku n monetate manual boosting 0 9 n searchclicktoken monetate nisc2lje2njixm3aumcnze3mjexoynd n n n additional records n n n filters n n n selectedlanguageid zsjrgszt4o7wzo9skgfzx request pathparameters name name kind required type string description the client s account for example a 1db61f7a as it appears in the value of channel used in the engine api request to obtain the search token the client s account for example a 1db61f7a as it appears in the value of channel used in the engine api request to obtain the search token name instance kind required type string description the client s account environment the value must either be p for production or d for development the client s account environment the value must either be p for production or d for development name domain kind required type string description the client s domain for example product monetate me as it appears in the value of channel used in the engine api request to obtain the search token the client s domain for example product monetate me as it appears in the value of channel used in the engine api request to obtain the search token queryparameters headerparameters name content type kind required type string description the value must be application json the value must be application json bodydataparameters name searchtoken kind required type string description a token used to authenticate the search request obtained by sending a request to the engine api see obtaining a search token in calling the personalized search api for more information a token used to authenticate the search request obtained by sending a request to the engine api see obtaining a search token in calling the personalized search api for more information name recordqueries kind required type object description the set of parameters that define a personalized category pages request children name id kind required type string description the unique identifier associated with the request name typeofrequest kind required type string description the type of query request use catnav for the value name settings kind required type object description the set of key value pairs that define the settings used for search results children name query kind required type object description the set of key value pairs that define the product category to retrieve results from children name categorypath kind required type string description the name of the product category from which to retrieve results in the same case and format as mapped into personalized search and with a semicolon ; used to separate the hierarchy for example mens shoes sneakers becomes mens;shoes;sneakers name limit kind optional type number description the number of records you want displayed per results page if you don t pass this parameter in the request call then personalized search uses the default value of 12 n nyou can fetch a maximum of 100 records when you pass the limit to get more than 100 records you must define the fields array in the request call name searchprefs kind optional type array description one or more values to fine tune a query name typeofrecords kind required type string description the type of results to return use monetate product for the value schema name id kind required type string description the unique identifier associated with the request name typeofrequest kind required type string description the type of query request use catnav for the value name settings kind required type object description the set of key value pairs that define the settings used for search results children name query kind required type object description the set of key value pairs that define the product category to retrieve results from children name categorypath kind required type string description the name of the product category from which to retrieve results in the same case and format as mapped into personalized search and with a semicolon ; used to separate the hierarchy for example mens shoes sneakers becomes mens;shoes;sneakers name limit kind optional type number description the number of records you want displayed per results page if you don t pass this parameter in the request call then personalized search uses the default value of 12 n nyou can fetch a maximum of 100 records when you pass the limit to get more than 100 records you must define the fields array in the request call name searchprefs kind optional type array description one or more values to fine tune a query name typeofrecords kind required type string description the type of results to return use monetate product for the value formdataparameters currentnewparameter label body parameter value bodydataparameters response name id kind optional type string description the id of the record query for which the results are being returned name meta kind optional type object description the query related parameters children name qtime kind optional type string description the time personalized search took to fetch the response name noofresults kind optional type number description the number of results requested to be returned for this query name totalresultsfound kind optional type number description the total results found for the query name typeofsearch kind optional type string description the search method s that personalized search used to retrieve the results refer to specifying a search type in personalized site search queries for more information name offset kind optional type string description the index of the first result returned in this response name debugginginformation kind optional type string description information that can be useful for debugging the query for example the actual query that personalied search fired including any synonyms or de compounded words taken into consideration name notificationcode kind optional type number description a code indicating if any actions were taken on the record possible values are as follows n n1 nothing to report n2 the price of the record is using the base currency name searchedterm kind optional type string description the customer s search term submitted for the query name ispersonalized kind optional type boolean description whether or not customer context was applied to the results name records kind optional type object description the records matching the query each record object is a map of key value pairs where the key is the name of an attribute for example id name price and its value in the mapped product catalog children name id kind optional type string description the unique identifier of the record within personalized search name itemgroupid kind optional type string description the identifier for a group of products that come in different versions as set in the value of the item group id attribute in the mapped product catalog name name kind optional type string description the name of the record for example the product name or category title name url kind optional type string description the fully qualified url the customer used to access the record on your site name sku kind optional type string description a product s unique identifier as set in the value of the id attribute in the mapped product catalog name category kind optional type string description a list of a record s most specific categories that excludes the full path with double semicolons ;; used to separate them for example a record in both mens shoes and mens tees has a value of shoes;;tees name monetate category kind optional type string description the record s categorization within personalized search with the product name separated from its category hierarchy with double semicolons ;; and then the category hierarchy itself separated by single semicolons for example mybrand tent;;sporting goods;outdoor recreation;camping;tents name monetate manual boosting kind optional type string description the rule based merchandising score rms you set on the rule based merchandising tab of the promotions page of the personalized search user interface name monetate product boosting kind optional type string description the product level score pls you set on the product level boosting tab of the promotions page of the personalized search user interface name instock kind optional type string description whether or not the product is in stock the value is either yes or no name price kind optional type number description the original price of the product before any discounts as set in the value of the price attribute in the mapped product catalog n nyou can use this parameter as a was price when used with saleprice name saleprice kind optional type number description the actual selling price of ther product or the now price when used with price when using filters the sale price is represented by monetate price name startprice kind optional type number description the value of saleprice for the variant with the lowest price among all variants with the same item group id you can use this parameter for a as low as price name toprice kind optional type number description the value of saleprice for the variant with the highest price among all variants with the same item group id you can use this parameter for a from x to y price range name groupprices kind optional type number description the prices of a record in format groupid price so that you can use your own front end logic to display prices in real time this field isn t always populated in part because price and saleprice are automatically calculated so there s no need to use this parameter in most cases name currency kind optional type string description the currency code applicable to the price values being displayed name shortdesc kind optional type string description the short description of the record as set in the value of the description attribute in the mapped product catalog name image kind optional type string description the fully qualified url to the record s main image name imagehover kind optional type string description the fully qualified url to the record s secondary image children name totalvariants kind optional type string description the number of variants available for a product in addition to the variant in the search results for example a product included in the results for a customer s small tshirt search has 3 color variants available in size small so the value of totalvariants is 2; a search for tshirt would include the same product but with the value of totalvariants being 8 because the product comes in 3 colors each in 3 sizes name brand kind optional type string description the product s brand as set in the value of the brand attribute in the mapped product catalog name additionaldatatoreturn kind optional type string description if present for the record you can use the data to display attribute variations in one product entry on the search results page refer to displaying product variants in preparing to implement personalized search in the monetate knowledge base for more information name searchclicktoken kind optional type string description a token that contains the relevant information about the customer about the omnichannel personalized search experience and about the record the customer clicked hastryitout false using the fields array by default, records returned in the response include values for all attributes in the mapped product catalog, including custom attributes use the fields array to limit the response to the specific attribute values you want returned doing so improves response time and decreases response size as such, you should limit returned attribute values to only those you intend to render before you can include one or more custom attributes in the fields array of a request, you must first contact your dedicated csm so that monetate can enable this option