Skip to content

Commit 7095ddf

Browse files
committed
V22.8.0 - 2022-08-02
1 parent eff6681 commit 7095ddf

File tree

3 files changed

+72
-27
lines changed

3 files changed

+72
-27
lines changed

src/ConstantContact/V3/Contacts.php

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,12 @@ public function __construct(\PHPFUI\ConstantContact\Client $client)
1717
* Use this method to return a collection of contacts. Use the query parameters
1818
* to search for contacts that match specific criteria. For example, you
1919
* can search by the contact's `email` address, `status`, `lists` memberships,
20-
* `segment_id`, `tags`, `notes` and `updated_after` date. Use the `limit`
21-
* query parameter to limit the number of results returned per page. Use
22-
* the `include` query parameter to include contact sub-resources in the
23-
* response and `include_count` to include the total number of contacts
24-
* that meet your specified search criteria.
20+
* `segment_id`, `tags`, `notes`, and by the date or date range that a
21+
* contact was created or updated. Use the `limit` query parameter to limit
22+
* the number of results returned per page. Use the `include` query parameter
23+
* to include contact sub-resources in the response and `include_count`
24+
* to include the total number of contacts that meet your specified search
25+
* criteria.
2526
*
2627
* By default, this method returns all contacts that are not deleted. Use
2728
* the `status` query parameter with the value `all` to return all contacts
@@ -32,12 +33,15 @@ public function __construct(\PHPFUI\ConstantContact\Client $client)
3233
* @param string $lists Use the `lists` query parameter to search for contacts that are members of one or more specified lists. Use a comma to separate multiple `list_id` values, up to a maximum of 25.
3334
* @param string $segment_id Use to get contacts that meet the segment criteria for a single specified `segment_id`. This query parameter can only be combined with the limit query parameter. When using the `segment_id` query parameter, the V3 API may return a 202 response code instead of a 200 response. The 202 response code indicates that your request has been accepted, but not fully completed. Retry sending your API request to return the completed results and a 200 response code.
3435
* @param string $tags Use to get contact details for up to 50 specified tags. Use a comma to separate each `tag_id`.
35-
* @param string $updated_after Use `updated_after` to search for contacts that have been updated after the date you specify; accepts ISO-8601 formatted dates.
36+
* @param string $updated_after Use `updated_after` to search for contacts that have been updated after the date you specify. To search for updated contacts within a date range, specify both `updated_after` and `updated_before` dates. Accepts ISO-8601 formatted dates.
37+
* @param string $updated_before Use `updated_before` to search for contacts that have been updated before a specified date. To search for updated contacts within a date range, specify both `updated_after` and `updated_before` dates. Accepts ISO-8601 formatted dates.
38+
* @param string $created_after Use `created_after` to search for contacts created after a specified date. To search for contacts created within a date range, specify both `created_after` and `created_before` dates. Accepts ISO-8601 formatted dates.
39+
* @param string $created_before Use `created_before` to search for contacts created before a specified date. To search for contacts created within a date range, specify both `created_after` and `created_before` dates. Accepts ISO-8601 formatted dates.
3640
* @param string $include Use `include` to specify which contact sub-resources to include in the response. Use a comma to separate multiple sub-resources. Valid values: `custom_fields`, `list_memberships`, `taggings`, `notes`,`phone_numbers`, `street_addresses`.
3741
* @param bool $include_count Set `include_count=true` to include the total number of contacts (`contacts_count`) that meet all search criteria in the response body.
3842
* @param int $limit Specifies the number of results displayed per page of output in the response, from 1 - 500, default = 50.
3943
*/
40-
public function get(?string $status = null, ?string $email = null, ?string $lists = null, ?string $segment_id = null, ?string $tags = null, ?string $updated_after = null, ?string $include = null, ?bool $include_count = null, ?int $limit = null) : array
44+
public function get(?string $status = null, ?string $email = null, ?string $lists = null, ?string $segment_id = null, ?string $tags = null, ?string $updated_after = null, ?string $updated_before = null, ?string $created_after = null, ?string $created_before = null, ?string $include = null, ?bool $include_count = null, ?int $limit = null) : array
4145
{
4246

4347
if (null !== $status)
@@ -68,7 +72,7 @@ public function get(?string $status = null, ?string $email = null, ?string $list
6872
}
6973
}
7074

71-
return $this->doGet(['status' => $status, 'email' => $email, 'lists' => $lists, 'segment_id' => $segment_id, 'tags' => $tags, 'updated_after' => $updated_after, 'include' => $include, 'include_count' => $include_count, 'limit' => $limit, ]);
75+
return $this->doGet(['status' => $status, 'email' => $email, 'lists' => $lists, 'segment_id' => $segment_id, 'tags' => $tags, 'updated_after' => $updated_after, 'updated_before' => $updated_before, 'created_after' => $created_after, 'created_before' => $created_before, 'include' => $include, 'include_count' => $include_count, 'limit' => $limit, ]);
7276
}
7377

7478
/**

src/ConstantContact/V3/Emails.php

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,13 @@ public function get(?int $limit = null, ?string $before_date = null, ?string $af
4646
* them with the new email campaign.
4747
*
4848
* The request body must contain the `name` property and the `email_campaign_activities`
49-
* array. The `email_campaign_activities` array contains the main content
50-
* of your email campaign using the required properties `format_type`,
51-
* `from_name`, `from_email`, `reply_to_email`, `subject`, and `html_content`.
52-
*
49+
* array. The `name` must be unique. The `email_campaign_activities` array
50+
* contains the main content of your email campaign and must include `format_type`,
51+
* `from_name`, `from_email`, `reply_to_email`, `subject`, and `html_content`
52+
* properties. The `from_email` address you use must use a verified email
53+
* address for your account.
54+
* NOTE: If you create an email campaign using a legacy (V7) format, Constant
55+
* Contact automatically converts it to the newer custom code format.
5356
*
5457
*
5558
* @param \PHPFUI\ConstantContact\Definition\EmailCampaignComplete $body A JSON request body that contains the email content.

yaml/swagger.yaml

Lines changed: 53 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1573,13 +1573,14 @@ paths:
15731573
description: "Use this method to return a collection of contacts. Use the query\
15741574
\ parameters to search for contacts that match specific criteria. For example,\
15751575
\ you can search by the contact's `email` address, `status`, `lists` memberships,\
1576-
\ `segment_id`, `tags`, `notes` and `updated_after` date. Use the `limit`\
1577-
\ query parameter to limit the number of results returned per page. Use the\
1578-
\ `include` query parameter to include contact sub-resources in the response\
1579-
\ and `include_count` to include the total number of contacts that meet your\
1580-
\ specified search criteria.\n\nBy default, this method returns all contacts\
1581-
\ that are not deleted. Use the `status` query parameter with the value `all`\
1582-
\ to return all contacts including deleted contacts."
1576+
\ `segment_id`, `tags`, `notes`, and by the date or date range that a contact\
1577+
\ was created or updated. Use the `limit` query parameter to limit the number\
1578+
\ of results returned per page. Use the `include` query parameter to include\
1579+
\ contact sub-resources in the response and `include_count` to include the\
1580+
\ total number of contacts that meet your specified search criteria.\n\nBy\
1581+
\ default, this method returns all contacts that are not deleted. Use the\
1582+
\ `status` query parameter with the value `all` to return all contacts including\
1583+
\ deleted contacts."
15831584
operationId: "getContacts"
15841585
produces:
15851586
- "application/json"
@@ -1641,11 +1642,43 @@ paths:
16411642
- name: "updated_after"
16421643
in: "query"
16431644
description: "Use `updated_after` to search for contacts that have been updated\
1644-
\ after the date you specify; accepts ISO-8601 formatted dates."
1645+
\ after the date you specify. To search for updated contacts within a date\
1646+
\ range, specify both `updated_after` and `updated_before` dates. Accepts\
1647+
\ ISO-8601 formatted dates."
16451648
required: false
16461649
type: "string"
1647-
format: "date"
1648-
x-example: "2016-07-16"
1650+
format: "date-time"
1651+
x-example: "2022-01-01T16:37:59.091Z"
1652+
- name: "updated_before"
1653+
in: "query"
1654+
description: "Use `updated_before` to search for contacts that have been updated\
1655+
\ before a specified date. To search for updated contacts within a date\
1656+
\ range, specify both `updated_after` and `updated_before` dates. Accepts\
1657+
\ ISO-8601 formatted dates."
1658+
required: false
1659+
type: "string"
1660+
format: "date-time"
1661+
x-example: "2022-07-16T16:37:59.091Z"
1662+
- name: "created_after"
1663+
in: "query"
1664+
description: "Use `created_after` to search for contacts created after a specified\
1665+
\ date. To search for contacts created within a date range, specify both\
1666+
\ `created_after` and `created_before` dates. Accepts ISO-8601 formatted\
1667+
\ dates."
1668+
required: false
1669+
type: "string"
1670+
format: "date-time"
1671+
x-example: "2021-01-01T16:37:59.091Z"
1672+
- name: "created_before"
1673+
in: "query"
1674+
description: "Use `created_before` to search for contacts created before a\
1675+
\ specified date. To search for contacts created within a date range, specify\
1676+
\ both `created_after` and `created_before` dates. Accepts ISO-8601 formatted\
1677+
\ dates."
1678+
required: false
1679+
type: "string"
1680+
format: "date-time"
1681+
x-example: "2022-07-16T16:37:59.091Z"
16491682
- name: "include"
16501683
in: "query"
16511684
description: "Use `include` to specify which contact sub-resources to include\
@@ -2803,10 +2836,13 @@ paths:
28032836
description: "Use this method to create a new email campaign. This method also\
28042837
\ creates new `primary_email` and `permalink` email campaign activities and\
28052838
\ associates them with the new email campaign.\n\nThe request body must contain\
2806-
\ the `name` property and the `email_campaign_activities` array. The `email_campaign_activities`\
2807-
\ array contains the main content of your email campaign using the required\
2808-
\ properties `format_type`, `from_name`, `from_email`, `reply_to_email`, `subject`,\
2809-
\ and `html_content`.\n"
2839+
\ the `name` property and the `email_campaign_activities` array. The `name`\
2840+
\ must be unique. The `email_campaign_activities` array contains the main\
2841+
\ content of your email campaign and must include `format_type`, `from_name`,\
2842+
\ `from_email`, `reply_to_email`, `subject`, and `html_content` properties.\
2843+
\ The `from_email` address you use must use a verified email address for your\
2844+
\ account.\nNOTE: If you create an email campaign using a legacy (V7) format,\
2845+
\ Constant Contact automatically converts it to the newer custom code format.\n"
28102846
operationId: "createEmailCampaignUsingPOST"
28112847
consumes:
28122848
- "application/json"
@@ -2821,7 +2857,9 @@ paths:
28212857
$ref: "#/definitions/EmailCampaignComplete"
28222858
responses:
28232859
"200":
2824-
description: "Request successful."
2860+
description: "Request successful. NOTE: If you created an email campaign\
2861+
\ using a legacy (V7) format, Constant Contact successfully converted\
2862+
\ it to the newer custom code format."
28252863
schema:
28262864
$ref: "#/definitions/EmailCampaign"
28272865
"400":

0 commit comments

Comments
 (0)