0

Is there a way to feed a list of values to an ET object search_filter so that it will match on any of the strings in the list?

email_list = ['email1@gmail.com', 'email2@gmail.com', 'email3@gmail.com']
getSubscriber = ET_Client.ET_Subscriber()
getSubscriber.auth_stub = stubObj
getSubscriber.props = ["ID","SubscriberKey"]
getSubscriber.search_filter = {'Property' : 'SubscriberKey','SimpleOperator' : 'equals','Value' : email_list}

I tried this and it did not pull anything. Is something like this possible with FuelSDK search_filter?

| improve this question | | | | |
  • Have you tired looping it? You – Samuel Dare Jul 12 '17 at 17:33
  • I considered doing that, but wouldn't that eat up a lot of API calls if I was using a large list? – HeaviestMatter Jul 12 '17 at 17:34
0

Try using 'IN' instead of 'equals'

getSubscriber.search_filter = {'Property' : 'SubscriberKey','SimpleOperator' : 'IN','Value' : email_list}

| improve this answer | | | | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.