__construct()
__construct(string $recipient, array<mixed,string> $addWordPair = array(null, null), array<mixed,string> $removeWordPair = array(null, null))
Creates a new group auto update rule.
When the given recipient receives a mobile originated SMS
containing keywords (first and/or second) matching the given
add
pair then the sender MSISDN is added to the group.
Similarly, if the MO is matching the given remove
keyword
pair then the MSISDN is removed from the group.
The add and remove keyword pair may contain null
for those
keywords that should not be considered. For example,
new GroupAutoUpdate('12345', ['add', null], ['remove', null])
or equivalently
new GroupAutoUpdate('12345', ['add'], ['remove'])
would trigger based solely on the first keyword of the MO message. On the other hand,
new GroupAutoUpdate('12345', ['alert', 'add'], ['alert', 'remove'])
would trigger only when both keywords are given in the MO message.
Parameters
string | $recipient | recipient that triggers this rule |
array<mixed,string> | $addWordPair | pair containing the |
array<mixed,string> | $removeWordPair | pair containing the |