Skip to content

Commit

Permalink
Add Klaviyo API support to Craft 3 version
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnynotsolucky committed May 6, 2024
1 parent e7e41ab commit e203707
Show file tree
Hide file tree
Showing 9 changed files with 282 additions and 661 deletions.
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Release Notes for KlaviyoConnect

## 4.2.0-beta.1

### Updated
- Uses official klaviyo/api package.
- Renamed `useSubscribeEndpoint` to `subscribe`.
- User profile now uses `external_id` instead of `id`.
- Renamed `event_id` to `unique_id`.
- Changed `identify` function to include an `$update` argument.
- `identify` action can update an existing profile.
- Updated `trackOrder` to include the order currency in the event details.

### Added
- Provide `email` and/or `phone_number` when `subscribe` is `true` to provide consent for subscription to those channels.
- Added `value_currency` to event details.

### Removed
- Removed track once event.
- Remove `profileInList` API service function.
- Removed `update-profile` action. Update profiles using identify and track endpoints instead.
- Removed `updateProfile` API service method.

## 4.1.0 2024-01-11

- Include order timestamps when synchronizing orders from the control panel
Expand Down
10 changes: 8 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
"name": "fostercommerce/klaviyoconnect",
"description": "Craft Commerce",
"type": "craft-plugin",
"version": "4.1.0",
"version": "4.2.0-beta.1",
"keywords": [
"klaviyo"
],
"homepage": "https://fostercommerce.com",
"require": {
"craftcms/cms": "^3.0.0",
"php": "^7.2 || ^8.0",
"guzzlehttp/guzzle": "^6.3.0 || ^7.2.0"
"klaviyo/api": "^7.1"
},
"autoload": {
"psr-4": {
Expand All @@ -24,5 +24,11 @@
},
"require-dev": {
"friendsofphp/php-cs-fixer": "^2.13"
},
"config": {
"allow-plugins": {
"yiisoft/yii2-composer": true,
"craftcms/plugin-installer": true
}
}
}
2 changes: 0 additions & 2 deletions src/Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

use Craft;
use craft\events\RegisterUrlRulesEvent;
use craft\services\Users;
use craft\elements\User;
use craft\base\Model;
use craft\commerce\elements\Order;
Expand All @@ -13,7 +12,6 @@
use craft\commerce\events\RefundTransactionEvent;
use craft\commerce\services\Payments;
use craft\services\Fields;
use craft\events\UserGroupsAssignEvent;
use craft\services\Utilities;
use craft\web\twig\variables\CraftVariable;
use craft\web\UrlManager;
Expand Down
Loading

0 comments on commit e203707

Please sign in to comment.