Skip to content

Commit faf76ab

Browse files
author
klaviyo-sdk
committed
version 7.1.2
1 parent 41d2b46 commit faf76ab

86 files changed

Lines changed: 7758 additions & 556 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ NOTE: For more granular API-specific changes, please see our [API Changelog](htt
99

1010

1111

12+
## [7.1.2] - revision 2024-02-15
13+
14+
### Fixed:
15+
16+
- Patched a bug due to incorrect handling of page_cursor
17+
1218
## [7.1.1] - revision 2024-02-15
1319

1420
### Fixed:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Klaviyo PHP SDK
22

3-
- SDK version: 7.1.1
3+
- SDK version: 7.1.2
44
- API Revision: 2024-02-15
55

66
## Helpful Resources

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "klaviyo/api",
3-
"version": "7.1.1",
3+
"version": "7.1.2",
44
"description": "PHP SDK for Klaviyo's API.",
55
"keywords": [
66
"openapitools",

lib/Configuration.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class Configuration
101101
*
102102
* @var string
103103
*/
104-
protected $userAgent = 'klaviyo-api-php/7.1.1';
104+
protected $userAgent = 'klaviyo-api-php/7.1.2';
105105

106106
/**
107107
* Debug switch (default set to false)
@@ -434,7 +434,7 @@ public static function toDebugReport()
434434
$report .= ' OS: ' . php_uname() . PHP_EOL;
435435
$report .= ' PHP Version: ' . PHP_VERSION . PHP_EOL;
436436
$report .= ' The version of the OpenAPI document: 2024-02-15' . PHP_EOL;
437-
$report .= ' SDK Package Version: 7.1.1' . PHP_EOL;
437+
$report .= ' SDK Package Version: 7.1.2' . PHP_EOL;
438438
$report .= ' Temp Folder Path: ' . self::getDefaultConfiguration()->getTempFolderPath() . PHP_EOL;
439439

440440
return $report;

lib/Model/AudiencesSubObject.php

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,8 @@ class AudiencesSubObject implements ModelInterface, ArrayAccess, \JsonSerializab
8080
* @var boolean[]
8181
*/
8282
protected static array $openAPINullables = [
83-
'included' => false,
84-
'excluded' => false
83+
'included' => true,
84+
'excluded' => true
8585
];
8686

8787
/**
@@ -308,7 +308,14 @@ public function setIncluded($included)
308308
{
309309

310310
if (is_null($included)) {
311-
throw new \InvalidArgumentException('non-nullable included cannot be null');
311+
array_push($this->openAPINullablesSetToNull, 'included');
312+
} else {
313+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
314+
$index = array_search('included', $nullablesSetToNull);
315+
if ($index !== FALSE) {
316+
unset($nullablesSetToNull[$index]);
317+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
318+
}
312319
}
313320

314321
$this->container['included'] = $included;
@@ -337,7 +344,14 @@ public function setExcluded($excluded)
337344
{
338345

339346
if (is_null($excluded)) {
340-
throw new \InvalidArgumentException('non-nullable excluded cannot be null');
347+
array_push($this->openAPINullablesSetToNull, 'excluded');
348+
} else {
349+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
350+
$index = array_search('excluded', $nullablesSetToNull);
351+
if ($index !== FALSE) {
352+
unset($nullablesSetToNull[$index]);
353+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
354+
}
341355
}
342356

343357
$this->container['excluded'] = $excluded;

lib/Model/CampaignCloneQueryResourceObjectAttributes.php

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class CampaignCloneQueryResourceObjectAttributes implements ModelInterface, Arra
7878
* @var boolean[]
7979
*/
8080
protected static array $openAPINullables = [
81-
'new_name' => false
81+
'new_name' => true
8282
];
8383

8484
/**
@@ -301,7 +301,14 @@ public function setNewName($new_name)
301301
{
302302

303303
if (is_null($new_name)) {
304-
throw new \InvalidArgumentException('non-nullable new_name cannot be null');
304+
array_push($this->openAPINullablesSetToNull, 'new_name');
305+
} else {
306+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
307+
$index = array_search('new_name', $nullablesSetToNull);
308+
if ($index !== FALSE) {
309+
unset($nullablesSetToNull[$index]);
310+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
311+
}
305312
}
306313

307314
$this->container['new_name'] = $new_name;

lib/Model/CampaignCreateQueryResourceObjectAttributes.php

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,8 @@ class CampaignCreateQueryResourceObjectAttributes implements ModelInterface, Arr
9191
'name' => false,
9292
'audiences' => false,
9393
'send_strategy' => false,
94-
'send_options' => false,
95-
'tracking_options' => false,
94+
'send_options' => true,
95+
'tracking_options' => true,
9696
'campaign_messages' => false
9797
];
9898

@@ -432,7 +432,14 @@ public function setSendOptions($send_options)
432432
{
433433

434434
if (is_null($send_options)) {
435-
throw new \InvalidArgumentException('non-nullable send_options cannot be null');
435+
array_push($this->openAPINullablesSetToNull, 'send_options');
436+
} else {
437+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
438+
$index = array_search('send_options', $nullablesSetToNull);
439+
if ($index !== FALSE) {
440+
unset($nullablesSetToNull[$index]);
441+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
442+
}
436443
}
437444

438445
$this->container['send_options'] = $send_options;
@@ -461,7 +468,14 @@ public function setTrackingOptions($tracking_options)
461468
{
462469

463470
if (is_null($tracking_options)) {
464-
throw new \InvalidArgumentException('non-nullable tracking_options cannot be null');
471+
array_push($this->openAPINullablesSetToNull, 'tracking_options');
472+
} else {
473+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
474+
$index = array_search('tracking_options', $nullablesSetToNull);
475+
if ($index !== FALSE) {
476+
unset($nullablesSetToNull[$index]);
477+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
478+
}
465479
}
466480

467481
$this->container['tracking_options'] = $tracking_options;

lib/Model/CampaignCreateQueryResourceObjectAttributesSendOptions.php

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ class CampaignCreateQueryResourceObjectAttributesSendOptions implements ModelInt
7979
* @var boolean[]
8080
*/
8181
protected static array $openAPINullables = [
82-
'use_smart_sending' => false
82+
'use_smart_sending' => true
8383
];
8484

8585
/**
@@ -302,7 +302,14 @@ public function setUseSmartSending($use_smart_sending)
302302
{
303303

304304
if (is_null($use_smart_sending)) {
305-
throw new \InvalidArgumentException('non-nullable use_smart_sending cannot be null');
305+
array_push($this->openAPINullablesSetToNull, 'use_smart_sending');
306+
} else {
307+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
308+
$index = array_search('use_smart_sending', $nullablesSetToNull);
309+
if ($index !== FALSE) {
310+
unset($nullablesSetToNull[$index]);
311+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
312+
}
306313
}
307314

308315
$this->container['use_smart_sending'] = $use_smart_sending;

lib/Model/CampaignCreateQueryResourceObjectAttributesTrackingOptions.php

Lines changed: 36 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,10 @@ class CampaignCreateQueryResourceObjectAttributesTrackingOptions implements Mode
8585
* @var boolean[]
8686
*/
8787
protected static array $openAPINullables = [
88-
'is_add_utm' => false,
89-
'utm_params' => false,
90-
'is_tracking_clicks' => false,
91-
'is_tracking_opens' => false
88+
'is_add_utm' => true,
89+
'utm_params' => true,
90+
'is_tracking_clicks' => true,
91+
'is_tracking_opens' => true
9292
];
9393

9494
/**
@@ -323,7 +323,14 @@ public function setIsAddUtm($is_add_utm)
323323
{
324324

325325
if (is_null($is_add_utm)) {
326-
throw new \InvalidArgumentException('non-nullable is_add_utm cannot be null');
326+
array_push($this->openAPINullablesSetToNull, 'is_add_utm');
327+
} else {
328+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
329+
$index = array_search('is_add_utm', $nullablesSetToNull);
330+
if ($index !== FALSE) {
331+
unset($nullablesSetToNull[$index]);
332+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
333+
}
327334
}
328335

329336
$this->container['is_add_utm'] = $is_add_utm;
@@ -352,7 +359,14 @@ public function setUtmParams($utm_params)
352359
{
353360

354361
if (is_null($utm_params)) {
355-
throw new \InvalidArgumentException('non-nullable utm_params cannot be null');
362+
array_push($this->openAPINullablesSetToNull, 'utm_params');
363+
} else {
364+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
365+
$index = array_search('utm_params', $nullablesSetToNull);
366+
if ($index !== FALSE) {
367+
unset($nullablesSetToNull[$index]);
368+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
369+
}
356370
}
357371

358372
$this->container['utm_params'] = $utm_params;
@@ -381,7 +395,14 @@ public function setIsTrackingClicks($is_tracking_clicks)
381395
{
382396

383397
if (is_null($is_tracking_clicks)) {
384-
throw new \InvalidArgumentException('non-nullable is_tracking_clicks cannot be null');
398+
array_push($this->openAPINullablesSetToNull, 'is_tracking_clicks');
399+
} else {
400+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
401+
$index = array_search('is_tracking_clicks', $nullablesSetToNull);
402+
if ($index !== FALSE) {
403+
unset($nullablesSetToNull[$index]);
404+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
405+
}
385406
}
386407

387408
$this->container['is_tracking_clicks'] = $is_tracking_clicks;
@@ -410,7 +431,14 @@ public function setIsTrackingOpens($is_tracking_opens)
410431
{
411432

412433
if (is_null($is_tracking_opens)) {
413-
throw new \InvalidArgumentException('non-nullable is_tracking_opens cannot be null');
434+
array_push($this->openAPINullablesSetToNull, 'is_tracking_opens');
435+
} else {
436+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
437+
$index = array_search('is_tracking_opens', $nullablesSetToNull);
438+
if ($index !== FALSE) {
439+
unset($nullablesSetToNull[$index]);
440+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
441+
}
414442
}
415443

416444
$this->container['is_tracking_opens'] = $is_tracking_opens;

lib/Model/CampaignMessageCreateQueryResourceObjectAttributes.php

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,8 @@ class CampaignMessageCreateQueryResourceObjectAttributes implements ModelInterfa
8585
*/
8686
protected static array $openAPINullables = [
8787
'channel' => false,
88-
'label' => false,
89-
'content' => false,
88+
'label' => true,
89+
'content' => true,
9090
'render_options' => false
9191
];
9292

@@ -354,7 +354,14 @@ public function setLabel($label)
354354
{
355355

356356
if (is_null($label)) {
357-
throw new \InvalidArgumentException('non-nullable label cannot be null');
357+
array_push($this->openAPINullablesSetToNull, 'label');
358+
} else {
359+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
360+
$index = array_search('label', $nullablesSetToNull);
361+
if ($index !== FALSE) {
362+
unset($nullablesSetToNull[$index]);
363+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
364+
}
358365
}
359366

360367
$this->container['label'] = $label;
@@ -383,7 +390,14 @@ public function setContent($content)
383390
{
384391

385392
if (is_null($content)) {
386-
throw new \InvalidArgumentException('non-nullable content cannot be null');
393+
array_push($this->openAPINullablesSetToNull, 'content');
394+
} else {
395+
$nullablesSetToNull = $this->getOpenAPINullablesSetToNull();
396+
$index = array_search('content', $nullablesSetToNull);
397+
if ($index !== FALSE) {
398+
unset($nullablesSetToNull[$index]);
399+
$this->setOpenAPINullablesSetToNull($nullablesSetToNull);
400+
}
387401
}
388402

389403
$this->container['content'] = $content;

0 commit comments

Comments
 (0)