Combining filters.

Comments

3 comments

  • Avatar
    Ivan Dedov

    To achieve this you should use the conditions parameter of the /createMessage request. You can learn more in this section of our Remote API Guide:

    http://docs.pushwoosh.com/docs/createmessage#tag-conditions

    Please keep in mind that “filter” and “conditions” parameters should not be used together. Also, both of them will be ignored, if the "devices" parameter is used in the same request.

  • Avatar
    Vladimir Kozhevnikov

    Could you please write the condition for my example?

  • Avatar
    Ivan Dedov

    Actually, if you want to send push for those users who match at least one of the filters, you should use /createTargetedMessage request. Sorry for not seeng it from the start, please refer to our Guide for details:

    http://docs.pushwoosh.com/docs/createtargetedmessage

    In your case the conditions should look like this:

    "devices_filter": "A(\"your_appcode\") * (T(\"mornign_pushes_enabled\", EQ, \"true\") + T(\"fresh_news\", EQ, \"ANIMALS\") + T(\"funny_videos\", EQ, \"CATS\"))" }

Please sign in to leave a comment.