Class SellerIdFilter

Selects offers based on whether or not certain seller_ids are present.

This filter only works with FILLZ.SOURCE.ABEBOOKS.v2, FILLZ.SOURCE.AMAZONCA.v2, FILLZ.SOURCE.AMAZONDE.v2, FILLZ.SOURCE.AMAZONFR.v2, FILLZ.SOURCE.AMAZONUK.v2, FILLZ.SOURCE.AMAZONUS.v2

Class Summary

Using the SellerId filter for abebooks:

var abe = FILLZ.SOURCE.ABEBOOKS.v2;
var filter = FILLZ.FILTERS.v1;
//will keep offers only from seller_ids 12345 or 345678
var offers = abe.offers(filter.seller_id.includes(12345,345678));
//will ignore offers from seller_ids 12345 or 345678
var offers = abe.offers(filter.seller_id.excludes(12345,345678));

Using the SellerId filter for amazon:

var amazon = FILLZ.SOURCE.AMAZONUS.v2;
var filter = FILLZ.FILTERS.v1;
//will keep offers only from seller_ids example_seller1 and example_seller2
var offers = amazon.offers(filter.seller_id.includes('example_seller1', 'example_seller2'));
//will ignore offers from seller_ids example_seller1 and example_seller2
var offers = amazon.offers(filter.seller_id.excludes('example_seller1', 'example_seller2'));

WARNING:

  • for AMAZON sources, the seller_id's are strings

Methods

  • includes(values)

    Returns true if Offer seller_id is one of the values

  • excludes(values)

    Returns true if Offer seller_id is not one of the values