Skip to content

Commit c1ba724

Browse files
committed
V25.11.1 - 2025-11-11
1 parent 5ea7fbb commit c1ba724

File tree

5 files changed

+257
-13
lines changed

5 files changed

+257
-13
lines changed

src/ConstantContact/V3/ContactLists.php

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,10 @@ public function __construct(\PHPFUI\ConstantContact\Client $client)
2525
* @param string $include_membership_count Use to include the total number of contacts per list. Set to `active`, to count only active (mailable) contacts, or `all` to count all contacts.
2626
* @param string $name Use to get details for a single list by entering the full name of the list.
2727
* @param string $status Use to get lists by status. Accepts comma-separated status values.
28+
* @param string $channel_type Use to return lists by channel type. The default value is `email`.
29+
* @param bool $include_sms_membership_count Set to `true` to return the total number of SMS members in each list. Only applicable when `channel_type` is `sms`. Default is `false`.
2830
*/
29-
public function get(?int $limit = null, ?bool $include_count = null, ?string $include_membership_count = null, ?string $name = null, ?string $status = null) : ?array
31+
public function get(?int $limit = null, ?bool $include_count = null, ?string $include_membership_count = null, ?string $name = null, ?string $status = null, ?string $channel_type = null, ?bool $include_sms_membership_count = null) : ?array
3032
{
3133

3234
if (null !== $include_membership_count)
@@ -49,12 +51,22 @@ public function get(?int $limit = null, ?bool $include_count = null, ?string $in
4951
}
5052
}
5153

52-
return $this->doGet(['limit' => $limit, 'include_count' => $include_count, 'include_membership_count' => $include_membership_count, 'name' => $name, 'status' => $status, ]);
54+
if (null !== $channel_type)
55+
{
56+
$validValues = ['email', 'sms'];
57+
58+
if (! \in_array($channel_type, $validValues))
59+
{
60+
throw new \PHPFUI\ConstantContact\Exception\InvalidValue("Parameter channel_type with value '{$channel_type}' is not one of (" . \implode(', ', $validValues) . ') in ' . __METHOD__);
61+
}
62+
}
63+
64+
return $this->doGet(['limit' => $limit, 'include_count' => $include_count, 'include_membership_count' => $include_membership_count, 'name' => $name, 'status' => $status, 'channel_type' => $channel_type, 'include_sms_membership_count' => $include_sms_membership_count, ]);
5365
}
5466

55-
public function getTyped(?int $limit = null, ?bool $include_count = null, ?string $include_membership_count = null, ?string $name = null, ?string $status = null) : ?\PHPFUI\ConstantContact\Definition\ContactListArray
67+
public function getTyped(?int $limit = null, ?bool $include_count = null, ?string $include_membership_count = null, ?string $name = null, ?string $status = null, ?string $channel_type = null, ?bool $include_sms_membership_count = null) : ?\PHPFUI\ConstantContact\Definition\ContactListArray
5668
{
57-
$data = $this->get($limit, $include_count, $include_membership_count, $name, $status);
69+
$data = $this->get($limit, $include_count, $include_membership_count, $name, $status, $channel_type, $include_sms_membership_count);
5870

5971
return $data ? new \PHPFUI\ConstantContact\Definition\ContactListArray($data) : null;
6072
}

src/ConstantContact/V3/Emails/Activities/Schedules.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,12 @@ public function getTyped(string $campaign_activity_id) : ?array
6767
/**
6868
* POST (Create) an Email Campaign Activity Schedule
6969
*
70-
* Use this method to schedule when Constant Contact will send an email
71-
* campaign activity to contacts. Use the `scheduled_date` request body
72-
* property to enter the ISO-8601 format date that you want Constant Contact
73-
* to send the email campaign activity on.
70+
* Use this method to send an email campaign activity to contacts either
71+
* immediately or on a specific date. To send the email campaign activity
72+
* immediately, specify `0` for the `scheduled_date` request property (results
73+
* return an empty array). To send the email campaign activity on a specific
74+
* date, specify the date using the `scheduled_date` request property (results
75+
* return the scheduled date in an array).
7476
*
7577
* Before you schedule an email campaign activity, you must update the
7678
* email campaign activity and specify which contacts you want Constant

src/ConstantContact/V3/Event.php

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<?php
2+
3+
// Generated file. Do not edit by hand. Use update.php in project root.
4+
5+
namespace PHPFUI\ConstantContact\V3;
6+
7+
class Event extends \PHPFUI\ConstantContact\Base
8+
{
9+
public function __construct(\PHPFUI\ConstantContact\Client $client)
10+
{
11+
parent::__construct($client, '/v3/events/{event_id}');
12+
}
13+
14+
/**
15+
* GET details for a single event.
16+
*
17+
* Specify the `event_id` path parameter to retrieve the event's details.
18+
*
19+
*
20+
* @param string $event_id The ID that uniquely identifies the event.
21+
* @param bool $include Use to include (`true`) or exclude (`false`) event setting properties in the results.
22+
*/
23+
public function get(string $event_id, ?bool $include = null) : ?array
24+
{
25+
26+
return $this->doGet(['event_id' => $event_id, 'include' => $include, ]);
27+
}
28+
29+
public function getTyped(string $event_id, ?bool $include = null) : ?\PHPFUI\ConstantContact\Definition\EventDto
30+
{
31+
$data = $this->get($event_id, $include);
32+
33+
return $data ? new \PHPFUI\ConstantContact\Definition\EventDto($data) : null;
34+
}
35+
36+
}

src/ConstantContact/V3/Events.php

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<?php
2+
3+
// Generated file. Do not edit by hand. Use update.php in project root.
4+
5+
namespace PHPFUI\ConstantContact\V3;
6+
7+
class Events extends \PHPFUI\ConstantContact\Base
8+
{
9+
public function __construct(\PHPFUI\ConstantContact\Client $client)
10+
{
11+
parent::__construct($client, '/v3/events');
12+
}
13+
14+
/**
15+
* GET a collection of events.
16+
*
17+
* Retrieve a collection of events with event details.
18+
*
19+
* @param string $event_status Use to return only events that meet the specified status. Acceptable values include `ACTIVE`,`DRAFT`, `COMPLETE`, `DELETED`,`CANCELLED`, and `ERROR`.
20+
* @param string $search_text Use to return only events that include the specified text.
21+
* @param string $sort_by Use to sort resulting events by one of the following properties: `name`, `start_time`, `end_time`, `created_time`, or `updated_time`.
22+
* @param string $sort_order Sort order for the `sort_by parameter`. Accepted values include `ASC` (ascending) or `DESC` (descending). Defaults to `ASC` if `sort_by` is provided.
23+
* @param string $limit Limit the number of results to return per page. Default and maximum is `100`.
24+
* @param string $prev Cursor for retrieving the previous page of results. This value is obtained from the `prev_cursor` field in a previous response.
25+
* @param string $next Cursor for retrieving the next page of results. This value is obtained from the `next_cursor` field in a previous response.
26+
*/
27+
public function get(?string $event_status = null, ?string $search_text = null, ?string $sort_by = null, ?string $sort_order = null, ?string $limit = null, ?string $prev = null, ?string $next = null) : ?array
28+
{
29+
30+
return $this->doGet(['event_status' => $event_status, 'search_text' => $search_text, 'sort_by' => $sort_by, 'sort_order' => $sort_order, 'limit' => $limit, 'prev' => $prev, 'next' => $next, ]);
31+
}
32+
33+
public function getTyped(?string $event_status = null, ?string $search_text = null, ?string $sort_by = null, ?string $sort_order = null, ?string $limit = null, ?string $prev = null, ?string $next = null) : ?\PHPFUI\ConstantContact\Definition\PaginationDtoEventListingDto
34+
{
35+
$data = $this->get($event_status, $search_text, $sort_by, $sort_order, $limit, $prev, $next);
36+
37+
return $data ? new \PHPFUI\ConstantContact\Definition\PaginationDtoEventListingDto($data) : null;
38+
}
39+
40+
}

yaml/swagger.yaml

Lines changed: 159 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ swagger: "2.0"
33
info:
44
description: "The Constant Contact, Inc. V3 public API, for building integrations\
55
\ with Constant Contact, the leading small-business email marketing platform."
6-
version: "3.0.95"
6+
version: "3.0.105"
77
title: "AppConnect V3"
88
contact:
99
name: "webservices@constantcontact.com"
@@ -1290,6 +1290,142 @@ paths:
12901290
- "contact_data"
12911291
x-authorization-privileges:
12921292
- "contacts:write"
1293+
/events:
1294+
get:
1295+
tags:
1296+
- "Events"
1297+
summary: "GET a collection of events."
1298+
description: "Retrieve a collection of events with event details."
1299+
operationId: "findEvents"
1300+
produces:
1301+
- "application/json"
1302+
parameters:
1303+
- name: "event_status"
1304+
in: "query"
1305+
description: "Use to return only events that meet the specified status. Acceptable\
1306+
\ values include `ACTIVE`,`DRAFT`, `COMPLETE`, `DELETED`,`CANCELLED`, and\
1307+
\ `ERROR`."
1308+
required: false
1309+
type: "string"
1310+
x-example: "DRAFT"
1311+
- name: "search_text"
1312+
in: "query"
1313+
description: "Use to return only events that include the specified text."
1314+
required: false
1315+
type: "string"
1316+
x-example: "reunion"
1317+
- name: "sort_by"
1318+
in: "query"
1319+
description: "Use to sort resulting events by one of the following properties:\
1320+
\ `name`, `start_time`, `end_time`, `created_time`, or `updated_time`."
1321+
required: false
1322+
type: "string"
1323+
x-example: "created_time"
1324+
- name: "sort_order"
1325+
in: "query"
1326+
description: "Sort order for the `sort_by parameter`. Accepted values include\
1327+
\ `ASC` (ascending) or `DESC` (descending). Defaults to `ASC` if `sort_by`\
1328+
\ is provided."
1329+
required: false
1330+
type: "string"
1331+
x-example: "DESC"
1332+
- name: "limit"
1333+
in: "query"
1334+
description: "Limit the number of results to return per page. Default and\
1335+
\ maximum is `100`."
1336+
required: false
1337+
type: "string"
1338+
x-example: "5"
1339+
- name: "prev"
1340+
in: "query"
1341+
description: "Cursor for retrieving the previous page of results. This value\
1342+
\ is obtained from the `prev_cursor` field in a previous response."
1343+
required: false
1344+
type: "string"
1345+
x-example: "7zDEe3DhD5gUiwRFsvWKKZlZO1j6-YihH2hyVWD8GaW7JnzXbHFP8Tou212KoU20mOjvM6pdWwycDWC3X-Hb_xY-RK1eBwYp_pc4X2CvLxo."
1346+
- name: "next"
1347+
in: "query"
1348+
description: "Cursor for retrieving the next page of results. This value is\
1349+
\ obtained from the `next_cursor` field in a previous response."
1350+
required: false
1351+
type: "string"
1352+
x-example: "7zDEe3DhD5gUiwRFsvWKKZlZO1j6-YihH2hyVWD8GaW7JnzXbHFP8Tou212KoU20mOjvM6pdWwycDWC3X-Hb_xY-RK1eBwYp_pc4X2CvLxo"
1353+
responses:
1354+
"200":
1355+
description: "Request Successful"
1356+
schema:
1357+
$ref: "#/definitions/PaginationDtoEventListingDto"
1358+
"400":
1359+
description: "Bad request. Either the JSON was malformed or there was a\
1360+
\ data validation error."
1361+
"401":
1362+
description: "The Access Token used is invalid."
1363+
"403":
1364+
description: "Forbidden request. You lack the necessary scopes, you lack\
1365+
\ the necessary user privileges, or the application is deactivated."
1366+
"404":
1367+
description: "The requested resource was not found."
1368+
"500":
1369+
description: "There was a problem with our internal service."
1370+
"503":
1371+
description: "Our internal service is temporarily unavailable."
1372+
security:
1373+
- oauth2_implicit:
1374+
- "campaign_data"
1375+
- oauth2_access_code:
1376+
- "campaign_data"
1377+
x-authorization-privileges:
1378+
- "campaign:read"
1379+
/events/{event_id}:
1380+
get:
1381+
tags:
1382+
- "Events"
1383+
summary: "GET details for a single event."
1384+
description: "Specify the `event_id` path parameter to retrieve the event's\
1385+
\ details."
1386+
operationId: "getEvent_2"
1387+
produces:
1388+
- "application/json"
1389+
parameters:
1390+
- name: "event_id"
1391+
in: "path"
1392+
description: "The ID that uniquely identifies the event."
1393+
required: true
1394+
type: "string"
1395+
x-example: "1697732a-8664-4675-8415-c4aabaa17dae"
1396+
- name: "include"
1397+
in: "query"
1398+
description: "Use to include (`true`) or exclude (`false`) event setting properties\
1399+
\ in the results."
1400+
required: false
1401+
type: "boolean"
1402+
x-example: true
1403+
responses:
1404+
"200":
1405+
description: "Request Successful"
1406+
schema:
1407+
$ref: "#/definitions/EventDto"
1408+
"400":
1409+
description: "Bad request. Either the JSON was malformed or there was a\
1410+
\ data validation error."
1411+
"401":
1412+
description: "The Access Token used is invalid."
1413+
"403":
1414+
description: "Forbidden request. You lack the necessary scopes, you lack\
1415+
\ the necessary user privileges, or the application is deactivated."
1416+
"404":
1417+
description: "The requested resource was not found."
1418+
"500":
1419+
description: "There was a problem with our internal service."
1420+
"503":
1421+
description: "Our internal service is temporarily unavailable."
1422+
security:
1423+
- oauth2_implicit:
1424+
- "campaign_data"
1425+
- oauth2_access_code:
1426+
- "campaign_data"
1427+
x-authorization-privileges:
1428+
- "campaign:read"
12931429
/segments:
12941430
get:
12951431
tags:
@@ -2660,6 +2796,22 @@ paths:
26602796
- "active"
26612797
- "deleted"
26622798
x-example: "all"
2799+
- name: "channel_type"
2800+
in: "query"
2801+
description: "Use to return lists by channel type. The default value is `email`."
2802+
required: false
2803+
type: "string"
2804+
enum:
2805+
- "email"
2806+
- "sms"
2807+
x-example: "all"
2808+
- name: "include_sms_membership_count"
2809+
in: "query"
2810+
description: "Set to `true` to return the total number of SMS members in each\
2811+
\ list. Only applicable when `channel_type` is `sms`. Default is `false`."
2812+
required: false
2813+
type: "boolean"
2814+
x-example: "false"
26632815
responses:
26642816
"200":
26652817
description: "Request successful"
@@ -3725,10 +3877,12 @@ paths:
37253877
tags:
37263878
- "Email Scheduling"
37273879
summary: "POST (Create) an Email Campaign Activity Schedule"
3728-
description: "Use this method to schedule when Constant Contact will send an\
3729-
\ email campaign activity to contacts. Use the `scheduled_date` request body\
3730-
\ property to enter the ISO-8601 format date that you want Constant Contact\
3731-
\ to send the email campaign activity on. \n\nBefore you schedule an email\
3880+
description: "Use this method to send an email campaign activity to contacts\
3881+
\ either immediately or on a specific date. To send the email campaign activity\
3882+
\ immediately, specify `0` for the `scheduled_date` request property (results\
3883+
\ return an empty array). To send the email campaign activity on a specific\
3884+
\ date, specify the date using the `scheduled_date` request property (results\
3885+
\ return the scheduled date in an array). \n\nBefore you schedule an email\
37323886
\ campaign activity, you must update the email campaign activity and specify\
37333887
\ which contacts you want Constant Contact to send the email to. When you\
37343888
\ make a PUT call to update an email campaign activity, use the `contact_list_ids`\

0 commit comments

Comments
 (0)