diff --git a/README.md b/README.md index d6c0d31..1e5b0ce 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,23 @@ var_dump($info); ## Changelog: +### _Differences between **v1.2.9** and **v1.2.10**_ +#### New methods: + +* **ScheduleSendNewsletterToLists** +> *Definition:* +> ```php +> public function ScheduleSendNewsletterToLists($newsletterid = false, $timeToSend = false, $listids = array()) +>``` +
+ +* **ScheduleSendNewsletterToSegments** +> *Definition:* +> ```php +> public function ScheduleSendNewsletterToSegments($newsletterid = false, $timeToSend = false, $segmentids = array())) +>``` +
+ ### _Differences between **v1.2.7** and **v1.2.9**_ #### Method definition changed: diff --git a/src/ApiParser.class.php b/src/ApiParser.class.php index 4fc8226..530bb39 100644 --- a/src/ApiParser.class.php +++ b/src/ApiParser.class.php @@ -1335,6 +1335,36 @@ public function ScheduleSendNewsletter($campaignid = false, $hours = false, $sav return self::REQUEST_FAILED; } + public function ScheduleSendNewsletterToLists($newsletterid = false, $timeToSend = false, $listids = array()) + { + $url = $this->URL . '/Sends/ScheduleSendNewsletterToLists'; + if($newsletterid && !empty($listids)) + { + $params = array( + 'newsletterid' => $newsletterid, + 'timeToSend' => $timeToSend, + 'listids' => $listids + ); + return $this->MakePostRequest($url, $params); + } + return self::REQUEST_FAILED; + } + + public function ScheduleSendNewsletterToSegments($newsletterid = false, $timeToSend = false, $segmentids = array()) + { + $url = $this->URL . '/Sends/ScheduleSendNewsletterToSegments'; + if($newsletterid && !empty($segmentids)) + { + $params = array( + 'newsletterid' => $newsletterid, + 'timeToSend' => $timeToSend, + 'segmentids' => $segmentids + ); + return $this->MakePostRequest($url, $params); + } + return self::REQUEST_FAILED; + } + /** * ScheduleSendSMS * Schedule SMS campaign for sending.