@@ -3201,50 +3201,28 @@ <h3 id='creditcardupdatepayload-field'>CreditCardUpdatePayload</h3>
32013201< h2 id ='crosssell '> CrossSell</ h2 > < p > Accessible via < a href ="#foxapi-analytics "> analytics</ a > property of < a href ="#foxapi "> FoxApi</ a > instance.</ p >
32023202
32033203< section >
3204- < h3 id ='crosssell-method ' > Methods </ h3 >
3204+ < h3 id ='crosssell-example ' > Usage example </ h3 >
32053205
32063206< section >
32073207
32083208
32093209
32103210< div class ='section-comments '> </ div >
32113211
3212- < table > < thead >
3213- < tr >
3214- < th > Method</ th >
3215- < th > Returns</ th >
3216- < th > Description</ th >
3217- </ tr >
3218- </ thead > < tbody >
3219- < tr id ='crosssell-crossselltrain '>
3220- < td > < code > < b > crossSellTrain</ b > (< nobr > <object></ nobr > < i > pointsObj</ i > , < i > {Object} pointsObj</ i > )</ nobr > </ code > </ td >
3221- < td > < code > Promise</ code > </ td >
3222- < td > Sends a collection of "points" to populate a sparse matrix for cross-sell
3223- analytics and related product tracking. The POST body is an object with a "points" key
3224- and value filled with an array of "Point" objects
3225- Example pointsObj
3212+
32263213< pre > < code > {
32273214 "points": [
32283215 {
32293216 "custID": 1,
32303217 "prodID": 4,
32313218 "chanID": 2,
3232- }
3219+ }
32333220 ]
32343221}
3235- </ code > </ pre > </ td >
3236- </ tr >
3237- < tr id ='crosssell-crosssellrelated '>
3238- < td > < code > < b > crossSellRelated</ b > (< nobr > <Int></ nobr > < i > productId</ i > , < nobr > <Int></ nobr > < i > channelId</ i > , < i > {Int} productId</ i > , < i > {Int} channelId</ i > )</ nobr > </ code > </ td >
3239- < td > < code > Promise</ code > </ td >
3240- < td > Returns JSON of what products are similar to the productId in the query params.
3241- { "products": [ RelatedProduct ] }
3242- Score == 1 means these products were purchased by the exact same set of customers.
3243- Score == 0 means no customer has purchased both of these
3244- Example Request
3245- `/v1/public/recommend/prod-prod/3?channel=2
3246- Example Response
3247- ```
3222+ </ code > </ pre >
3223+ < p > `/v1/public/recommend/prod-prod/3?channel=2</ p >
3224+
3225+ < p > ```
32483226{
32493227 "products": [
32503228 {
@@ -3260,7 +3238,44 @@ <h3 id='crosssell-method'>Methods</h3>
32603238 "score": 0
32613239 }
32623240 ]
3263- }</ td >
3241+ }</ p >
3242+
3243+
3244+
3245+ </ section >
3246+
3247+ </ section >
3248+ < section >
3249+ < h3 id ='crosssell-method '> Methods</ h3 >
3250+
3251+ < section >
3252+
3253+
3254+
3255+ < div class ='section-comments '> </ div >
3256+
3257+ < table > < thead >
3258+ < tr >
3259+ < th > Method</ th >
3260+ < th > Returns</ th >
3261+ < th > Description</ th >
3262+ </ tr >
3263+ </ thead > < tbody >
3264+ < tr id ='crosssell-crossselltrain '>
3265+ < td > < code > < b > crossSellTrain</ b > (< nobr > <object></ nobr > < i > pointsObj</ i > , < i > {Object} pointsObj</ i > )</ nobr > </ code > </ td >
3266+ < td > < code > Promise</ code > </ td >
3267+ < td > Sends a collection of "points" to populate a sparse matrix for cross-sell
3268+ analytics and related product tracking. The POST body is an object with a "points" key
3269+ and value filled with an array of "Point" objects.
3270+ This method is intended for Admin use only.</ td >
3271+ </ tr >
3272+ < tr id ='crosssell-crosssellrelated '>
3273+ < td > < code > < b > crossSellRelated</ b > (< nobr > <Int></ nobr > < i > productId</ i > , < nobr > <Int></ nobr > < i > channelId</ i > , < i > {Int} productId</ i > , < i > {Int} channelId</ i > )</ nobr > </ code > </ td >
3274+ < td > < code > Promise</ code > </ td >
3275+ < td > Returns JSON of what products are similar to the productId in the query params.
3276+ { "products": [ RelatedProduct ] }
3277+ Score == 1 means these products were purchased by the exact same set of customers.
3278+ Score == 0 means no customer has purchased both of these</ td >
32643279 </ tr >
32653280</ tbody > </ table >
32663281
0 commit comments