campaign_versions
Creates, updates, deletes, gets or lists a campaign_versions resource.
Overview
| Name | campaign_versions |
| Type | Resource |
| Id | aws.pinpoint.campaign_versions |
Fields
The following fields are returned by SELECT queries:
- get_campaign_version
- get_campaign_versions
| Name | Datatype | Description |
|---|---|---|
additional_treatments | array | An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment. |
application_id | string | The unique identifier for the application that the campaign applies to. |
arn | string | The Amazon Resource Name (ARN) of the campaign. |
creation_date | string | The date, in ISO 8601 format, when the campaign was created. |
custom_delivery_configuration | object | The delivery configuration settings for sending the campaign through a custom channel. |
default_state | object | The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment. |
description | string | The custom description of the campaign. |
holdout_percent | integer | The allocated percentage of users (segment members) who shouldn't receive messages from the campaign. |
hook | object | The settings for the AWS Lambda function to use as a code hook for the campaign. You can use this hook to customize the segment that's used by the campaign. |
id | string | The unique identifier for the campaign. |
is_paused | boolean | Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false. |
last_modified_date | string | The date, in ISO 8601 format, when the campaign was last modified. |
limits | object | The messaging limits for the campaign. |
message_configuration | object | The message configuration settings for the campaign. |
name | string | The name of the campaign. |
priority | integer | Defines the priority of the campaign, used to decide the order of messages displayed to user if there are multiple messages scheduled to be displayed at the same moment. |
schedule | object | The schedule settings for the campaign. |
segment_id | string | The unique identifier for the segment that's associated with the campaign. |
segment_version | integer | The version number of the segment that's associated with the campaign. |
state | object | The current status of the campaign. |
template_configuration | object | The message template that’s used for the campaign. |
treatment_description | string | The custom description of the default treatment for the campaign. |
treatment_name | string | The custom name of the default treatment for the campaign, if the campaign has multiple treatments. A treatment is a variation of a campaign that's used for A/B testing. |
version | integer | The version number of the campaign. |
tags | object | A string-to-string map of key-value pairs that identifies the tags that are associated with the campaign. Each tag consists of a required tag key and an associated tag value. |
| Name | Datatype | Description |
|---|---|---|
item | array | An array of responses, one for each campaign that's associated with the application. |
next_token | string | The string to use in a subsequent request to get the next page of results in a paginated response. This value is null if there are no additional pages. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_campaign_version | select | application-id, campaign-id, version, region | Retrieves information about the status, configuration, and other settings for a specific version of a campaign. | |
get_campaign_versions | select | application-id, campaign-id, region | page-size, token | Retrieves information about the status, configuration, and other settings for all versions of a campaign. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
application-id | string | The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console. |
campaign-id | string | The unique identifier for the campaign. |
region | string | AWS region (default: us-east-1) |
version | string | The unique version number (Version property) for the campaign version. |
page-size | string | The maximum number of items to include in each page of a paginated response. This parameter is not supported for application, campaign, and journey metrics. |
token | string | The NextToken string that specifies which page of results to return in a paginated response. |
SELECT examples
- get_campaign_version
- get_campaign_versions
Retrieves information about the status, configuration, and other settings for a specific version of a campaign.
SELECT
additional_treatments,
application_id,
arn,
creation_date,
custom_delivery_configuration,
default_state,
description,
holdout_percent,
hook,
id,
is_paused,
last_modified_date,
limits,
message_configuration,
name,
priority,
schedule,
segment_id,
segment_version,
state,
template_configuration,
treatment_description,
treatment_name,
version,
tags
FROM aws.pinpoint.campaign_versions
WHERE `application-id` = '{{ application-id }}' -- required
AND `campaign-id` = '{{ campaign-id }}' -- required
AND version = '{{ version }}' -- required
AND region = '{{ region }}' -- required
;
Retrieves information about the status, configuration, and other settings for all versions of a campaign.
SELECT
item,
next_token
FROM aws.pinpoint.campaign_versions
WHERE `application-id` = '{{ application-id }}' -- required
AND `campaign-id` = '{{ campaign-id }}' -- required
AND region = '{{ region }}' -- required
AND `page-size` = '{{ page-size }}'
AND token = '{{ token }}'
;