- Update simpletest/simpletest package to verison 1.2.0
- Update test suite to support PHP 7
- Update package to support PHP 8
- Upgrades to Createsend API v3.3 which includes new breaking changes
- Breaking: client sent campaigns endpoint is now paginated and filtered
- Added new client tags endpoint
- Added support for returning campaign tags as part of sent, draft and scheduled campaign endpoints
- Added support for returning campaign name as part of campaign summary endpoint
- Added sample script for get client tags endpoint
- Adding support for returning ListJoinedDate for each subscriber.
- List.Active()
- List.Bounced()
- List.Unsubscribed()
- List.Unconfirmed()
- List.Deleted()
- Segment.Subscribers()
- Subscriber.Get()
- Changed local API timeout from 20 secs to 120 secs to cater for changes on get segment subscribers API endpoint.
- Add PHP 7.4 Support
- Added support for the Journeys API (https://www.campaignmonitor.com/api/journeys/)
- Upgrades to Createsend API v3.2 which includes new breaking changes
- Breaking: 'Consent to track' field is now mandatory for sending smart and classic transactionl emails
- Breaking: 'Consent to track' field is now mandatory when adding or updating subscribers
- Optional 'Include tracking preference' field when retrieving lists of subscribers
- Changed local API timeout from 10 sec to 20 sec
- Added support for Behavioral Event data
- Prevent definition re-declarations
- Changed the fatal error thrown when unable to communicate with the API into a catchable Exception
- Added PHP7 support
- Fixed the transactional smart email call for get_list() so it now passes the client id
- Added support for Transactional Email
- Updated constant definitions so PHP Notices aren't raised
- Updated the class_exists check to no longer call __autoload
- Updated to v3.1 API
- Added support for new segments structure
-
Segment now includes a new
RuleGroups
member, instead of aRules
member.So for example, when you _previously_ would have created a segment like so: ```php $result = $wrap->create('Segments List ID', array( 'Title' => 'Segment Title', 'Rules' => array( array( 'Subject' => 'EmailAddress', 'Clauses' => array( 'CONTAINS example.com' ) ) , array( 'Subject' => '[customfield]', 'Clauses' => array( 'PROVIDED', 'EQUALS 1' ) ) ) )); ``` You would _now_ do this: ```php $result = $wrap->create('Segments List ID', array( 'Title' => 'Segment Title', 'RuleGroups' => array( array( 'Rules' => array( array( 'RuleType' => 'EmailAddress', 'Clause' => 'CONTAINS example.com' ) ) ) , array( 'Rules' => array( array( 'RuleType' => '[customfield]', 'Clause' => 'PROVIDED' ) , array( 'RuleType' => '[customfield]', 'Clause' => 'EQUALS 1' ) ) ) ) ));
-
The Add Rule call is now Add Rule Group, taking a
ruleGroup
argument instead of arule
argument.function CS_REST_Segments->add_rulegroup($rulegroup)
So for example, when you previously would have added a rule like so:
$wrap = new CS_REST_Segments('Segment ID', $auth); $result = $wrap->add_rule(array( 'Subject' => 'EmailAddress', 'Clauses' => array('CONTAINS example.com') ));
You would now do this:
$wrap = new CS_REST_Segments('Segment ID', $auth); $result = $wrap->add_rulegroup(array( 'Rules' => array( array( 'RuleType' => 'EmailAddress', 'Clause' => 'CONTAINS example.com' ) ) ));
-
- Removed the get_apikey method to promote usage of oAuth authentication
- Fixed a notice that was raised when unscheduling a campaign.
- Only set the
CURLOPT_CAINFO
option if not already set globally via the ini system.
- Made it harder to accidentally email your subscribers when using the example code
- Added support for single sign on which allows initiation of external login sessions to Campaign Monitor.
- Added support for authenticating using OAuth. See the README for full usage instructions.
-
This introduces some changes to how you authenticate using this library. You now authenticate by passing an
$auth
array as the first argument when creating instances of any classes which inherit from theCS_REST_Wrapper_Base
class.So in existing code, when you previously would have authenticated using an API key as follows:
$wrap = new CS_REST_General('Your API Key'); $result = $wrap->get_clients();
If you want to authenticate using an API key, you should now do this:
$wrap = new CS_REST_General(array('api_key' => 'Your API Key')); $result = $wrap->get_clients();
-
- Removed simpletest source files, and added simpletest as a dev dependency.
- Fixed autoloading with composer, so that only necessary classes are loaded.
- Use CURLOPT_TIMEOUT and CURLOPT_CONNECTTIMEOUT constants instead of CURLOPT_TIMEOUT_MS and CURLOPT_CONNECTTIMEOUT_MS.
- Added autoloading support when using Composer (PHP dependency management).
- Added support for including from name, from email, and reply to email in drafts, scheduled, and sent campaigns.
- Added support for campaign text version urls.
- Added support for transferring credits to/from a client.
- Added support for getting account billing details as well as client credits.
- Made all date fields optional when getting paged results.
- Added CS_REST_Campaigns.get_email_client_usage().
- Added support for ReadsEmailWith field on subscriber objects.
- Added support for retrieving unconfirmed subscribers for a list.
- Added support for suppressing email addresses.
- Added support for retrieving spam complaints for a campaign, as well as adding SpamComplaints field to campaign summary output.
- Added VisibleInPreferenceCenter field to custom field output.
- Added support for setting preference center visibility when creating custom fields.
- Added the ability to update a custom field name and preference visibility.
- Added documentation explaining that TextUrl is now optional when creating a campaign.
- Fixed timeout issue by setting CS_REST_SOCKET_TIMEOUT to 10 seconds.
- Fixed #13. Load services_json.php only if Services_JSON class doesn't already exist.
- Fixed issue with curl calls hangs hanging on proxy failure.
- Added support for creating campaigns from templates.
- Added support for unsuppressing an email address.
- Backported fix to use Mozilla certificate bundle, as per http://curl.haxx.se/docs/caextract.html
- Added WorldviewURL field to campaign summary response.
- Added Latitude, Longitude, City, Region, CountryCode, and CountryName fields to campaign opens and clicks responses.
- Added 'Contributing' section to README.
- Used the Mozilla certificate bundle, as per http://curl.haxx.se/docs/caextract.html
- Bumping to 2.1.1
- Added support for basic / unlimited pricing.
- Removing deprecated method CS_REST_Clients.set_access().
- Removed traces of calling the API in a deprecated manner.
- Added support for UnsubscribeSetting field when creating, updating and getting list details.
- Added support for AddUnsubscribesToSuppList and ScrubActiveWithSuppList fields when updating a list.
- Added support for finding all client lists to which a subscriber with a specific email address belongs.
- Added support for specifying whether subscription-based autoresponders should be restarted when adding or updating subscribers.
- Added Travis CI support.
- Added support for team management.
- Added support for new API methods.
- Fixed subscriber import sample.
- Fixed response handling code so that it can deal with HTTP responses beginning with "HTTP/1.1 Continue".
- Fixed socket issue by added Connection:Close header for raw socket transport.
- Fixed #5. Updated recursive check_encoding call.
- Fixed #7. Modified template create/update to not require screenshot URL.
- Fixed #4. Removed static function calls.
- Initial release which supports current Campaign Monitor API.