Pinpoint

Table of Contents

Client

class Pinpoint.Client

A low-level client representing Amazon Pinpoint:

import boto3

client = boto3.client('pinpoint')

These are the available methods:

can_paginate(operation_name)

Check if an operation can be paginated.

Parameters
operation_name (string) -- The operation name. This is the same name as the method name on the client. For example, if the method name is create_foo, and you'd normally invoke the operation as client.create_foo(**kwargs), if the create_foo operation can be paginated, you can use the call client.get_paginator("create_foo").
Returns
True if the operation can be paginated, False otherwise.
create_app(**kwargs)

Creates an application.

See also: AWS API Documentation

Request Syntax

response = client.create_app(
    CreateApplicationRequest={
        'Name': 'string',
        'tags': {
            'string': 'string'
        }
    }
)
Parameters
CreateApplicationRequest (dict) --

[REQUIRED]

Specifies the display name of an application and the tags to associate with the application.

  • Name (string) -- [REQUIRED]

    The display name of the application. This name is displayed as the Project name on the Amazon Pinpoint console.

  • tags (dict) --

    A string-to-string map of key-value pairs that defines the tags to associate with the application. Each tag consists of a required tag key and an associated tag value.

    • (string) --
      • (string) --
Return type
dict
Returns
Response Syntax
{
    'ApplicationResponse': {
        'Arn': 'string',
        'Id': 'string',
        'Name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    The request succeeded and the specified resource was created.

    • ApplicationResponse (dict) --

      Provides information about an application.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the application.

      • Id (string) --

        The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

      • Name (string) --

        The display name of the application. This name is displayed as the Project name on the Amazon Pinpoint console.

      • tags (dict) --

        A string-to-string map of key-value pairs that identifies the tags that are associated with the application. Each tag consists of a required tag key and an associated tag value.

        • (string) --
          • (string) --
create_campaign(**kwargs)

Creates a new campaign for an application or updates the settings of an existing campaign for an application.

See also: AWS API Documentation

Request Syntax

response = client.create_campaign(
    ApplicationId='string',
    WriteCampaignRequest={
        'AdditionalTreatments': [
            {
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SizePercent': 123,
                'TreatmentDescription': 'string',
                'TreatmentName': 'string'
            },
        ],
        'Description': 'string',
        'HoldoutPercent': 123,
        'Hook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'IsPaused': True|False,
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'MessageConfiguration': {
            'ADMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'APNSMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'BaiduMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'DefaultMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'EmailMessage': {
                'Body': 'string',
                'FromAddress': 'string',
                'HtmlBody': 'string',
                'Title': 'string'
            },
            'GCMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'SMSMessage': {
                'Body': 'string',
                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                'SenderId': 'string'
            }
        },
        'Name': 'string',
        'Schedule': {
            'EndTime': 'string',
            'EventFilter': {
                'Dimensions': {
                    'Attributes': {
                        'string': {
                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                            'Values': [
                                'string',
                            ]
                        }
                    },
                    'EventType': {
                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                        'Values': [
                            'string',
                        ]
                    },
                    'Metrics': {
                        'string': {
                            'ComparisonOperator': 'string',
                            'Value': 123.0
                        }
                    }
                },
                'FilterType': 'SYSTEM'|'ENDPOINT'
            },
            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
            'IsLocalTime': True|False,
            'QuietTime': {
                'End': 'string',
                'Start': 'string'
            },
            'StartTime': 'string',
            'Timezone': 'string'
        },
        'SegmentId': 'string',
        'SegmentVersion': 123,
        'tags': {
            'string': 'string'
        },
        'TreatmentDescription': 'string',
        'TreatmentName': 'string'
    }
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • WriteCampaignRequest (dict) --

    [REQUIRED]

    Specifies the configuration and other settings for a campaign.

    • AdditionalTreatments (list) --

      An array of requests that defines additional treatments for the campaign, in addition to the default treatment for the campaign.

      • (dict) --

        Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

        • MessageConfiguration (dict) --

          The message configuration settings for the treatment.

          • ADMMessage (dict) --

            The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

            • Action (string) --

              The action to occur if a recipient taps the push notification. Valid values are:

              • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
              • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
              • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
            • Body (string) --

              The body of the notification message. The maximum number of characters is 200.

            • ImageIconUrl (string) --

              The URL of the image to display as the push-notification icon, such as the icon for the app.

            • ImageSmallIconUrl (string) --

              The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

            • ImageUrl (string) --

              The URL of an image to display in the push notification.

            • JsonBody (string) --

              The JSON payload to use for a silent push notification.

            • MediaUrl (string) --

              The URL of the image or video to display in the push notification.

            • RawContent (string) --

              The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

            • SilentPush (boolean) --

              Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

            • TimeToLive (integer) --

              The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

              This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

            • Title (string) --

              The title to display above the notification message on a recipient's device.

            • Url (string) --

              The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

          • APNSMessage (dict) --

            The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

            • Action (string) --

              The action to occur if a recipient taps the push notification. Valid values are:

              • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
              • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
              • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
            • Body (string) --

              The body of the notification message. The maximum number of characters is 200.

            • ImageIconUrl (string) --

              The URL of the image to display as the push-notification icon, such as the icon for the app.

            • ImageSmallIconUrl (string) --

              The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

            • ImageUrl (string) --

              The URL of an image to display in the push notification.

            • JsonBody (string) --

              The JSON payload to use for a silent push notification.

            • MediaUrl (string) --

              The URL of the image or video to display in the push notification.

            • RawContent (string) --

              The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

            • SilentPush (boolean) --

              Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

            • TimeToLive (integer) --

              The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

              This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

            • Title (string) --

              The title to display above the notification message on a recipient's device.

            • Url (string) --

              The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

          • BaiduMessage (dict) --

            The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

            • Action (string) --

              The action to occur if a recipient taps the push notification. Valid values are:

              • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
              • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
              • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
            • Body (string) --

              The body of the notification message. The maximum number of characters is 200.

            • ImageIconUrl (string) --

              The URL of the image to display as the push-notification icon, such as the icon for the app.

            • ImageSmallIconUrl (string) --

              The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

            • ImageUrl (string) --

              The URL of an image to display in the push notification.

            • JsonBody (string) --

              The JSON payload to use for a silent push notification.

            • MediaUrl (string) --

              The URL of the image or video to display in the push notification.

            • RawContent (string) --

              The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

            • SilentPush (boolean) --

              Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

            • TimeToLive (integer) --

              The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

              This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

            • Title (string) --

              The title to display above the notification message on a recipient's device.

            • Url (string) --

              The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

          • DefaultMessage (dict) --

            The default message that the campaign sends through all the channels that are configured for the campaign.

            • Action (string) --

              The action to occur if a recipient taps the push notification. Valid values are:

              • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
              • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
              • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
            • Body (string) --

              The body of the notification message. The maximum number of characters is 200.

            • ImageIconUrl (string) --

              The URL of the image to display as the push-notification icon, such as the icon for the app.

            • ImageSmallIconUrl (string) --

              The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

            • ImageUrl (string) --

              The URL of an image to display in the push notification.

            • JsonBody (string) --

              The JSON payload to use for a silent push notification.

            • MediaUrl (string) --

              The URL of the image or video to display in the push notification.

            • RawContent (string) --

              The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

            • SilentPush (boolean) --

              Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

            • TimeToLive (integer) --

              The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

              This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

            • Title (string) --

              The title to display above the notification message on a recipient's device.

            • Url (string) --

              The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

          • EmailMessage (dict) --

            The message that the campaign sends through the email channel.

            • Body (string) --

              The body of the email for recipients whose email clients don't support HTML content.

            • FromAddress (string) --

              The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

            • HtmlBody (string) --

              The body of the email, in HTML format, for recipients whose email clients support HTML content.

            • Title (string) -- [REQUIRED]

              The subject line, or title, of the email.

          • GCMMessage (dict) --

            The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

            • Action (string) --

              The action to occur if a recipient taps the push notification. Valid values are:

              • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
              • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
              • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
            • Body (string) --

              The body of the notification message. The maximum number of characters is 200.

            • ImageIconUrl (string) --

              The URL of the image to display as the push-notification icon, such as the icon for the app.

            • ImageSmallIconUrl (string) --

              The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

            • ImageUrl (string) --

              The URL of an image to display in the push notification.

            • JsonBody (string) --

              The JSON payload to use for a silent push notification.

            • MediaUrl (string) --

              The URL of the image or video to display in the push notification.

            • RawContent (string) --

              The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

            • SilentPush (boolean) --

              Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

            • TimeToLive (integer) --

              The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

              This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

            • Title (string) --

              The title to display above the notification message on a recipient's device.

            • Url (string) --

              The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

          • SMSMessage (dict) --

            The message that the campaign sends through the SMS channel.

            • Body (string) --

              The body of the SMS message.

            • MessageType (string) --

              The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

            • SenderId (string) --

              The sender ID to display on recipients' devices when they receive the SMS message.

        • Schedule (dict) --

          The schedule settings for the treatment.

          • EndTime (string) --

            The scheduled time, in ISO 8601 format, for the campaign to end.

          • EventFilter (dict) --

            The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

            • Dimensions (dict) -- [REQUIRED]

              The dimension settings of the event filter for the campaign.

              • Attributes (dict) --

                One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                • (string) --
                  • (dict) --

                    Specifies attribute-based criteria for including or excluding endpoints from a segment.

                    • AttributeType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) -- [REQUIRED]

                      The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                      • (string) --
              • EventType (dict) --

                The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                • DimensionType (string) --

                  The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                • Values (list) -- [REQUIRED]

                  The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                  • (string) --
              • Metrics (dict) --

                One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                • (string) --
                  • (dict) --

                    Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                    • ComparisonOperator (string) -- [REQUIRED]

                      The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                    • Value (float) -- [REQUIRED]

                      The value to compare.

            • FilterType (string) -- [REQUIRED]

              The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

          • Frequency (string) --

            Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

          • IsLocalTime (boolean) --

            Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

          • QuietTime (dict) --

            The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

            • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
            • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
            • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

            If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

            • End (string) --

              The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • Start (string) --

              The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

          • StartTime (string) -- [REQUIRED]

            The scheduled time, in ISO 8601 format, for the campaign to begin.

          • Timezone (string) --

            The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

        • SizePercent (integer) -- [REQUIRED]

          The allocated percentage of users (segment members) to send the treatment to.

        • TreatmentDescription (string) --

          The custom description of the treatment.

        • TreatmentName (string) --

          The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

    • Description (string) --

      The custom description of the campaign.

    • HoldoutPercent (integer) --

      The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

    • Hook (dict) --

      The settings for the AWS Lambda function to use as a code hook for the campaign.

      • LambdaFunctionName (string) --

        The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

      • Mode (string) --

        Specifies which Lambda mode to use when invoking the AWS Lambda function.

      • WebUrl (string) --

        The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

    • IsPaused (boolean) --

      Specifies whether to pause the campaign. A paused campaign doesn't run unless you resume it by setting this value to false.

    • Limits (dict) --

      The messaging limits for the campaign.

      • Daily (integer) --

        The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

      • MaximumDuration (integer) --

        The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

      • MessagesPerSecond (integer) --

        The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

      • Total (integer) --

        The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

    • MessageConfiguration (dict) --

      The message configuration settings for the campaign.

      • ADMMessage (dict) --

        The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

        • Action (string) --

          The action to occur if a recipient taps the push notification. Valid values are:

          • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
          • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
          • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
        • Body (string) --

          The body of the notification message. The maximum number of characters is 200.

        • ImageIconUrl (string) --

          The URL of the image to display as the push-notification icon, such as the icon for the app.

        • ImageSmallIconUrl (string) --

          The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

        • ImageUrl (string) --

          The URL of an image to display in the push notification.

        • JsonBody (string) --

          The JSON payload to use for a silent push notification.

        • MediaUrl (string) --

          The URL of the image or video to display in the push notification.

        • RawContent (string) --

          The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

        • SilentPush (boolean) --

          Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

        • TimeToLive (integer) --

          The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

          This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

        • Title (string) --

          The title to display above the notification message on a recipient's device.

        • Url (string) --

          The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

      • APNSMessage (dict) --

        The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

        • Action (string) --

          The action to occur if a recipient taps the push notification. Valid values are:

          • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
          • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
          • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
        • Body (string) --

          The body of the notification message. The maximum number of characters is 200.

        • ImageIconUrl (string) --

          The URL of the image to display as the push-notification icon, such as the icon for the app.

        • ImageSmallIconUrl (string) --

          The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

        • ImageUrl (string) --

          The URL of an image to display in the push notification.

        • JsonBody (string) --

          The JSON payload to use for a silent push notification.

        • MediaUrl (string) --

          The URL of the image or video to display in the push notification.

        • RawContent (string) --

          The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

        • SilentPush (boolean) --

          Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

        • TimeToLive (integer) --

          The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

          This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

        • Title (string) --

          The title to display above the notification message on a recipient's device.

        • Url (string) --

          The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

      • BaiduMessage (dict) --

        The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

        • Action (string) --

          The action to occur if a recipient taps the push notification. Valid values are:

          • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
          • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
          • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
        • Body (string) --

          The body of the notification message. The maximum number of characters is 200.

        • ImageIconUrl (string) --

          The URL of the image to display as the push-notification icon, such as the icon for the app.

        • ImageSmallIconUrl (string) --

          The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

        • ImageUrl (string) --

          The URL of an image to display in the push notification.

        • JsonBody (string) --

          The JSON payload to use for a silent push notification.

        • MediaUrl (string) --

          The URL of the image or video to display in the push notification.

        • RawContent (string) --

          The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

        • SilentPush (boolean) --

          Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

        • TimeToLive (integer) --

          The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

          This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

        • Title (string) --

          The title to display above the notification message on a recipient's device.

        • Url (string) --

          The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

      • DefaultMessage (dict) --

        The default message that the campaign sends through all the channels that are configured for the campaign.

        • Action (string) --

          The action to occur if a recipient taps the push notification. Valid values are:

          • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
          • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
          • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
        • Body (string) --

          The body of the notification message. The maximum number of characters is 200.

        • ImageIconUrl (string) --

          The URL of the image to display as the push-notification icon, such as the icon for the app.

        • ImageSmallIconUrl (string) --

          The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

        • ImageUrl (string) --

          The URL of an image to display in the push notification.

        • JsonBody (string) --

          The JSON payload to use for a silent push notification.

        • MediaUrl (string) --

          The URL of the image or video to display in the push notification.

        • RawContent (string) --

          The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

        • SilentPush (boolean) --

          Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

        • TimeToLive (integer) --

          The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

          This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

        • Title (string) --

          The title to display above the notification message on a recipient's device.

        • Url (string) --

          The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

      • EmailMessage (dict) --

        The message that the campaign sends through the email channel.

        • Body (string) --

          The body of the email for recipients whose email clients don't support HTML content.

        • FromAddress (string) --

          The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

        • HtmlBody (string) --

          The body of the email, in HTML format, for recipients whose email clients support HTML content.

        • Title (string) -- [REQUIRED]

          The subject line, or title, of the email.

      • GCMMessage (dict) --

        The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

        • Action (string) --

          The action to occur if a recipient taps the push notification. Valid values are:

          • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
          • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
          • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
        • Body (string) --

          The body of the notification message. The maximum number of characters is 200.

        • ImageIconUrl (string) --

          The URL of the image to display as the push-notification icon, such as the icon for the app.

        • ImageSmallIconUrl (string) --

          The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

        • ImageUrl (string) --

          The URL of an image to display in the push notification.

        • JsonBody (string) --

          The JSON payload to use for a silent push notification.

        • MediaUrl (string) --

          The URL of the image or video to display in the push notification.

        • RawContent (string) --

          The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

        • SilentPush (boolean) --

          Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

        • TimeToLive (integer) --

          The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

          This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

        • Title (string) --

          The title to display above the notification message on a recipient's device.

        • Url (string) --

          The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

      • SMSMessage (dict) --

        The message that the campaign sends through the SMS channel.

        • Body (string) --

          The body of the SMS message.

        • MessageType (string) --

          The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

        • SenderId (string) --

          The sender ID to display on recipients' devices when they receive the SMS message.

    • Name (string) --

      The custom name of the campaign.

    • Schedule (dict) --

      The schedule settings for the campaign.

      • EndTime (string) --

        The scheduled time, in ISO 8601 format, for the campaign to end.

      • EventFilter (dict) --

        The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

        • Dimensions (dict) -- [REQUIRED]

          The dimension settings of the event filter for the campaign.

          • Attributes (dict) --

            One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

            • (string) --
              • (dict) --

                Specifies attribute-based criteria for including or excluding endpoints from a segment.

                • AttributeType (string) --

                  The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                • Values (list) -- [REQUIRED]

                  The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                  • (string) --
          • EventType (dict) --

            The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) -- [REQUIRED]

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Metrics (dict) --

            One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

            • (string) --
              • (dict) --

                Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                • ComparisonOperator (string) -- [REQUIRED]

                  The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                • Value (float) -- [REQUIRED]

                  The value to compare.

        • FilterType (string) -- [REQUIRED]

          The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

      • Frequency (string) --

        Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

      • IsLocalTime (boolean) --

        Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

      • QuietTime (dict) --

        The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

        • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
        • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
        • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

        If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

        • End (string) --

          The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • Start (string) --

          The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

      • StartTime (string) -- [REQUIRED]

        The scheduled time, in ISO 8601 format, for the campaign to begin.

      • Timezone (string) --

        The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

    • SegmentId (string) --

      The unique identifier for the segment to associate with the campaign.

    • SegmentVersion (integer) --

      The version of the segment to associate with the campaign.

    • tags (dict) --

      A string-to-string map of key-value pairs that defines the tags to associate with the campaign. Each tag consists of a required tag key and an associated tag value.

      • (string) --
        • (string) --
    • TreatmentDescription (string) --

      The custom description of a variation of the campaign to use for A/B testing.

    • TreatmentName (string) --

      The custom name of a variation of the campaign to use for A/B testing.

Return type

dict

Returns

Response Syntax

{
    'CampaignResponse': {
        'AdditionalTreatments': [
            {
                'Id': 'string',
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SizePercent': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string'
            },
        ],
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'DefaultState': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'Description': 'string',
        'HoldoutPercent': 123,
        'Hook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'Id': 'string',
        'IsPaused': True|False,
        'LastModifiedDate': 'string',
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'MessageConfiguration': {
            'ADMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'APNSMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'BaiduMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'DefaultMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'EmailMessage': {
                'Body': 'string',
                'FromAddress': 'string',
                'HtmlBody': 'string',
                'Title': 'string'
            },
            'GCMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'SMSMessage': {
                'Body': 'string',
                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                'SenderId': 'string'
            }
        },
        'Name': 'string',
        'Schedule': {
            'EndTime': 'string',
            'EventFilter': {
                'Dimensions': {
                    'Attributes': {
                        'string': {
                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                            'Values': [
                                'string',
                            ]
                        }
                    },
                    'EventType': {
                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                        'Values': [
                            'string',
                        ]
                    },
                    'Metrics': {
                        'string': {
                            'ComparisonOperator': 'string',
                            'Value': 123.0
                        }
                    }
                },
                'FilterType': 'SYSTEM'|'ENDPOINT'
            },
            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
            'IsLocalTime': True|False,
            'QuietTime': {
                'End': 'string',
                'Start': 'string'
            },
            'StartTime': 'string',
            'Timezone': 'string'
        },
        'SegmentId': 'string',
        'SegmentVersion': 123,
        'State': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'tags': {
            'string': 'string'
        },
        'TreatmentDescription': 'string',
        'TreatmentName': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded and the specified resource was created.

    • CampaignResponse (dict) --

      Provides information about the status, configuration, and other settings for a campaign.

      • AdditionalTreatments (list) --

        An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

        • (dict) --

          Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

          • Id (string) --

            The unique identifier for the treatment.

          • MessageConfiguration (dict) --

            The message configuration settings for the treatment.

            • ADMMessage (dict) --

              The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • APNSMessage (dict) --

              The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • BaiduMessage (dict) --

              The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • DefaultMessage (dict) --

              The default message that the campaign sends through all the channels that are configured for the campaign.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • EmailMessage (dict) --

              The message that the campaign sends through the email channel.

              • Body (string) --

                The body of the email for recipients whose email clients don't support HTML content.

              • FromAddress (string) --

                The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

              • HtmlBody (string) --

                The body of the email, in HTML format, for recipients whose email clients support HTML content.

              • Title (string) --

                The subject line, or title, of the email.

            • GCMMessage (dict) --

              The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • SMSMessage (dict) --

              The message that the campaign sends through the SMS channel.

              • Body (string) --

                The body of the SMS message.

              • MessageType (string) --

                The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

              • SenderId (string) --

                The sender ID to display on recipients' devices when they receive the SMS message.

          • Schedule (dict) --

            The schedule settings for the treatment.

            • EndTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to end.

            • EventFilter (dict) --

              The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

              • Dimensions (dict) --

                The dimension settings of the event filter for the campaign.

                • Attributes (dict) --

                  One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • EventType (dict) --

                  The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Metrics (dict) --

                  One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

              • FilterType (string) --

                The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

            • Frequency (string) --

              Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

            • IsLocalTime (boolean) --

              Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

            • QuietTime (dict) --

              The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

              • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
              • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
              • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

              If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

              • End (string) --

                The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

              • Start (string) --

                The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • StartTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to begin.

            • Timezone (string) --

              The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

          • SizePercent (integer) --

            The allocated percentage of users (segment members) that the treatment is sent to.

          • State (dict) --

            The status of the treatment.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • TreatmentDescription (string) --

            The custom description of the treatment.

          • TreatmentName (string) --

            The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

      • ApplicationId (string) --

        The unique identifier for the application that the campaign applies to.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the campaign.

      • CreationDate (string) --

        The date, ISO 8601 format, when the campaign was created.

      • DefaultState (dict) --

        The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment, to support A/B testing.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • Description (string) --

        The custom description of the campaign.

      • HoldoutPercent (integer) --

        The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

      • Hook (dict) --

        The settings for the AWS Lambda function to use as a code hook for the campaign.

        • LambdaFunctionName (string) --

          The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

        • Mode (string) --

          Specifies which Lambda mode to use when invoking the AWS Lambda function.

        • WebUrl (string) --

          The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

      • Id (string) --

        The unique identifier for the campaign.

      • IsPaused (boolean) --

        Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false.

      • LastModifiedDate (string) --

        The date, in ISO 8601 format, when the campaign was last modified.

      • Limits (dict) --

        The messaging limits for the campaign.

        • Daily (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

        • MaximumDuration (integer) --

          The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

        • MessagesPerSecond (integer) --

          The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

        • Total (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

      • MessageConfiguration (dict) --

        The message configuration settings for the campaign.

        • ADMMessage (dict) --

          The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • APNSMessage (dict) --

          The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • BaiduMessage (dict) --

          The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • DefaultMessage (dict) --

          The default message that the campaign sends through all the channels that are configured for the campaign.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • EmailMessage (dict) --

          The message that the campaign sends through the email channel.

          • Body (string) --

            The body of the email for recipients whose email clients don't support HTML content.

          • FromAddress (string) --

            The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

          • HtmlBody (string) --

            The body of the email, in HTML format, for recipients whose email clients support HTML content.

          • Title (string) --

            The subject line, or title, of the email.

        • GCMMessage (dict) --

          The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • SMSMessage (dict) --

          The message that the campaign sends through the SMS channel.

          • Body (string) --

            The body of the SMS message.

          • MessageType (string) --

            The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

          • SenderId (string) --

            The sender ID to display on recipients' devices when they receive the SMS message.

      • Name (string) --

        The name of the campaign.

      • Schedule (dict) --

        The schedule settings for the campaign.

        • EndTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to end.

        • EventFilter (dict) --

          The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

          • Dimensions (dict) --

            The dimension settings of the event filter for the campaign.

            • Attributes (dict) --

              One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies attribute-based criteria for including or excluding endpoints from a segment.

                  • AttributeType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                    • (string) --
            • EventType (dict) --

              The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

              • DimensionType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                • (string) --
            • Metrics (dict) --

              One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                  • ComparisonOperator (string) --

                    The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                  • Value (float) --

                    The value to compare.

          • FilterType (string) --

            The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

        • Frequency (string) --

          Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

        • IsLocalTime (boolean) --

          Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

        • QuietTime (dict) --

          The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

          • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
          • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
          • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

          If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

          • End (string) --

            The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

          • Start (string) --

            The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • StartTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to begin.

        • Timezone (string) --

          The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

      • SegmentId (string) --

        The unique identifier for the segment that's associated with the campaign.

      • SegmentVersion (integer) --

        The version number of the segment that's associated with the campaign.

      • State (dict) --

        The current status of the campaign.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • tags (dict) --

        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.

        • (string) --
          • (string) --
      • TreatmentDescription (string) --

        The custom description of a variation of the campaign that's used for A/B testing.

      • TreatmentName (string) --

        The custom name of a variation of the campaign that's used for A/B testing.

      • Version (integer) --

        The version number of the campaign.

create_export_job(**kwargs)

Creates a new export job for an application.

See also: AWS API Documentation

Request Syntax

response = client.create_export_job(
    ApplicationId='string',
    ExportJobRequest={
        'RoleArn': 'string',
        'S3UrlPrefix': 'string',
        'SegmentId': 'string',
        'SegmentVersion': 123
    }
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • ExportJobRequest (dict) --

    [REQUIRED]

    Specifies the settings for a job that exports endpoint definitions to an Amazon Simple Storage Service (Amazon S3) bucket.

    • RoleArn (string) -- [REQUIRED]

      The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorizes Amazon Pinpoint to access the Amazon S3 location where you want to export endpoint definitions to.

    • S3UrlPrefix (string) -- [REQUIRED]

      The URL of the location in an Amazon Simple Storage Service (Amazon S3) bucket where you want to export endpoint definitions to. This location is typically a folder that contains multiple files. The URL should be in the following format: s3://bucket-name/folder-name/.

    • SegmentId (string) --

      The identifier for the segment to export endpoint definitions from. If you don't specify this value, Amazon Pinpoint exports definitions for all the endpoints that are associated with the application.

    • SegmentVersion (integer) --

      The version of the segment to export endpoint definitions from, if specified.

Return type

dict

Returns

Response Syntax

{
    'ExportJobResponse': {
        'ApplicationId': 'string',
        'CompletedPieces': 123,
        'CompletionDate': 'string',
        'CreationDate': 'string',
        'Definition': {
            'RoleArn': 'string',
            'S3UrlPrefix': 'string',
            'SegmentId': 'string',
            'SegmentVersion': 123
        },
        'FailedPieces': 123,
        'Failures': [
            'string',
        ],
        'Id': 'string',
        'JobStatus': 'CREATED'|'INITIALIZING'|'PROCESSING'|'COMPLETING'|'COMPLETED'|'FAILING'|'FAILED',
        'TotalFailures': 123,
        'TotalPieces': 123,
        'TotalProcessed': 123,
        'Type': 'string'
    }
}

Response Structure

  • (dict) --

    The request was accepted for processing. Processing may not be complete.

    • ExportJobResponse (dict) --

      Provides information about the status and settings of a job that exports endpoint definitions to a file. The file can be added directly to an Amazon Simple Storage Service (Amazon S3) bucket by using the Amazon Pinpoint API or downloaded directly to a computer by using the Amazon Pinpoint console.

      • ApplicationId (string) --

        The unique identifier for the application that's associated with the export job.

      • CompletedPieces (integer) --

        The number of pieces that were processed successfully (completed) by the export job, as of the time of the request.

      • CompletionDate (string) --

        The date, in ISO 8601 format, when the export job was completed.

      • CreationDate (string) --

        The date, in ISO 8601 format, when the export job was created.

      • Definition (dict) --

        The resource settings that apply to the export job.

        • RoleArn (string) --

          The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorized Amazon Pinpoint to access the Amazon S3 location where the endpoint definitions were exported to.

        • S3UrlPrefix (string) --

          The URL of the location in an Amazon Simple Storage Service (Amazon S3) bucket where the endpoint definitions were exported to. This location is typically a folder that contains multiple files. The URL should be in the following format: s3://bucket-name/folder-name/.

        • SegmentId (string) --

          The identifier for the segment that the endpoint definitions were exported from. If this value isn't present, Amazon Pinpoint exported definitions for all the endpoints that are associated with the application.

        • SegmentVersion (integer) --

          The version of the segment that the endpoint definitions were exported from.

      • FailedPieces (integer) --

        The number of pieces that weren't processed successfully (failed) by the export job, as of the time of the request.

      • Failures (list) --

        An array of entries, one for each of the first 100 entries that weren't processed successfully (failed) by the export job, if any.

        • (string) --
      • Id (string) --

        The unique identifier for the export job.

      • JobStatus (string) --

        The status of the export job. The job status is FAILED if Amazon Pinpoint wasn't able to process one or more pieces in the job.

      • TotalFailures (integer) --

        The total number of endpoint definitions that weren't processed successfully (failed) by the export job, typically because an error, such as a syntax error, occurred.

      • TotalPieces (integer) --

        The total number of pieces that must be processed to complete the export job. Each piece consists of an approximately equal portion of the endpoint definitions that are part of the export job.

      • TotalProcessed (integer) --

        The total number of endpoint definitions that were processed by the export job.

      • Type (string) --

        The job type. This value is EXPORT for export jobs.

create_import_job(**kwargs)

Creates a new import job for an application.

See also: AWS API Documentation

Request Syntax

response = client.create_import_job(
    ApplicationId='string',
    ImportJobRequest={
        'DefineSegment': True|False,
        'ExternalId': 'string',
        'Format': 'CSV'|'JSON',
        'RegisterEndpoints': True|False,
        'RoleArn': 'string',
        'S3Url': 'string',
        'SegmentId': 'string',
        'SegmentName': 'string'
    }
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • ImportJobRequest (dict) --

    [REQUIRED]

    Specifies the settings for a job that imports endpoint definitions from an Amazon Simple Storage Service (Amazon S3) bucket.

    • DefineSegment (boolean) --

      Specifies whether to create a segment that contains the endpoints, when the endpoint definitions are imported.

    • ExternalId (string) --

      (Deprecated) Your AWS account ID, which you assigned to an external ID key in an IAM trust policy. Amazon Pinpoint previously used this value to assume an IAM role when importing endpoint definitions, but we removed this requirement. We don't recommend use of external IDs for IAM roles that are assumed by Amazon Pinpoint.

    • Format (string) -- [REQUIRED]

      The format of the files that contain the endpoint definitions to import. Valid values are: CSV, for comma-separated values format; and, JSON, for newline-delimited JSON format. If the Amazon S3 location stores multiple files that use different formats, Amazon Pinpoint imports data only from the files that use the specified format.

    • RegisterEndpoints (boolean) --

      Specifies whether to register the endpoints with Amazon Pinpoint, when the endpoint definitions are imported.

    • RoleArn (string) -- [REQUIRED]

      The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorizes Amazon Pinpoint to access the Amazon S3 location to import endpoint definitions from.

    • S3Url (string) -- [REQUIRED]

      The URL of the Amazon Simple Storage Service (Amazon S3) bucket that contains the endpoint definitions to import. This location can be a folder or a single file. If the location is a folder, Amazon Pinpoint imports endpoint definitions from the files in this location, including any subfolders that the folder contains.

      The URL should be in the following format: s3://bucket-name/folder-name/file-name. The location can end with the key for an individual object or a prefix that qualifies multiple objects.

    • SegmentId (string) --

      The identifier for the segment to update or add the imported endpoint definitions to, if the import job is meant to update an existing segment.

    • SegmentName (string) --

      The custom name for the segment that's created by the import job, if the value of the DefineSegment property is true.

Return type

dict

Returns

Response Syntax

{
    'ImportJobResponse': {
        'ApplicationId': 'string',
        'CompletedPieces': 123,
        'CompletionDate': 'string',
        'CreationDate': 'string',
        'Definition': {
            'DefineSegment': True|False,
            'ExternalId': 'string',
            'Format': 'CSV'|'JSON',
            'RegisterEndpoints': True|False,
            'RoleArn': 'string',
            'S3Url': 'string',
            'SegmentId': 'string',
            'SegmentName': 'string'
        },
        'FailedPieces': 123,
        'Failures': [
            'string',
        ],
        'Id': 'string',
        'JobStatus': 'CREATED'|'INITIALIZING'|'PROCESSING'|'COMPLETING'|'COMPLETED'|'FAILING'|'FAILED',
        'TotalFailures': 123,
        'TotalPieces': 123,
        'TotalProcessed': 123,
        'Type': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded and the specified resource was created.

    • ImportJobResponse (dict) --

      Provides information about the status and settings of a job that imports endpoint definitions from one or more files. The files can be stored in an Amazon Simple Storage Service (Amazon S3) bucket or uploaded directly from a computer by using the Amazon Pinpoint console.

      • ApplicationId (string) --

        The unique identifier for the application that's associated with the import job.

      • CompletedPieces (integer) --

        The number of pieces that were processed successfully (completed) by the import job, as of the time of the request.

      • CompletionDate (string) --

        The date, in ISO 8601 format, when the import job was completed.

      • CreationDate (string) --

        The date, in ISO 8601 format, when the import job was created.

      • Definition (dict) --

        The resource settings that apply to the import job.

        • DefineSegment (boolean) --

          Specifies whether the import job creates a segment that contains the endpoints, when the endpoint definitions are imported.

        • ExternalId (string) --

          (Deprecated) Your AWS account ID, which you assigned to an external ID key in an IAM trust policy. Amazon Pinpoint previously used this value to assume an IAM role when importing endpoint definitions, but we removed this requirement. We don't recommend use of external IDs for IAM roles that are assumed by Amazon Pinpoint.

        • Format (string) --

          The format of the files that contain the endpoint definitions to import. Valid values are: CSV, for comma-separated values format; and, JSON, for newline-delimited JSON format.

          If the files are stored in an Amazon S3 location and that location contains multiple files that use different formats, Amazon Pinpoint imports data only from the files that use the specified format.

        • RegisterEndpoints (boolean) --

          Specifies whether the import job registers the endpoints with Amazon Pinpoint, when the endpoint definitions are imported.

        • RoleArn (string) --

          The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorizes Amazon Pinpoint to access the Amazon S3 location to import endpoint definitions from.

        • S3Url (string) --

          The URL of the Amazon Simple Storage Service (Amazon S3) bucket that contains the endpoint definitions to import. This location can be a folder or a single file. If the location is a folder, Amazon Pinpoint imports endpoint definitions from the files in this location, including any subfolders that the folder contains.

          The URL should be in the following format: s3://bucket-name/folder-name/file-name. The location can end with the key for an individual object or a prefix that qualifies multiple objects.

        • SegmentId (string) --

          The identifier for the segment that the import job updates or adds endpoint definitions to, if the import job updates an existing segment.

        • SegmentName (string) --

          The custom name for the segment that's created by the import job, if the value of the DefineSegment property is true.

      • FailedPieces (integer) --

        The number of pieces that weren't processed successfully (failed) by the import job, as of the time of the request.

      • Failures (list) --

        An array of entries, one for each of the first 100 entries that weren't processed successfully (failed) by the import job, if any.

        • (string) --
      • Id (string) --

        The unique identifier for the import job.

      • JobStatus (string) --

        The status of the import job. The job status is FAILED if Amazon Pinpoint wasn't able to process one or more pieces in the job.

      • TotalFailures (integer) --

        The total number of endpoint definitions that weren't processed successfully (failed) by the import job, typically because an error, such as a syntax error, occurred.

      • TotalPieces (integer) --

        The total number of pieces that must be processed to complete the import job. Each piece consists of an approximately equal portion of the endpoint definitions that are part of the import job.

      • TotalProcessed (integer) --

        The total number of endpoint definitions that were processed by the import job.

      • Type (string) --

        The job type. This value is IMPORT for import jobs.

create_segment(**kwargs)

Creates a new segment for an application or updates the configuration, dimension, and other settings for an existing segment that's associated with an application.

See also: AWS API Documentation

Request Syntax

response = client.create_segment(
    ApplicationId='string',
    WriteSegmentRequest={
        'Dimensions': {
            'Attributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Behavior': {
                'Recency': {
                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                    'RecencyType': 'ACTIVE'|'INACTIVE'
                }
            },
            'Demographic': {
                'AppVersion': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Channel': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'DeviceType': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Make': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Model': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Platform': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Location': {
                'Country': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'GPSPoint': {
                    'Coordinates': {
                        'Latitude': 123.0,
                        'Longitude': 123.0
                    },
                    'RangeInKilometers': 123.0
                }
            },
            'Metrics': {
                'string': {
                    'ComparisonOperator': 'string',
                    'Value': 123.0
                }
            },
            'UserAttributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            }
        },
        'Name': 'string',
        'SegmentGroups': {
            'Groups': [
                {
                    'Dimensions': [
                        {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Behavior': {
                                'Recency': {
                                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                                    'RecencyType': 'ACTIVE'|'INACTIVE'
                                }
                            },
                            'Demographic': {
                                'AppVersion': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Channel': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'DeviceType': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Make': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Model': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Platform': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Location': {
                                'Country': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'GPSPoint': {
                                    'Coordinates': {
                                        'Latitude': 123.0,
                                        'Longitude': 123.0
                                    },
                                    'RangeInKilometers': 123.0
                                }
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            },
                            'UserAttributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            }
                        },
                    ],
                    'SourceSegments': [
                        {
                            'Id': 'string',
                            'Version': 123
                        },
                    ],
                    'SourceType': 'ALL'|'ANY'|'NONE',
                    'Type': 'ALL'|'ANY'|'NONE'
                },
            ],
            'Include': 'ALL'|'ANY'|'NONE'
        },
        'tags': {
            'string': 'string'
        }
    }
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • WriteSegmentRequest (dict) --

    [REQUIRED]

    Specifies the configuration, dimension, and other settings for a segment. A WriteSegmentRequest object can include a Dimensions object or a SegmentGroups object, but not both.

    • Dimensions (dict) --

      The criteria that define the dimensions for the segment.

      • Attributes (dict) --

        One or more custom attributes to use as criteria for the segment.

        • (string) --
          • (dict) --

            Specifies attribute-based criteria for including or excluding endpoints from a segment.

            • AttributeType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) -- [REQUIRED]

              The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

              • (string) --
      • Behavior (dict) --

        The behavior-based criteria, such as how recently users have used your app, for the segment.

        • Recency (dict) --

          The dimension settings that are based on how recently an endpoint was active.

          • Duration (string) -- [REQUIRED]

            The duration to use when determining whether an endpoint is active or inactive.

          • RecencyType (string) -- [REQUIRED]

            The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

      • Demographic (dict) --

        The demographic-based criteria, such as device platform, for the segment.

        • AppVersion (dict) --

          The app version criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • Channel (dict) --

          The channel criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • DeviceType (dict) --

          The device type criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • Make (dict) --

          The device make criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • Model (dict) --

          The device model criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • Platform (dict) --

          The device platform criteria for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
      • Location (dict) --

        The location-based criteria, such as region or GPS coordinates, for the segment.

        • Country (dict) --

          The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

          • DimensionType (string) --

            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

          • Values (list) -- [REQUIRED]

            The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

            • (string) --
        • GPSPoint (dict) --

          The GPS location and range for the segment.

          • Coordinates (dict) -- [REQUIRED]

            The GPS coordinates to measure distance from.

            • Latitude (float) -- [REQUIRED]

              The latitude coordinate of the location.

            • Longitude (float) -- [REQUIRED]

              The longitude coordinate of the location.

          • RangeInKilometers (float) --

            The range, in kilometers, from the GPS coordinates.

      • Metrics (dict) --

        One or more custom metrics to use as criteria for the segment.

        • (string) --
          • (dict) --

            Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

            • ComparisonOperator (string) -- [REQUIRED]

              The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

            • Value (float) -- [REQUIRED]

              The value to compare.

      • UserAttributes (dict) --

        One or more custom user attributes to use as criteria for the segment.

        • (string) --
          • (dict) --

            Specifies attribute-based criteria for including or excluding endpoints from a segment.

            • AttributeType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) -- [REQUIRED]

              The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

              • (string) --
    • Name (string) --

      The name of the segment.

    • SegmentGroups (dict) --

      The segment group to use and the dimensions to apply to the group's base segments in order to build the segment. A segment group can consist of zero or more base segments. Your request can include only one segment group.

      • Groups (list) --

        An array that defines the set of segment criteria to evaluate when handling segment groups for the segment.

        • (dict) --

          Specifies the base segments and dimensions for a segment, and the relationships between these base segments and dimensions.

          • Dimensions (list) --

            An array that defines the dimensions for the segment.

            • (dict) --

              Specifies the dimension settings for a segment.

              • Attributes (dict) --

                One or more custom attributes to use as criteria for the segment.

                • (string) --
                  • (dict) --

                    Specifies attribute-based criteria for including or excluding endpoints from a segment.

                    • AttributeType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) -- [REQUIRED]

                      The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                      • (string) --
              • Behavior (dict) --

                The behavior-based criteria, such as how recently users have used your app, for the segment.

                • Recency (dict) --

                  The dimension settings that are based on how recently an endpoint was active.

                  • Duration (string) -- [REQUIRED]

                    The duration to use when determining whether an endpoint is active or inactive.

                  • RecencyType (string) -- [REQUIRED]

                    The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

              • Demographic (dict) --

                The demographic-based criteria, such as device platform, for the segment.

                • AppVersion (dict) --

                  The app version criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Channel (dict) --

                  The channel criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • DeviceType (dict) --

                  The device type criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Make (dict) --

                  The device make criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Model (dict) --

                  The device model criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Platform (dict) --

                  The device platform criteria for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
              • Location (dict) --

                The location-based criteria, such as region or GPS coordinates, for the segment.

                • Country (dict) --

                  The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) -- [REQUIRED]

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • GPSPoint (dict) --

                  The GPS location and range for the segment.

                  • Coordinates (dict) -- [REQUIRED]

                    The GPS coordinates to measure distance from.

                    • Latitude (float) -- [REQUIRED]

                      The latitude coordinate of the location.

                    • Longitude (float) -- [REQUIRED]

                      The longitude coordinate of the location.

                  • RangeInKilometers (float) --

                    The range, in kilometers, from the GPS coordinates.

              • Metrics (dict) --

                One or more custom metrics to use as criteria for the segment.

                • (string) --
                  • (dict) --

                    Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                    • ComparisonOperator (string) -- [REQUIRED]

                      The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                    • Value (float) -- [REQUIRED]

                      The value to compare.

              • UserAttributes (dict) --

                One or more custom user attributes to use as criteria for the segment.

                • (string) --
                  • (dict) --

                    Specifies attribute-based criteria for including or excluding endpoints from a segment.

                    • AttributeType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) -- [REQUIRED]

                      The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                      • (string) --
          • SourceSegments (list) --

            The base segment to build the segment on. A base segment, also referred to as a source segment , defines the initial population of endpoints for a segment. When you add dimensions to a segment, Amazon Pinpoint filters the base segment by using the dimensions that you specify.

            You can specify more than one dimensional segment or only one imported segment. If you specify an imported segment, the Amazon Pinpoint console displays a segment size estimate that indicates the size of the imported segment without any filters applied to it.

            • (dict) --

              Specifies the segment identifier and version of a segment.

              • Id (string) -- [REQUIRED]

                The unique identifier for the segment.

              • Version (integer) --

                The version number of the segment.

          • SourceType (string) --

            Specifies how to handle multiple base segments for the segment. For example, if you specify three base segments for the segment, whether the resulting segment is based on all, any, or none of the base segments.

          • Type (string) --

            Specifies how to handle multiple dimensions for the segment. For example, if you specify three dimensions for the segment, whether the resulting segment includes endpoints that match all, any, or none of the dimensions.

      • Include (string) --

        Specifies how to handle multiple segment groups for the segment. For example, if the segment includes three segment groups, whether the resulting segment includes endpoints that match all, any, or none of the segment groups.

    • tags (dict) --

      A string-to-string map of key-value pairs that defines the tags to associate with the segment. Each tag consists of a required tag key and an associated tag value.

      • (string) --
        • (string) --
Return type

dict

Returns

Response Syntax

{
    'SegmentResponse': {
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'Dimensions': {
            'Attributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Behavior': {
                'Recency': {
                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                    'RecencyType': 'ACTIVE'|'INACTIVE'
                }
            },
            'Demographic': {
                'AppVersion': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Channel': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'DeviceType': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Make': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Model': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Platform': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Location': {
                'Country': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'GPSPoint': {
                    'Coordinates': {
                        'Latitude': 123.0,
                        'Longitude': 123.0
                    },
                    'RangeInKilometers': 123.0
                }
            },
            'Metrics': {
                'string': {
                    'ComparisonOperator': 'string',
                    'Value': 123.0
                }
            },
            'UserAttributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            }
        },
        'Id': 'string',
        'ImportDefinition': {
            'ChannelCounts': {
                'string': 123
            },
            'ExternalId': 'string',
            'Format': 'CSV'|'JSON',
            'RoleArn': 'string',
            'S3Url': 'string',
            'Size': 123
        },
        'LastModifiedDate': 'string',
        'Name': 'string',
        'SegmentGroups': {
            'Groups': [
                {
                    'Dimensions': [
                        {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Behavior': {
                                'Recency': {
                                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                                    'RecencyType': 'ACTIVE'|'INACTIVE'
                                }
                            },
                            'Demographic': {
                                'AppVersion': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Channel': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'DeviceType': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Make': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Model': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Platform': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Location': {
                                'Country': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'GPSPoint': {
                                    'Coordinates': {
                                        'Latitude': 123.0,
                                        'Longitude': 123.0
                                    },
                                    'RangeInKilometers': 123.0
                                }
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            },
                            'UserAttributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            }
                        },
                    ],
                    'SourceSegments': [
                        {
                            'Id': 'string',
                            'Version': 123
                        },
                    ],
                    'SourceType': 'ALL'|'ANY'|'NONE',
                    'Type': 'ALL'|'ANY'|'NONE'
                },
            ],
            'Include': 'ALL'|'ANY'|'NONE'
        },
        'SegmentType': 'DIMENSIONAL'|'IMPORT',
        'tags': {
            'string': 'string'
        },
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded and the specified resource was created.

    • SegmentResponse (dict) --

      Provides information about the configuration, dimension, and other settings for a segment.

      • ApplicationId (string) --

        The unique identifier for the application that the segment is associated with.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the segment.

      • CreationDate (string) --

        The date and time when the segment was created.

      • Dimensions (dict) --

        The dimension settings for the segment.

        • Attributes (dict) --

          One or more custom attributes to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies attribute-based criteria for including or excluding endpoints from a segment.

              • AttributeType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                • (string) --
        • Behavior (dict) --

          The behavior-based criteria, such as how recently users have used your app, for the segment.

          • Recency (dict) --

            The dimension settings that are based on how recently an endpoint was active.

            • Duration (string) --

              The duration to use when determining whether an endpoint is active or inactive.

            • RecencyType (string) --

              The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

        • Demographic (dict) --

          The demographic-based criteria, such as device platform, for the segment.

          • AppVersion (dict) --

            The app version criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Channel (dict) --

            The channel criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • DeviceType (dict) --

            The device type criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Make (dict) --

            The device make criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Model (dict) --

            The device model criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Platform (dict) --

            The device platform criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
        • Location (dict) --

          The location-based criteria, such as region or GPS coordinates, for the segment.

          • Country (dict) --

            The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • GPSPoint (dict) --

            The GPS location and range for the segment.

            • Coordinates (dict) --

              The GPS coordinates to measure distance from.

              • Latitude (float) --

                The latitude coordinate of the location.

              • Longitude (float) --

                The longitude coordinate of the location.

            • RangeInKilometers (float) --

              The range, in kilometers, from the GPS coordinates.

        • Metrics (dict) --

          One or more custom metrics to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

              • ComparisonOperator (string) --

                The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

              • Value (float) --

                The value to compare.

        • UserAttributes (dict) --

          One or more custom user attributes to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies attribute-based criteria for including or excluding endpoints from a segment.

              • AttributeType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                • (string) --
      • Id (string) --

        The unique identifier for the segment.

      • ImportDefinition (dict) --

        The settings for the import job that's associated with the segment.

        • ChannelCounts (dict) --

          The number of channel types in the endpoint definitions that were imported to create the segment.

          • (string) --
            • (integer) --
        • ExternalId (string) --

          (Deprecated) Your AWS account ID, which you assigned to an external ID key in an IAM trust policy. Amazon Pinpoint previously used this value to assume an IAM role when importing endpoint definitions, but we removed this requirement. We don't recommend use of external IDs for IAM roles that are assumed by Amazon Pinpoint.

        • Format (string) --

          The format of the files that were imported to create the segment. Valid values are: CSV, for comma-separated values format; and, JSON, for newline-delimited JSON format.

        • RoleArn (string) --

          The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorized Amazon Pinpoint to access the Amazon S3 location to import endpoint definitions from.

        • S3Url (string) --

          The URL of the Amazon Simple Storage Service (Amazon S3) bucket that the endpoint definitions were imported from to create the segment.

        • Size (integer) --

          The number of endpoint definitions that were imported successfully to create the segment.

      • LastModifiedDate (string) --

        The date and time when the segment was last modified.

      • Name (string) --

        The name of the segment.

      • SegmentGroups (dict) --

        A list of one or more segment groups that apply to the segment. Each segment group consists of zero or more base segments and the dimensions that are applied to those base segments.

        • Groups (list) --

          An array that defines the set of segment criteria to evaluate when handling segment groups for the segment.

          • (dict) --

            Specifies the base segments and dimensions for a segment, and the relationships between these base segments and dimensions.

            • Dimensions (list) --

              An array that defines the dimensions for the segment.

              • (dict) --

                Specifies the dimension settings for a segment.

                • Attributes (dict) --

                  One or more custom attributes to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • Behavior (dict) --

                  The behavior-based criteria, such as how recently users have used your app, for the segment.

                  • Recency (dict) --

                    The dimension settings that are based on how recently an endpoint was active.

                    • Duration (string) --

                      The duration to use when determining whether an endpoint is active or inactive.

                    • RecencyType (string) --

                      The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

                • Demographic (dict) --

                  The demographic-based criteria, such as device platform, for the segment.

                  • AppVersion (dict) --

                    The app version criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Channel (dict) --

                    The channel criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • DeviceType (dict) --

                    The device type criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Make (dict) --

                    The device make criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Model (dict) --

                    The device model criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Platform (dict) --

                    The device platform criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                • Location (dict) --

                  The location-based criteria, such as region or GPS coordinates, for the segment.

                  • Country (dict) --

                    The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • GPSPoint (dict) --

                    The GPS location and range for the segment.

                    • Coordinates (dict) --

                      The GPS coordinates to measure distance from.

                      • Latitude (float) --

                        The latitude coordinate of the location.

                      • Longitude (float) --

                        The longitude coordinate of the location.

                    • RangeInKilometers (float) --

                      The range, in kilometers, from the GPS coordinates.

                • Metrics (dict) --

                  One or more custom metrics to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

                • UserAttributes (dict) --

                  One or more custom user attributes to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
            • SourceSegments (list) --

              The base segment to build the segment on. A base segment, also referred to as a source segment , defines the initial population of endpoints for a segment. When you add dimensions to a segment, Amazon Pinpoint filters the base segment by using the dimensions that you specify.

              You can specify more than one dimensional segment or only one imported segment. If you specify an imported segment, the Amazon Pinpoint console displays a segment size estimate that indicates the size of the imported segment without any filters applied to it.

              • (dict) --

                Specifies the segment identifier and version of a segment.

                • Id (string) --

                  The unique identifier for the segment.

                • Version (integer) --

                  The version number of the segment.

            • SourceType (string) --

              Specifies how to handle multiple base segments for the segment. For example, if you specify three base segments for the segment, whether the resulting segment is based on all, any, or none of the base segments.

            • Type (string) --

              Specifies how to handle multiple dimensions for the segment. For example, if you specify three dimensions for the segment, whether the resulting segment includes endpoints that match all, any, or none of the dimensions.

        • Include (string) --

          Specifies how to handle multiple segment groups for the segment. For example, if the segment includes three segment groups, whether the resulting segment includes endpoints that match all, any, or none of the segment groups.

      • SegmentType (string) --

        The segment type. Valid values are:

        • DIMENSIONAL - A dynamic segment, which is a segment that uses selection criteria that you specify and is based on endpoint data that's reported by your app. Dynamic segments can change over time.
        • IMPORT - A static segment, which is a segment that uses selection criteria that you specify and is based on endpoint definitions that you import from a file. Imported segments are static; they don't change over time.
      • tags (dict) --

        A string-to-string map of key-value pairs that identifies the tags that are associated with the segment. Each tag consists of a required tag key and an associated tag value.

        • (string) --
          • (string) --
      • Version (integer) --

        The version number of the segment.

delete_adm_channel(**kwargs)

Disables the ADM channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_adm_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'ADMChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ADMChannelResponse (dict) --

      Provides information about the status and settings of the ADM (Amazon Device Messaging) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the ADM channel applies to.

      • CreationDate (string) --

        The date and time when the ADM channel was enabled.

      • Enabled (boolean) --

        Specifies whether the ADM channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the ADM channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the ADM channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the ADM channel.

      • LastModifiedDate (string) --

        The date and time when the ADM channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the ADM channel, this value is ADM.

      • Version (integer) --

        The current version of the ADM channel.

delete_apns_channel(**kwargs)

Disables the APNs channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_apns_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs channel applies to.

      • CreationDate (string) --

        The date and time when the APNs channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with APNs for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs channel.

      • LastModifiedDate (string) --

        The date and time when the APNs channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs channel, this value is APNS.

      • Version (integer) --

        The current version of the APNs channel.

delete_apns_sandbox_channel(**kwargs)

Disables the APNs sandbox channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_apns_sandbox_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSSandboxChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSSandboxChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) sandbox channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs sandbox channel applies to.

      • CreationDate (string) --

        The date and time when the APNs sandbox channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with the APNs sandbox environment for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs sandbox channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs sandbox channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs sandbox channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs sandbox channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs sandbox channel.

      • LastModifiedDate (string) --

        The date and time when the APNs sandbox channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs sandbox channel, this value is APNS_SANDBOX.

      • Version (integer) --

        The current version of the APNs sandbox channel.

delete_apns_voip_channel(**kwargs)

Disables the APNs VoIP channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_apns_voip_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSVoipChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSVoipChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) VoIP channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs VoIP channel applies to.

      • CreationDate (string) --

        The date and time when the APNs VoIP channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with APNs for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs VoIP channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs VoIP channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs VoIP channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs VoIP channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs VoIP channel.

      • LastModifiedDate (string) --

        The date and time when the APNs VoIP channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs VoIP channel, this value is APNS_VOIP.

      • Version (integer) --

        The current version of the APNs VoIP channel.

delete_apns_voip_sandbox_channel(**kwargs)

Disables the APNs VoIP sandbox channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_apns_voip_sandbox_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSVoipSandboxChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSVoipSandboxChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) VoIP sandbox channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs VoIP sandbox channel applies to.

      • CreationDate (string) --

        The date and time when the APNs VoIP sandbox channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with the APNs sandbox environment for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs VoIP sandbox channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs VoIP sandbox channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs VoIP sandbox channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs VoIP sandbox channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs VoIP sandbox channel.

      • LastModifiedDate (string) --

        The date and time when the APNs VoIP sandbox channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs VoIP sandbox channel, this value is APNS_VOIP_SANDBOX.

      • Version (integer) --

        The current version of the APNs VoIP sandbox channel.

delete_app(**kwargs)

Deletes an application.

See also: AWS API Documentation

Request Syntax

response = client.delete_app(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'ApplicationResponse': {
        'Arn': 'string',
        'Id': 'string',
        'Name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ApplicationResponse (dict) --

      Provides information about an application.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the application.

      • Id (string) --

        The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

      • Name (string) --

        The display name of the application. This name is displayed as the Project name on the Amazon Pinpoint console.

      • tags (dict) --

        A string-to-string map of key-value pairs that identifies the tags that are associated with the application. Each tag consists of a required tag key and an associated tag value.

        • (string) --
          • (string) --
delete_baidu_channel(**kwargs)

Disables the Baidu channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_baidu_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'BaiduChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Credential': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • BaiduChannelResponse (dict) --

      Provides information about the status and settings of the Baidu (Baidu Cloud Push) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the Baidu channel applies to.

      • CreationDate (string) --

        The date and time when the Baidu channel was enabled.

      • Credential (string) --

        The API key that you received from the Baidu Cloud Push service to communicate with the service.

      • Enabled (boolean) --

        Specifies whether the Baidu channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the Baidu channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the Baidu channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the Baidu channel.

      • LastModifiedDate (string) --

        The date and time when the Baidu channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the Baidu channel, this value is BAIDU.

      • Version (integer) --

        The current version of the Baidu channel.

delete_campaign(**kwargs)

Deletes a campaign from an application.

See also: AWS API Documentation

Request Syntax

response = client.delete_campaign(
    ApplicationId='string',
    CampaignId='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

Return type

dict

Returns

Response Syntax

{
    'CampaignResponse': {
        'AdditionalTreatments': [
            {
                'Id': 'string',
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SizePercent': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string'
            },
        ],
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'DefaultState': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'Description': 'string',
        'HoldoutPercent': 123,
        'Hook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'Id': 'string',
        'IsPaused': True|False,
        'LastModifiedDate': 'string',
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'MessageConfiguration': {
            'ADMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'APNSMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'BaiduMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'DefaultMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'EmailMessage': {
                'Body': 'string',
                'FromAddress': 'string',
                'HtmlBody': 'string',
                'Title': 'string'
            },
            'GCMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'SMSMessage': {
                'Body': 'string',
                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                'SenderId': 'string'
            }
        },
        'Name': 'string',
        'Schedule': {
            'EndTime': 'string',
            'EventFilter': {
                'Dimensions': {
                    'Attributes': {
                        'string': {
                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                            'Values': [
                                'string',
                            ]
                        }
                    },
                    'EventType': {
                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                        'Values': [
                            'string',
                        ]
                    },
                    'Metrics': {
                        'string': {
                            'ComparisonOperator': 'string',
                            'Value': 123.0
                        }
                    }
                },
                'FilterType': 'SYSTEM'|'ENDPOINT'
            },
            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
            'IsLocalTime': True|False,
            'QuietTime': {
                'End': 'string',
                'Start': 'string'
            },
            'StartTime': 'string',
            'Timezone': 'string'
        },
        'SegmentId': 'string',
        'SegmentVersion': 123,
        'State': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'tags': {
            'string': 'string'
        },
        'TreatmentDescription': 'string',
        'TreatmentName': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignResponse (dict) --

      Provides information about the status, configuration, and other settings for a campaign.

      • AdditionalTreatments (list) --

        An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

        • (dict) --

          Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

          • Id (string) --

            The unique identifier for the treatment.

          • MessageConfiguration (dict) --

            The message configuration settings for the treatment.

            • ADMMessage (dict) --

              The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • APNSMessage (dict) --

              The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • BaiduMessage (dict) --

              The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • DefaultMessage (dict) --

              The default message that the campaign sends through all the channels that are configured for the campaign.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • EmailMessage (dict) --

              The message that the campaign sends through the email channel.

              • Body (string) --

                The body of the email for recipients whose email clients don't support HTML content.

              • FromAddress (string) --

                The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

              • HtmlBody (string) --

                The body of the email, in HTML format, for recipients whose email clients support HTML content.

              • Title (string) --

                The subject line, or title, of the email.

            • GCMMessage (dict) --

              The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • SMSMessage (dict) --

              The message that the campaign sends through the SMS channel.

              • Body (string) --

                The body of the SMS message.

              • MessageType (string) --

                The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

              • SenderId (string) --

                The sender ID to display on recipients' devices when they receive the SMS message.

          • Schedule (dict) --

            The schedule settings for the treatment.

            • EndTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to end.

            • EventFilter (dict) --

              The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

              • Dimensions (dict) --

                The dimension settings of the event filter for the campaign.

                • Attributes (dict) --

                  One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • EventType (dict) --

                  The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Metrics (dict) --

                  One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

              • FilterType (string) --

                The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

            • Frequency (string) --

              Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

            • IsLocalTime (boolean) --

              Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

            • QuietTime (dict) --

              The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

              • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
              • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
              • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

              If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

              • End (string) --

                The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

              • Start (string) --

                The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • StartTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to begin.

            • Timezone (string) --

              The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

          • SizePercent (integer) --

            The allocated percentage of users (segment members) that the treatment is sent to.

          • State (dict) --

            The status of the treatment.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • TreatmentDescription (string) --

            The custom description of the treatment.

          • TreatmentName (string) --

            The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

      • ApplicationId (string) --

        The unique identifier for the application that the campaign applies to.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the campaign.

      • CreationDate (string) --

        The date, ISO 8601 format, when the campaign was created.

      • DefaultState (dict) --

        The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment, to support A/B testing.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • Description (string) --

        The custom description of the campaign.

      • HoldoutPercent (integer) --

        The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

      • Hook (dict) --

        The settings for the AWS Lambda function to use as a code hook for the campaign.

        • LambdaFunctionName (string) --

          The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

        • Mode (string) --

          Specifies which Lambda mode to use when invoking the AWS Lambda function.

        • WebUrl (string) --

          The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

      • Id (string) --

        The unique identifier for the campaign.

      • IsPaused (boolean) --

        Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false.

      • LastModifiedDate (string) --

        The date, in ISO 8601 format, when the campaign was last modified.

      • Limits (dict) --

        The messaging limits for the campaign.

        • Daily (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

        • MaximumDuration (integer) --

          The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

        • MessagesPerSecond (integer) --

          The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

        • Total (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

      • MessageConfiguration (dict) --

        The message configuration settings for the campaign.

        • ADMMessage (dict) --

          The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • APNSMessage (dict) --

          The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • BaiduMessage (dict) --

          The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • DefaultMessage (dict) --

          The default message that the campaign sends through all the channels that are configured for the campaign.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • EmailMessage (dict) --

          The message that the campaign sends through the email channel.

          • Body (string) --

            The body of the email for recipients whose email clients don't support HTML content.

          • FromAddress (string) --

            The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

          • HtmlBody (string) --

            The body of the email, in HTML format, for recipients whose email clients support HTML content.

          • Title (string) --

            The subject line, or title, of the email.

        • GCMMessage (dict) --

          The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • SMSMessage (dict) --

          The message that the campaign sends through the SMS channel.

          • Body (string) --

            The body of the SMS message.

          • MessageType (string) --

            The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

          • SenderId (string) --

            The sender ID to display on recipients' devices when they receive the SMS message.

      • Name (string) --

        The name of the campaign.

      • Schedule (dict) --

        The schedule settings for the campaign.

        • EndTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to end.

        • EventFilter (dict) --

          The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

          • Dimensions (dict) --

            The dimension settings of the event filter for the campaign.

            • Attributes (dict) --

              One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies attribute-based criteria for including or excluding endpoints from a segment.

                  • AttributeType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                    • (string) --
            • EventType (dict) --

              The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

              • DimensionType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                • (string) --
            • Metrics (dict) --

              One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                  • ComparisonOperator (string) --

                    The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                  • Value (float) --

                    The value to compare.

          • FilterType (string) --

            The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

        • Frequency (string) --

          Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

        • IsLocalTime (boolean) --

          Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

        • QuietTime (dict) --

          The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

          • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
          • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
          • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

          If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

          • End (string) --

            The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

          • Start (string) --

            The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • StartTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to begin.

        • Timezone (string) --

          The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

      • SegmentId (string) --

        The unique identifier for the segment that's associated with the campaign.

      • SegmentVersion (integer) --

        The version number of the segment that's associated with the campaign.

      • State (dict) --

        The current status of the campaign.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • tags (dict) --

        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.

        • (string) --
          • (string) --
      • TreatmentDescription (string) --

        The custom description of a variation of the campaign that's used for A/B testing.

      • TreatmentName (string) --

        The custom name of a variation of the campaign that's used for A/B testing.

      • Version (integer) --

        The version number of the campaign.

delete_email_channel(**kwargs)

Disables the email channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_email_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'EmailChannelResponse': {
        'ApplicationId': 'string',
        'ConfigurationSet': 'string',
        'CreationDate': 'string',
        'Enabled': True|False,
        'FromAddress': 'string',
        'HasCredential': True|False,
        'Id': 'string',
        'Identity': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'MessagesPerSecond': 123,
        'Platform': 'string',
        'RoleArn': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • EmailChannelResponse (dict) --

      Provides information about the status and settings of the email channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the email channel applies to.

      • ConfigurationSet (string) --

        The configuration set that's applied to email that's sent through the channel by using the Amazon Pinpoint Email API .

      • CreationDate (string) --

        The date and time, in ISO 8601 format, when the email channel was enabled.

      • Enabled (boolean) --

        Specifies whether the email channel is enabled for the application.

      • FromAddress (string) --

        The verified email address that you send email from when you send email through the channel.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the email channel. This property is retained only for backward compatibility.

      • Identity (string) --

        The Amazon Resource Name (ARN) of the identity, verified with Amazon Simple Email Service (Amazon SES), that you use when you send email through the channel.

      • IsArchived (boolean) --

        Specifies whether the email channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the email channel.

      • LastModifiedDate (string) --

        The date and time, in ISO 8601 format, when the email channel was last modified.

      • MessagesPerSecond (integer) --

        The maximum number of emails that you can send through the channel each second.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the email channel, this value is EMAIL.

      • RoleArn (string) --

        The ARN of the AWS Identity and Access Management (IAM) role that Amazon Pinpoint uses to submit email-related event data for the channel.

      • Version (integer) --

        The current version of the email channel.

delete_endpoint(**kwargs)

Deletes an endpoint from an application.

See also: AWS API Documentation

Request Syntax

response = client.delete_endpoint(
    ApplicationId='string',
    EndpointId='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • EndpointId (string) --

    [REQUIRED]

    The unique identifier for the endpoint.

Return type

dict

Returns

Response Syntax

{
    'EndpointResponse': {
        'Address': 'string',
        'ApplicationId': 'string',
        'Attributes': {
            'string': [
                'string',
            ]
        },
        'ChannelType': 'GCM'|'APNS'|'APNS_SANDBOX'|'APNS_VOIP'|'APNS_VOIP_SANDBOX'|'ADM'|'SMS'|'VOICE'|'EMAIL'|'BAIDU'|'CUSTOM',
        'CohortId': 'string',
        'CreationDate': 'string',
        'Demographic': {
            'AppVersion': 'string',
            'Locale': 'string',
            'Make': 'string',
            'Model': 'string',
            'ModelVersion': 'string',
            'Platform': 'string',
            'PlatformVersion': 'string',
            'Timezone': 'string'
        },
        'EffectiveDate': 'string',
        'EndpointStatus': 'string',
        'Id': 'string',
        'Location': {
            'City': 'string',
            'Country': 'string',
            'Latitude': 123.0,
            'Longitude': 123.0,
            'PostalCode': 'string',
            'Region': 'string'
        },
        'Metrics': {
            'string': 123.0
        },
        'OptOut': 'string',
        'RequestId': 'string',
        'User': {
            'UserAttributes': {
                'string': [
                    'string',
                ]
            },
            'UserId': 'string'
        }
    }
}

Response Structure

  • (dict) --

    The request was accepted for processing. Processing may not be complete.

    • EndpointResponse (dict) --

      Provides information about the channel type and other settings for an endpoint.

      • Address (string) --

        The destination address for messages or push notifications that you send to the endpoint. The address varies by channel. For example, the address for a push-notification channel is typically the token provided by a push notification service, such as an Apple Push Notification service (APNs) device token or a Firebase Cloud Messaging (FCM) registration token. The address for the SMS channel is a phone number in E.164 format, such as +12065550100. The address for the email channel is an email address.

      • ApplicationId (string) --

        The unique identifier for the application that's associated with the endpoint.

      • Attributes (dict) --

        One or more custom attributes that describe the endpoint by associating a name with an array of values. For example, the value of a custom attribute named Interests might be: ["science", "music", "travel"]. You can use these attributes as filter criteria when you create segments.

        • (string) --
          • (list) --
            • (string) --
      • ChannelType (string) --

        The channel that's used when sending messages or push notifications to the endpoint.

      • CohortId (string) --

        A number from 0-99 that represents the cohort that the endpoint is assigned to. Endpoints are grouped into cohorts randomly, and each cohort contains approximately 1 percent of the endpoints for an application. Amazon Pinpoint assigns cohorts to the holdout or treatment allocations for campaigns.

      • CreationDate (string) --

        The date and time, in ISO 8601 format, when the endpoint was created.

      • Demographic (dict) --

        The demographic information for the endpoint, such as the time zone and platform.

        • AppVersion (string) --

          The version of the app that's associated with the endpoint.

        • Locale (string) --

          The locale of the endpoint, in the following format: the ISO 639-1 alpha-2 code, followed by an underscore (_), followed by an ISO 3166-1 alpha-2 value.

        • Make (string) --

          The manufacturer of the endpoint device, such as Apple or Samsung.

        • Model (string) --

          The model name or number of the endpoint device, such as iPhone.

        • ModelVersion (string) --

          The model version of the endpoint device.

        • Platform (string) --

          The platform of the endpoint device, such as iOS or Android.

        • PlatformVersion (string) --

          The platform version of the endpoint device.

        • Timezone (string) --

          The time zone of the endpoint, specified as a tz database name value, such as America/Los_Angeles.

      • EffectiveDate (string) --

        The date and time, in ISO 8601 format, when the endpoint was last updated.

      • EndpointStatus (string) --

        Not used.

      • Id (string) --

        The unique identifier that you assigned to the endpoint. The identifier should be a globally unique identifier (GUID) to ensure that it doesn't conflict with other endpoint identifiers that are associated with the application.

      • Location (dict) --

        The geographic information for the endpoint.

        • City (string) --

          The name of the city where the endpoint is located.

        • Country (string) --

          The two-character code, in ISO 3166-1 alpha-2 format, for the country or region where the endpoint is located. For example, US for the United States.

        • Latitude (float) --

          The latitude coordinate of the endpoint location, rounded to one decimal place.

        • Longitude (float) --

          The longitude coordinate of the endpoint location, rounded to one decimal place.

        • PostalCode (string) --

          The postal or ZIP code for the area where the endpoint is located.

        • Region (string) --

          The name of the region where the endpoint is located. For locations in the United States, this value is the name of a state.

      • Metrics (dict) --

        One or more custom metrics that your app reports to Amazon Pinpoint for the endpoint.

        • (string) --
          • (float) --
      • OptOut (string) --

        Specifies whether the user who's associated with the endpoint has opted out of receiving messages and push notifications from you. Possible values are: ALL, the user has opted out and doesn't want to receive any messages or push notifications; and, NONE, the user hasn't opted out and wants to receive all messages and push notifications.

      • RequestId (string) --

        The unique identifier for the most recent request to update the endpoint.

      • User (dict) --

        One or more custom user attributes that your app reports to Amazon Pinpoint for the user who's associated with the endpoint.

        • UserAttributes (dict) --

          One or more custom attributes that describe the user by associating a name with an array of values. For example, the value of an attribute named Interests might be: ["science", "music", "travel"]. You can use these attributes as filter criteria when you create segments.

          When you define the name of a custom attribute, avoid using the following characters: number sign (#), colon (:), question mark (?), backslash (), and slash (/). The Amazon Pinpoint console can't display attribute names that contain these characters. This limitation doesn't apply to attribute values.

          • (string) --
            • (list) --
              • (string) --
        • UserId (string) --

          The unique identifier for the user.

delete_event_stream(**kwargs)

Deletes the event stream for an application.

See also: AWS API Documentation

Request Syntax

response = client.delete_event_stream(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'EventStream': {
        'ApplicationId': 'string',
        'DestinationStreamArn': 'string',
        'ExternalId': 'string',
        'LastModifiedDate': 'string',
        'LastUpdatedBy': 'string',
        'RoleArn': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • EventStream (dict) --

      Specifies settings for publishing event data to an Amazon Kinesis data stream or an Amazon Kinesis Data Firehose delivery stream.

      • ApplicationId (string) --

        The unique identifier for the application to publish event data for.

      • DestinationStreamArn (string) --

        The Amazon Resource Name (ARN) of the Amazon Kinesis data stream or Amazon Kinesis Data Firehose delivery stream to publish event data to.

        For a Kinesis data stream, the ARN format is: arn:aws:kinesis:region:account-id:stream/stream_name

        For a Kinesis Data Firehose delivery stream, the ARN format is: arn:aws:firehose:region:account-id:deliverystream/stream_name

      • ExternalId (string) --

        (Deprecated) Your AWS account ID, which you assigned to an external ID key in an IAM trust policy. Amazon Pinpoint previously used this value to assume an IAM role when publishing event data, but we removed this requirement. We don't recommend use of external IDs for IAM roles that are assumed by Amazon Pinpoint.

      • LastModifiedDate (string) --

        The date, in ISO 8601 format, when the event stream was last modified.

      • LastUpdatedBy (string) --

        The IAM user who last modified the event stream.

      • RoleArn (string) --

        The AWS Identity and Access Management (IAM) role that authorizes Amazon Pinpoint to publish event data to the stream in your AWS account.

delete_gcm_channel(**kwargs)

Disables the GCM channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_gcm_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'GCMChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Credential': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • GCMChannelResponse (dict) --

      Provides information about the status and settings of the GCM channel for an application. The GCM channel enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service.

      • ApplicationId (string) --

        The unique identifier for the application that the GCM channel applies to.

      • CreationDate (string) --

        The date and time when the GCM channel was enabled.

      • Credential (string) --

        The API key, also referred to as a server key , that you received from Google to communicate with Google services.

      • Enabled (boolean) --

        Specifies whether the GCM channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the GCM channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the GCM channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the GCM channel.

      • LastModifiedDate (string) --

        The date and time when the GCM channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the GCM channel, this value is GCM.

      • Version (integer) --

        The current version of the GCM channel.

delete_segment(**kwargs)

Deletes a segment from an application.

See also: AWS API Documentation

Request Syntax

response = client.delete_segment(
    ApplicationId='string',
    SegmentId='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • SegmentId (string) --

    [REQUIRED]

    The unique identifier for the segment.

Return type

dict

Returns

Response Syntax

{
    'SegmentResponse': {
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'Dimensions': {
            'Attributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Behavior': {
                'Recency': {
                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                    'RecencyType': 'ACTIVE'|'INACTIVE'
                }
            },
            'Demographic': {
                'AppVersion': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Channel': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'DeviceType': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Make': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Model': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'Platform': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            },
            'Location': {
                'Country': {
                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                },
                'GPSPoint': {
                    'Coordinates': {
                        'Latitude': 123.0,
                        'Longitude': 123.0
                    },
                    'RangeInKilometers': 123.0
                }
            },
            'Metrics': {
                'string': {
                    'ComparisonOperator': 'string',
                    'Value': 123.0
                }
            },
            'UserAttributes': {
                'string': {
                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                    'Values': [
                        'string',
                    ]
                }
            }
        },
        'Id': 'string',
        'ImportDefinition': {
            'ChannelCounts': {
                'string': 123
            },
            'ExternalId': 'string',
            'Format': 'CSV'|'JSON',
            'RoleArn': 'string',
            'S3Url': 'string',
            'Size': 123
        },
        'LastModifiedDate': 'string',
        'Name': 'string',
        'SegmentGroups': {
            'Groups': [
                {
                    'Dimensions': [
                        {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Behavior': {
                                'Recency': {
                                    'Duration': 'HR_24'|'DAY_7'|'DAY_14'|'DAY_30',
                                    'RecencyType': 'ACTIVE'|'INACTIVE'
                                }
                            },
                            'Demographic': {
                                'AppVersion': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Channel': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'DeviceType': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Make': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Model': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'Platform': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'Location': {
                                'Country': {
                                    'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                },
                                'GPSPoint': {
                                    'Coordinates': {
                                        'Latitude': 123.0,
                                        'Longitude': 123.0
                                    },
                                    'RangeInKilometers': 123.0
                                }
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            },
                            'UserAttributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            }
                        },
                    ],
                    'SourceSegments': [
                        {
                            'Id': 'string',
                            'Version': 123
                        },
                    ],
                    'SourceType': 'ALL'|'ANY'|'NONE',
                    'Type': 'ALL'|'ANY'|'NONE'
                },
            ],
            'Include': 'ALL'|'ANY'|'NONE'
        },
        'SegmentType': 'DIMENSIONAL'|'IMPORT',
        'tags': {
            'string': 'string'
        },
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • SegmentResponse (dict) --

      Provides information about the configuration, dimension, and other settings for a segment.

      • ApplicationId (string) --

        The unique identifier for the application that the segment is associated with.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the segment.

      • CreationDate (string) --

        The date and time when the segment was created.

      • Dimensions (dict) --

        The dimension settings for the segment.

        • Attributes (dict) --

          One or more custom attributes to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies attribute-based criteria for including or excluding endpoints from a segment.

              • AttributeType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                • (string) --
        • Behavior (dict) --

          The behavior-based criteria, such as how recently users have used your app, for the segment.

          • Recency (dict) --

            The dimension settings that are based on how recently an endpoint was active.

            • Duration (string) --

              The duration to use when determining whether an endpoint is active or inactive.

            • RecencyType (string) --

              The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

        • Demographic (dict) --

          The demographic-based criteria, such as device platform, for the segment.

          • AppVersion (dict) --

            The app version criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Channel (dict) --

            The channel criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • DeviceType (dict) --

            The device type criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Make (dict) --

            The device make criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Model (dict) --

            The device model criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • Platform (dict) --

            The device platform criteria for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
        • Location (dict) --

          The location-based criteria, such as region or GPS coordinates, for the segment.

          • Country (dict) --

            The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

            • DimensionType (string) --

              The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

            • Values (list) --

              The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

              • (string) --
          • GPSPoint (dict) --

            The GPS location and range for the segment.

            • Coordinates (dict) --

              The GPS coordinates to measure distance from.

              • Latitude (float) --

                The latitude coordinate of the location.

              • Longitude (float) --

                The longitude coordinate of the location.

            • RangeInKilometers (float) --

              The range, in kilometers, from the GPS coordinates.

        • Metrics (dict) --

          One or more custom metrics to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

              • ComparisonOperator (string) --

                The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

              • Value (float) --

                The value to compare.

        • UserAttributes (dict) --

          One or more custom user attributes to use as criteria for the segment.

          • (string) --

            • (dict) --

              Specifies attribute-based criteria for including or excluding endpoints from a segment.

              • AttributeType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                • (string) --
      • Id (string) --

        The unique identifier for the segment.

      • ImportDefinition (dict) --

        The settings for the import job that's associated with the segment.

        • ChannelCounts (dict) --

          The number of channel types in the endpoint definitions that were imported to create the segment.

          • (string) --
            • (integer) --
        • ExternalId (string) --

          (Deprecated) Your AWS account ID, which you assigned to an external ID key in an IAM trust policy. Amazon Pinpoint previously used this value to assume an IAM role when importing endpoint definitions, but we removed this requirement. We don't recommend use of external IDs for IAM roles that are assumed by Amazon Pinpoint.

        • Format (string) --

          The format of the files that were imported to create the segment. Valid values are: CSV, for comma-separated values format; and, JSON, for newline-delimited JSON format.

        • RoleArn (string) --

          The Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role that authorized Amazon Pinpoint to access the Amazon S3 location to import endpoint definitions from.

        • S3Url (string) --

          The URL of the Amazon Simple Storage Service (Amazon S3) bucket that the endpoint definitions were imported from to create the segment.

        • Size (integer) --

          The number of endpoint definitions that were imported successfully to create the segment.

      • LastModifiedDate (string) --

        The date and time when the segment was last modified.

      • Name (string) --

        The name of the segment.

      • SegmentGroups (dict) --

        A list of one or more segment groups that apply to the segment. Each segment group consists of zero or more base segments and the dimensions that are applied to those base segments.

        • Groups (list) --

          An array that defines the set of segment criteria to evaluate when handling segment groups for the segment.

          • (dict) --

            Specifies the base segments and dimensions for a segment, and the relationships between these base segments and dimensions.

            • Dimensions (list) --

              An array that defines the dimensions for the segment.

              • (dict) --

                Specifies the dimension settings for a segment.

                • Attributes (dict) --

                  One or more custom attributes to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • Behavior (dict) --

                  The behavior-based criteria, such as how recently users have used your app, for the segment.

                  • Recency (dict) --

                    The dimension settings that are based on how recently an endpoint was active.

                    • Duration (string) --

                      The duration to use when determining whether an endpoint is active or inactive.

                    • RecencyType (string) --

                      The type of recency dimension to use for the segment. Valid values are: ACTIVE, endpoints that were active within the specified duration are included in the segment; and, INACTIVE, endpoints that weren't active within the specified duration are included in the segment.

                • Demographic (dict) --

                  The demographic-based criteria, such as device platform, for the segment.

                  • AppVersion (dict) --

                    The app version criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Channel (dict) --

                    The channel criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • DeviceType (dict) --

                    The device type criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Make (dict) --

                    The device make criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Model (dict) --

                    The device model criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • Platform (dict) --

                    The device platform criteria for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                • Location (dict) --

                  The location-based criteria, such as region or GPS coordinates, for the segment.

                  • Country (dict) --

                    The country or region code, in ISO 3166-1 alpha-2 format, for the segment.

                    • DimensionType (string) --

                      The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                    • Values (list) --

                      The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                      • (string) --
                  • GPSPoint (dict) --

                    The GPS location and range for the segment.

                    • Coordinates (dict) --

                      The GPS coordinates to measure distance from.

                      • Latitude (float) --

                        The latitude coordinate of the location.

                      • Longitude (float) --

                        The longitude coordinate of the location.

                    • RangeInKilometers (float) --

                      The range, in kilometers, from the GPS coordinates.

                • Metrics (dict) --

                  One or more custom metrics to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

                • UserAttributes (dict) --

                  One or more custom user attributes to use as criteria for the segment.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
            • SourceSegments (list) --

              The base segment to build the segment on. A base segment, also referred to as a source segment , defines the initial population of endpoints for a segment. When you add dimensions to a segment, Amazon Pinpoint filters the base segment by using the dimensions that you specify.

              You can specify more than one dimensional segment or only one imported segment. If you specify an imported segment, the Amazon Pinpoint console displays a segment size estimate that indicates the size of the imported segment without any filters applied to it.

              • (dict) --

                Specifies the segment identifier and version of a segment.

                • Id (string) --

                  The unique identifier for the segment.

                • Version (integer) --

                  The version number of the segment.

            • SourceType (string) --

              Specifies how to handle multiple base segments for the segment. For example, if you specify three base segments for the segment, whether the resulting segment is based on all, any, or none of the base segments.

            • Type (string) --

              Specifies how to handle multiple dimensions for the segment. For example, if you specify three dimensions for the segment, whether the resulting segment includes endpoints that match all, any, or none of the dimensions.

        • Include (string) --

          Specifies how to handle multiple segment groups for the segment. For example, if the segment includes three segment groups, whether the resulting segment includes endpoints that match all, any, or none of the segment groups.

      • SegmentType (string) --

        The segment type. Valid values are:

        • DIMENSIONAL - A dynamic segment, which is a segment that uses selection criteria that you specify and is based on endpoint data that's reported by your app. Dynamic segments can change over time.
        • IMPORT - A static segment, which is a segment that uses selection criteria that you specify and is based on endpoint definitions that you import from a file. Imported segments are static; they don't change over time.
      • tags (dict) --

        A string-to-string map of key-value pairs that identifies the tags that are associated with the segment. Each tag consists of a required tag key and an associated tag value.

        • (string) --
          • (string) --
      • Version (integer) --

        The version number of the segment.

delete_sms_channel(**kwargs)

Disables the SMS channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_sms_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'SMSChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'PromotionalMessagesPerSecond': 123,
        'SenderId': 'string',
        'ShortCode': 'string',
        'TransactionalMessagesPerSecond': 123,
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • SMSChannelResponse (dict) --

      Provides information about the status and settings of the SMS channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the SMS channel applies to.

      • CreationDate (string) --

        The date and time, in ISO 8601 format, when the SMS channel was enabled.

      • Enabled (boolean) --

        Specifies whether the SMS channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the SMS channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the SMS channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the SMS channel.

      • LastModifiedDate (string) --

        The date and time, in ISO 8601 format, when the SMS channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the SMS channel, this value is SMS.

      • PromotionalMessagesPerSecond (integer) --

        The maximum number of promotional messages that you can send through the SMS channel each second.

      • SenderId (string) --

        The identity that displays on recipients' devices when they receive messages from the SMS channel.

      • ShortCode (string) --

        The registered short code to use when you send messages through the SMS channel.

      • TransactionalMessagesPerSecond (integer) --

        The maximum number of transactional messages that you can send through the SMS channel each second.

      • Version (integer) --

        The current version of the SMS channel.

delete_user_endpoints(**kwargs)

Deletes all the endpoints that are associated with a specific user ID.

See also: AWS API Documentation

Request Syntax

response = client.delete_user_endpoints(
    ApplicationId='string',
    UserId='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • UserId (string) --

    [REQUIRED]

    The unique identifier for the user.

Return type

dict

Returns

Response Syntax

{
    'EndpointsResponse': {
        'Item': [
            {
                'Address': 'string',
                'ApplicationId': 'string',
                'Attributes': {
                    'string': [
                        'string',
                    ]
                },
                'ChannelType': 'GCM'|'APNS'|'APNS_SANDBOX'|'APNS_VOIP'|'APNS_VOIP_SANDBOX'|'ADM'|'SMS'|'VOICE'|'EMAIL'|'BAIDU'|'CUSTOM',
                'CohortId': 'string',
                'CreationDate': 'string',
                'Demographic': {
                    'AppVersion': 'string',
                    'Locale': 'string',
                    'Make': 'string',
                    'Model': 'string',
                    'ModelVersion': 'string',
                    'Platform': 'string',
                    'PlatformVersion': 'string',
                    'Timezone': 'string'
                },
                'EffectiveDate': 'string',
                'EndpointStatus': 'string',
                'Id': 'string',
                'Location': {
                    'City': 'string',
                    'Country': 'string',
                    'Latitude': 123.0,
                    'Longitude': 123.0,
                    'PostalCode': 'string',
                    'Region': 'string'
                },
                'Metrics': {
                    'string': 123.0
                },
                'OptOut': 'string',
                'RequestId': 'string',
                'User': {
                    'UserAttributes': {
                        'string': [
                            'string',
                        ]
                    },
                    'UserId': 'string'
                }
            },
        ]
    }
}

Response Structure

  • (dict) --

    The request was accepted for processing. Processing may not be complete.

    • EndpointsResponse (dict) --

      Provides information about all the endpoints that are associated with a user ID.

      • Item (list) --

        An array of responses, one for each endpoint that's associated with the user ID.

        • (dict) --

          Provides information about the channel type and other settings for an endpoint.

          • Address (string) --

            The destination address for messages or push notifications that you send to the endpoint. The address varies by channel. For example, the address for a push-notification channel is typically the token provided by a push notification service, such as an Apple Push Notification service (APNs) device token or a Firebase Cloud Messaging (FCM) registration token. The address for the SMS channel is a phone number in E.164 format, such as +12065550100. The address for the email channel is an email address.

          • ApplicationId (string) --

            The unique identifier for the application that's associated with the endpoint.

          • Attributes (dict) --

            One or more custom attributes that describe the endpoint by associating a name with an array of values. For example, the value of a custom attribute named Interests might be: ["science", "music", "travel"]. You can use these attributes as filter criteria when you create segments.

            • (string) --
              • (list) --
                • (string) --
          • ChannelType (string) --

            The channel that's used when sending messages or push notifications to the endpoint.

          • CohortId (string) --

            A number from 0-99 that represents the cohort that the endpoint is assigned to. Endpoints are grouped into cohorts randomly, and each cohort contains approximately 1 percent of the endpoints for an application. Amazon Pinpoint assigns cohorts to the holdout or treatment allocations for campaigns.

          • CreationDate (string) --

            The date and time, in ISO 8601 format, when the endpoint was created.

          • Demographic (dict) --

            The demographic information for the endpoint, such as the time zone and platform.

            • AppVersion (string) --

              The version of the app that's associated with the endpoint.

            • Locale (string) --

              The locale of the endpoint, in the following format: the ISO 639-1 alpha-2 code, followed by an underscore (_), followed by an ISO 3166-1 alpha-2 value.

            • Make (string) --

              The manufacturer of the endpoint device, such as Apple or Samsung.

            • Model (string) --

              The model name or number of the endpoint device, such as iPhone.

            • ModelVersion (string) --

              The model version of the endpoint device.

            • Platform (string) --

              The platform of the endpoint device, such as iOS or Android.

            • PlatformVersion (string) --

              The platform version of the endpoint device.

            • Timezone (string) --

              The time zone of the endpoint, specified as a tz database name value, such as America/Los_Angeles.

          • EffectiveDate (string) --

            The date and time, in ISO 8601 format, when the endpoint was last updated.

          • EndpointStatus (string) --

            Not used.

          • Id (string) --

            The unique identifier that you assigned to the endpoint. The identifier should be a globally unique identifier (GUID) to ensure that it doesn't conflict with other endpoint identifiers that are associated with the application.

          • Location (dict) --

            The geographic information for the endpoint.

            • City (string) --

              The name of the city where the endpoint is located.

            • Country (string) --

              The two-character code, in ISO 3166-1 alpha-2 format, for the country or region where the endpoint is located. For example, US for the United States.

            • Latitude (float) --

              The latitude coordinate of the endpoint location, rounded to one decimal place.

            • Longitude (float) --

              The longitude coordinate of the endpoint location, rounded to one decimal place.

            • PostalCode (string) --

              The postal or ZIP code for the area where the endpoint is located.

            • Region (string) --

              The name of the region where the endpoint is located. For locations in the United States, this value is the name of a state.

          • Metrics (dict) --

            One or more custom metrics that your app reports to Amazon Pinpoint for the endpoint.

            • (string) --
              • (float) --
          • OptOut (string) --

            Specifies whether the user who's associated with the endpoint has opted out of receiving messages and push notifications from you. Possible values are: ALL, the user has opted out and doesn't want to receive any messages or push notifications; and, NONE, the user hasn't opted out and wants to receive all messages and push notifications.

          • RequestId (string) --

            The unique identifier for the most recent request to update the endpoint.

          • User (dict) --

            One or more custom user attributes that your app reports to Amazon Pinpoint for the user who's associated with the endpoint.

            • UserAttributes (dict) --

              One or more custom attributes that describe the user by associating a name with an array of values. For example, the value of an attribute named Interests might be: ["science", "music", "travel"]. You can use these attributes as filter criteria when you create segments.

              When you define the name of a custom attribute, avoid using the following characters: number sign (#), colon (:), question mark (?), backslash (), and slash (/). The Amazon Pinpoint console can't display attribute names that contain these characters. This limitation doesn't apply to attribute values.

              • (string) --
                • (list) --
                  • (string) --
            • UserId (string) --

              The unique identifier for the user.

delete_voice_channel(**kwargs)

Disables the voice channel for an application and deletes any existing settings for the channel.

See also: AWS API Documentation

Request Syntax

response = client.delete_voice_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'VoiceChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • VoiceChannelResponse (dict) --

      Provides information about the status and settings of the voice channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the voice channel applies to.

      • CreationDate (string) --

        The date and time, in ISO 8601 format, when the voice channel was enabled.

      • Enabled (boolean) --

        Specifies whether the voice channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the voice channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the voice channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the voice channel.

      • LastModifiedDate (string) --

        The date and time, in ISO 8601 format, when the voice channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the voice channel, this value is VOICE.

      • Version (integer) --

        The current version of the voice channel.

generate_presigned_url(ClientMethod, Params=None, ExpiresIn=3600, HttpMethod=None)

Generate a presigned url given a client, its method, and arguments

Parameters
  • ClientMethod (string) -- The client method to presign for
  • Params (dict) -- The parameters normally passed to ClientMethod.
  • ExpiresIn (int) -- The number of seconds the presigned url is valid for. By default it expires in an hour (3600 seconds)
  • HttpMethod (string) -- The http method to use on the generated url. By default, the http method is whatever is used in the method's model.
Returns

The presigned url

get_adm_channel(**kwargs)

Retrieves information about the status and settings of the ADM channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_adm_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'ADMChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ADMChannelResponse (dict) --

      Provides information about the status and settings of the ADM (Amazon Device Messaging) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the ADM channel applies to.

      • CreationDate (string) --

        The date and time when the ADM channel was enabled.

      • Enabled (boolean) --

        Specifies whether the ADM channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the ADM channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the ADM channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the ADM channel.

      • LastModifiedDate (string) --

        The date and time when the ADM channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the ADM channel, this value is ADM.

      • Version (integer) --

        The current version of the ADM channel.

get_apns_channel(**kwargs)

Retrieves information about the status and settings of the APNs channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_apns_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs channel applies to.

      • CreationDate (string) --

        The date and time when the APNs channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with APNs for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs channel.

      • LastModifiedDate (string) --

        The date and time when the APNs channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs channel, this value is APNS.

      • Version (integer) --

        The current version of the APNs channel.

get_apns_sandbox_channel(**kwargs)

Retrieves information about the status and settings of the APNs sandbox channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_apns_sandbox_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSSandboxChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSSandboxChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) sandbox channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs sandbox channel applies to.

      • CreationDate (string) --

        The date and time when the APNs sandbox channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with the APNs sandbox environment for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs sandbox channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs sandbox channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs sandbox channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs sandbox channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs sandbox channel.

      • LastModifiedDate (string) --

        The date and time when the APNs sandbox channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs sandbox channel, this value is APNS_SANDBOX.

      • Version (integer) --

        The current version of the APNs sandbox channel.

get_apns_voip_channel(**kwargs)

Retrieves information about the status and settings of the APNs VoIP channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_apns_voip_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSVoipChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSVoipChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) VoIP channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs VoIP channel applies to.

      • CreationDate (string) --

        The date and time when the APNs VoIP channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with APNs for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs VoIP channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs VoIP channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs VoIP channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs VoIP channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs VoIP channel.

      • LastModifiedDate (string) --

        The date and time when the APNs VoIP channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs VoIP channel, this value is APNS_VOIP.

      • Version (integer) --

        The current version of the APNs VoIP channel.

get_apns_voip_sandbox_channel(**kwargs)

Retrieves information about the status and settings of the APNs VoIP sandbox channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_apns_voip_sandbox_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'APNSVoipSandboxChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'DefaultAuthenticationMethod': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'HasTokenKey': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • APNSVoipSandboxChannelResponse (dict) --

      Provides information about the status and settings of the APNs (Apple Push Notification service) VoIP sandbox channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the APNs VoIP sandbox channel applies to.

      • CreationDate (string) --

        The date and time when the APNs VoIP sandbox channel was enabled.

      • DefaultAuthenticationMethod (string) --

        The default authentication method that Amazon Pinpoint uses to authenticate with the APNs sandbox environment for this channel, key or certificate.

      • Enabled (boolean) --

        Specifies whether the APNs VoIP sandbox channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • HasTokenKey (boolean) --

        Specifies whether the APNs VoIP sandbox channel is configured to communicate with APNs by using APNs tokens. To provide an authentication key for APNs tokens, set the TokenKey property of the channel.

      • Id (string) --

        (Deprecated) An identifier for the APNs VoIP sandbox channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the APNs VoIP sandbox channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the APNs VoIP sandbox channel.

      • LastModifiedDate (string) --

        The date and time when the APNs VoIP sandbox channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the APNs VoIP sandbox channel, this value is APNS_VOIP_SANDBOX.

      • Version (integer) --

        The current version of the APNs VoIP sandbox channel.

get_app(**kwargs)

Retrieves information about an application.

See also: AWS API Documentation

Request Syntax

response = client.get_app(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'ApplicationResponse': {
        'Arn': 'string',
        'Id': 'string',
        'Name': 'string',
        'tags': {
            'string': 'string'
        }
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ApplicationResponse (dict) --

      Provides information about an application.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the application.

      • Id (string) --

        The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

      • Name (string) --

        The display name of the application. This name is displayed as the Project name on the Amazon Pinpoint console.

      • tags (dict) --

        A string-to-string map of key-value pairs that identifies the tags that are associated with the application. Each tag consists of a required tag key and an associated tag value.

        • (string) --
          • (string) --
get_application_date_range_kpi(**kwargs)

Retrieves (queries) pre-aggregated data for a standard metric that applies to an application.

See also: AWS API Documentation

Request Syntax

response = client.get_application_date_range_kpi(
    ApplicationId='string',
    EndTime=datetime(2015, 1, 1),
    KpiName='string',
    NextToken='string',
    PageSize='string',
    StartTime=datetime(2015, 1, 1)
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • EndTime (datetime) -- The last date to retrieve data for, as part of an inclusive date range that filters the query results. This value should be in ISO 8601 format, for example: 2019-07-19 for July 19, 2019. To define a date range that ends at a specific time, specify the date and time in ISO 8601 format, for example: 2019-07-19T20:00Z for 8:00 PM July 19, 2019.
  • KpiName (string) --

    [REQUIRED]

    The name of the metric, also referred to as a key performance indicator (KPI) , to retrieve data for. This value describes the associated metric and consists of two or more terms, which are comprised of lowercase alphanumeric characters, separated by a hyphen. Examples are attempted-deliveries and successful-deliveries. For a list of valid values, see the Amazon Pinpoint Developer Guide .

  • NextToken (string) -- The NextToken string that specifies which page of results to return in a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • StartTime (datetime) -- The first date to retrieve data for, as part of an inclusive date range that filters the query results. This value should be in ISO 8601 format, for example: 2019-07-15 for July 15, 2019. To define a date range that begins at a specific time, specify the date and time in ISO 8601 format, for example: 2019-07-15T16:00Z for 4:00 PM July 15, 2019.
Return type

dict

Returns

Response Syntax

{
    'ApplicationDateRangeKpiResponse': {
        'ApplicationId': 'string',
        'EndTime': datetime(2015, 1, 1),
        'KpiName': 'string',
        'KpiResult': {
            'Rows': [
                {
                    'GroupedBys': [
                        {
                            'Key': 'string',
                            'Type': 'string',
                            'Value': 'string'
                        },
                    ],
                    'Values': [
                        {
                            'Key': 'string',
                            'Type': 'string',
                            'Value': 'string'
                        },
                    ]
                },
            ]
        },
        'NextToken': 'string',
        'StartTime': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ApplicationDateRangeKpiResponse (dict) --

      Provides the results of a query that retrieved the data for a standard metric that applies to an application, and provides information about that query.

      • ApplicationId (string) --

        The unique identifier for the application that the metric applies to.

      • EndTime (datetime) --

        The last date or date and time of the date range that was used to filter the query results, in ISO 8601 format. The date range is inclusive.

      • KpiName (string) --

        The name of the metric, also referred to as a key performance indicator (KPI) , that the data was retrieved for. This value describes the associated metric and consists of two or more terms, which are comprised of lowercase alphanumeric characters, separated by a hyphen. For a list of valid values, see the Amazon Pinpoint Developer Guide .

      • KpiResult (dict) --

        An array of objects that contains the results of the query. Each object contains the value for the metric and metadata about that value.

        • Rows (list) --

          An array of objects that provides the results of a query that retrieved the data for a standard metric that applies to an application or campaign.

          • (dict) --

            Provides the results of a query that retrieved the data for a standard metric that applies to an application or campaign.

            • GroupedBys (list) --

              An array of objects that defines the field and field values that were used to group data in a result set that contains multiple results. This value is null if the data in a result set isn’t grouped.

              • (dict) --

                Provides a single value and metadata about that value as part of an array of query results for a standard metric that applies to an application or campaign.

                • Key (string) --

                  The name of the field that Amazon Pinpoint uses to store the value specified by the Value property.

                • Type (string) --

                  The data type of the value specified by the Value property.

                • Value (string) --

                  In a Values object, the value for the metric that the query retrieved data for. In a GroupedBys object, the value for the field that was used to group data in a result set that contains multiple results (Values objects).

            • Values (list) --

              An array of objects that provides pre-aggregated values for a standard metric that applies to an application or campaign.

              • (dict) --

                Provides a single value and metadata about that value as part of an array of query results for a standard metric that applies to an application or campaign.

                • Key (string) --

                  The name of the field that Amazon Pinpoint uses to store the value specified by the Value property.

                • Type (string) --

                  The data type of the value specified by the Value property.

                • Value (string) --

                  In a Values object, the value for the metric that the query retrieved data for. In a GroupedBys object, the value for the field that was used to group data in a result set that contains multiple results (Values objects).

      • NextToken (string) --

        The string to use in a subsequent request to get the next page of results in a paginated response. This value is null for the App Metrics resource. The App Metrics resource returns all results in a single page.

      • StartTime (datetime) --

        The first date or date and time of the date range that was used to filter the query results, in ISO 8601 format. The date range is inclusive.

get_application_settings(**kwargs)

Retrieves information about the settings for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_application_settings(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'ApplicationSettingsResource': {
        'ApplicationId': 'string',
        'CampaignHook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'LastModifiedDate': 'string',
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'QuietTime': {
            'End': 'string',
            'Start': 'string'
        }
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ApplicationSettingsResource (dict) --

      Provides information about an application, including the default settings for an application.

      • ApplicationId (string) --

        The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

      • CampaignHook (dict) --

        The settings for the AWS Lambda function to use by default as a code hook for campaigns in the application.

        • LambdaFunctionName (string) --

          The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

        • Mode (string) --

          Specifies which Lambda mode to use when invoking the AWS Lambda function.

        • WebUrl (string) --

          The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

      • LastModifiedDate (string) --

        The date and time, in ISO 8601 format, when the application's settings were last modified.

      • Limits (dict) --

        The default sending limits for campaigns in the application.

        • Daily (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

        • MaximumDuration (integer) --

          The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

        • MessagesPerSecond (integer) --

          The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

        • Total (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

      • QuietTime (dict) --

        The default quiet time for campaigns in the application. Quiet time is a specific time range when campaigns don't send messages to endpoints, if all the following conditions are met:

        • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
        • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the application (or a campaign that has custom quiet time settings).
        • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the application (or a campaign that has custom quiet time settings).

        If any of the preceding conditions isn't met, the endpoint will receive messages from a campaign, even if quiet time is enabled.

        • End (string) --

          The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • Start (string) --

          The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

get_apps(**kwargs)

Retrieves information about all of your applications.

See also: AWS API Documentation

Request Syntax

response = client.get_apps(
    PageSize='string',
    Token='string'
)
Parameters
  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • Token (string) -- The NextToken string that specifies which page of results to return in a paginated response.
Return type

dict

Returns

Response Syntax

{
    'ApplicationsResponse': {
        'Item': [
            {
                'Arn': 'string',
                'Id': 'string',
                'Name': 'string',
                'tags': {
                    'string': 'string'
                }
            },
        ],
        'NextToken': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ApplicationsResponse (dict) --

      Provides information about all of your applications.

      • Item (list) --

        An array of responses, one for each application that was returned.

        • (dict) --

          Provides information about an application.

          • Arn (string) --

            The Amazon Resource Name (ARN) of the application.

          • Id (string) --

            The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

          • Name (string) --

            The display name of the application. This name is displayed as the Project name on the Amazon Pinpoint console.

          • tags (dict) --

            A string-to-string map of key-value pairs that identifies the tags that are associated with the application. Each tag consists of a required tag key and an associated tag value.

            • (string) --
              • (string) --
      • NextToken (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.

get_baidu_channel(**kwargs)

Retrieves information about the status and settings of the Baidu Cloud Push channel for an application.

See also: AWS API Documentation

Request Syntax

response = client.get_baidu_channel(
    ApplicationId='string'
)
Parameters
ApplicationId (string) --

[REQUIRED]

The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

Return type
dict
Returns
Response Syntax
{
    'BaiduChannelResponse': {
        'ApplicationId': 'string',
        'CreationDate': 'string',
        'Credential': 'string',
        'Enabled': True|False,
        'HasCredential': True|False,
        'Id': 'string',
        'IsArchived': True|False,
        'LastModifiedBy': 'string',
        'LastModifiedDate': 'string',
        'Platform': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • BaiduChannelResponse (dict) --

      Provides information about the status and settings of the Baidu (Baidu Cloud Push) channel for an application.

      • ApplicationId (string) --

        The unique identifier for the application that the Baidu channel applies to.

      • CreationDate (string) --

        The date and time when the Baidu channel was enabled.

      • Credential (string) --

        The API key that you received from the Baidu Cloud Push service to communicate with the service.

      • Enabled (boolean) --

        Specifies whether the Baidu channel is enabled for the application.

      • HasCredential (boolean) --

        (Not used) This property is retained only for backward compatibility.

      • Id (string) --

        (Deprecated) An identifier for the Baidu channel. This property is retained only for backward compatibility.

      • IsArchived (boolean) --

        Specifies whether the Baidu channel is archived.

      • LastModifiedBy (string) --

        The user who last modified the Baidu channel.

      • LastModifiedDate (string) --

        The date and time when the Baidu channel was last modified.

      • Platform (string) --

        The type of messaging or notification platform for the channel. For the Baidu channel, this value is BAIDU.

      • Version (integer) --

        The current version of the Baidu channel.

get_campaign(**kwargs)

Retrieves information about the status, configuration, and other settings for a campaign.

See also: AWS API Documentation

Request Syntax

response = client.get_campaign(
    ApplicationId='string',
    CampaignId='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

Return type

dict

Returns

Response Syntax

{
    'CampaignResponse': {
        'AdditionalTreatments': [
            {
                'Id': 'string',
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SizePercent': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string'
            },
        ],
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'DefaultState': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'Description': 'string',
        'HoldoutPercent': 123,
        'Hook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'Id': 'string',
        'IsPaused': True|False,
        'LastModifiedDate': 'string',
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'MessageConfiguration': {
            'ADMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'APNSMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'BaiduMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'DefaultMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'EmailMessage': {
                'Body': 'string',
                'FromAddress': 'string',
                'HtmlBody': 'string',
                'Title': 'string'
            },
            'GCMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'SMSMessage': {
                'Body': 'string',
                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                'SenderId': 'string'
            }
        },
        'Name': 'string',
        'Schedule': {
            'EndTime': 'string',
            'EventFilter': {
                'Dimensions': {
                    'Attributes': {
                        'string': {
                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                            'Values': [
                                'string',
                            ]
                        }
                    },
                    'EventType': {
                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                        'Values': [
                            'string',
                        ]
                    },
                    'Metrics': {
                        'string': {
                            'ComparisonOperator': 'string',
                            'Value': 123.0
                        }
                    }
                },
                'FilterType': 'SYSTEM'|'ENDPOINT'
            },
            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
            'IsLocalTime': True|False,
            'QuietTime': {
                'End': 'string',
                'Start': 'string'
            },
            'StartTime': 'string',
            'Timezone': 'string'
        },
        'SegmentId': 'string',
        'SegmentVersion': 123,
        'State': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'tags': {
            'string': 'string'
        },
        'TreatmentDescription': 'string',
        'TreatmentName': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignResponse (dict) --

      Provides information about the status, configuration, and other settings for a campaign.

      • AdditionalTreatments (list) --

        An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

        • (dict) --

          Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

          • Id (string) --

            The unique identifier for the treatment.

          • MessageConfiguration (dict) --

            The message configuration settings for the treatment.

            • ADMMessage (dict) --

              The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • APNSMessage (dict) --

              The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • BaiduMessage (dict) --

              The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • DefaultMessage (dict) --

              The default message that the campaign sends through all the channels that are configured for the campaign.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • EmailMessage (dict) --

              The message that the campaign sends through the email channel.

              • Body (string) --

                The body of the email for recipients whose email clients don't support HTML content.

              • FromAddress (string) --

                The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

              • HtmlBody (string) --

                The body of the email, in HTML format, for recipients whose email clients support HTML content.

              • Title (string) --

                The subject line, or title, of the email.

            • GCMMessage (dict) --

              The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • SMSMessage (dict) --

              The message that the campaign sends through the SMS channel.

              • Body (string) --

                The body of the SMS message.

              • MessageType (string) --

                The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

              • SenderId (string) --

                The sender ID to display on recipients' devices when they receive the SMS message.

          • Schedule (dict) --

            The schedule settings for the treatment.

            • EndTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to end.

            • EventFilter (dict) --

              The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

              • Dimensions (dict) --

                The dimension settings of the event filter for the campaign.

                • Attributes (dict) --

                  One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • EventType (dict) --

                  The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Metrics (dict) --

                  One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

              • FilterType (string) --

                The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

            • Frequency (string) --

              Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

            • IsLocalTime (boolean) --

              Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

            • QuietTime (dict) --

              The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

              • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
              • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
              • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

              If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

              • End (string) --

                The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

              • Start (string) --

                The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • StartTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to begin.

            • Timezone (string) --

              The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

          • SizePercent (integer) --

            The allocated percentage of users (segment members) that the treatment is sent to.

          • State (dict) --

            The status of the treatment.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • TreatmentDescription (string) --

            The custom description of the treatment.

          • TreatmentName (string) --

            The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

      • ApplicationId (string) --

        The unique identifier for the application that the campaign applies to.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the campaign.

      • CreationDate (string) --

        The date, ISO 8601 format, when the campaign was created.

      • DefaultState (dict) --

        The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment, to support A/B testing.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • Description (string) --

        The custom description of the campaign.

      • HoldoutPercent (integer) --

        The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

      • Hook (dict) --

        The settings for the AWS Lambda function to use as a code hook for the campaign.

        • LambdaFunctionName (string) --

          The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

        • Mode (string) --

          Specifies which Lambda mode to use when invoking the AWS Lambda function.

        • WebUrl (string) --

          The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

      • Id (string) --

        The unique identifier for the campaign.

      • IsPaused (boolean) --

        Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false.

      • LastModifiedDate (string) --

        The date, in ISO 8601 format, when the campaign was last modified.

      • Limits (dict) --

        The messaging limits for the campaign.

        • Daily (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

        • MaximumDuration (integer) --

          The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

        • MessagesPerSecond (integer) --

          The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

        • Total (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

      • MessageConfiguration (dict) --

        The message configuration settings for the campaign.

        • ADMMessage (dict) --

          The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • APNSMessage (dict) --

          The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • BaiduMessage (dict) --

          The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • DefaultMessage (dict) --

          The default message that the campaign sends through all the channels that are configured for the campaign.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • EmailMessage (dict) --

          The message that the campaign sends through the email channel.

          • Body (string) --

            The body of the email for recipients whose email clients don't support HTML content.

          • FromAddress (string) --

            The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

          • HtmlBody (string) --

            The body of the email, in HTML format, for recipients whose email clients support HTML content.

          • Title (string) --

            The subject line, or title, of the email.

        • GCMMessage (dict) --

          The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • SMSMessage (dict) --

          The message that the campaign sends through the SMS channel.

          • Body (string) --

            The body of the SMS message.

          • MessageType (string) --

            The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

          • SenderId (string) --

            The sender ID to display on recipients' devices when they receive the SMS message.

      • Name (string) --

        The name of the campaign.

      • Schedule (dict) --

        The schedule settings for the campaign.

        • EndTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to end.

        • EventFilter (dict) --

          The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

          • Dimensions (dict) --

            The dimension settings of the event filter for the campaign.

            • Attributes (dict) --

              One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies attribute-based criteria for including or excluding endpoints from a segment.

                  • AttributeType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                    • (string) --
            • EventType (dict) --

              The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

              • DimensionType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                • (string) --
            • Metrics (dict) --

              One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                  • ComparisonOperator (string) --

                    The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                  • Value (float) --

                    The value to compare.

          • FilterType (string) --

            The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

        • Frequency (string) --

          Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

        • IsLocalTime (boolean) --

          Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

        • QuietTime (dict) --

          The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

          • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
          • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
          • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

          If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

          • End (string) --

            The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

          • Start (string) --

            The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • StartTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to begin.

        • Timezone (string) --

          The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

      • SegmentId (string) --

        The unique identifier for the segment that's associated with the campaign.

      • SegmentVersion (integer) --

        The version number of the segment that's associated with the campaign.

      • State (dict) --

        The current status of the campaign.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • tags (dict) --

        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.

        • (string) --
          • (string) --
      • TreatmentDescription (string) --

        The custom description of a variation of the campaign that's used for A/B testing.

      • TreatmentName (string) --

        The custom name of a variation of the campaign that's used for A/B testing.

      • Version (integer) --

        The version number of the campaign.

get_campaign_activities(**kwargs)

Retrieves information about the activity performed by a campaign.

See also: AWS API Documentation

Request Syntax

response = client.get_campaign_activities(
    ApplicationId='string',
    CampaignId='string',
    PageSize='string',
    Token='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • Token (string) -- The NextToken string that specifies which page of results to return in a paginated response.
Return type

dict

Returns

Response Syntax

{
    'ActivitiesResponse': {
        'Item': [
            {
                'ApplicationId': 'string',
                'CampaignId': 'string',
                'End': 'string',
                'Id': 'string',
                'Result': 'string',
                'ScheduledStart': 'string',
                'Start': 'string',
                'State': 'string',
                'SuccessfulEndpointCount': 123,
                'TimezonesCompletedCount': 123,
                'TimezonesTotalCount': 123,
                'TotalEndpointCount': 123,
                'TreatmentId': 'string'
            },
        ],
        'NextToken': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • ActivitiesResponse (dict) --

      Provides information about the activities that were performed by a campaign.

      • Item (list) --

        An array of responses, one for each activity that was performed by the campaign.

        • (dict) --

          Provides information about an activity that was performed by a campaign.

          • ApplicationId (string) --

            The unique identifier for the application that the campaign applies to.

          • CampaignId (string) --

            The unique identifier for the campaign that the activity applies to.

          • End (string) --

            The actual time, in ISO 8601 format, when the activity was marked CANCELLED or COMPLETED.

          • Id (string) --

            The unique identifier for the activity.

          • Result (string) --

            Specifies whether the activity succeeded. Possible values are SUCCESS and FAIL.

          • ScheduledStart (string) --

            The scheduled start time, in ISO 8601 format, for the activity.

          • Start (string) --

            The actual start time, in ISO 8601 format, of the activity.

          • State (string) --

            The state of the activity. Possible values are: PENDING, INITIALIZING, RUNNING, PAUSED, CANCELLED, and COMPLETED.

          • SuccessfulEndpointCount (integer) --

            The total number of endpoints that the campaign successfully delivered messages to.

          • TimezonesCompletedCount (integer) --

            The total number of time zones that were completed.

          • TimezonesTotalCount (integer) --

            The total number of unique time zones that are in the segment for the campaign.

          • TotalEndpointCount (integer) --

            The total number of endpoints that the campaign attempted to deliver messages to.

          • TreatmentId (string) --

            The unique identifier for the campaign treatment that the activity applies to. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

      • NextToken (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.

get_campaign_date_range_kpi(**kwargs)

Retrieves (queries) pre-aggregated data for a standard metric that applies to a campaign.

See also: AWS API Documentation

Request Syntax

response = client.get_campaign_date_range_kpi(
    ApplicationId='string',
    CampaignId='string',
    EndTime=datetime(2015, 1, 1),
    KpiName='string',
    NextToken='string',
    PageSize='string',
    StartTime=datetime(2015, 1, 1)
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

  • EndTime (datetime) -- The last date to retrieve data for, as part of an inclusive date range that filters the query results. This value should be in ISO 8601 format, for example: 2019-07-19 for July 19, 2019. To define a date range that ends at a specific time, specify the date and time in ISO 8601 format, for example: 2019-07-19T20:00Z for 8:00 PM July 19, 2019.
  • KpiName (string) --

    [REQUIRED]

    The name of the metric, also referred to as a key performance indicator (KPI) , to retrieve data for. This value describes the associated metric and consists of two or more terms, which are comprised of lowercase alphanumeric characters, separated by a hyphen. Examples are attempted-deliveries and successful-deliveries. For a list of valid values, see the Amazon Pinpoint Developer Guide .

  • NextToken (string) -- The NextToken string that specifies which page of results to return in a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • StartTime (datetime) -- The first date to retrieve data for, as part of an inclusive date range that filters the query results. This value should be in ISO 8601 format, for example: 2019-07-15 for July 15, 2019. To define a date range that begins at a specific time, specify the date and time in ISO 8601 format, for example: 2019-07-15T16:00Z for 4:00 PM July 15, 2019.
Return type

dict

Returns

Response Syntax

{
    'CampaignDateRangeKpiResponse': {
        'ApplicationId': 'string',
        'CampaignId': 'string',
        'EndTime': datetime(2015, 1, 1),
        'KpiName': 'string',
        'KpiResult': {
            'Rows': [
                {
                    'GroupedBys': [
                        {
                            'Key': 'string',
                            'Type': 'string',
                            'Value': 'string'
                        },
                    ],
                    'Values': [
                        {
                            'Key': 'string',
                            'Type': 'string',
                            'Value': 'string'
                        },
                    ]
                },
            ]
        },
        'NextToken': 'string',
        'StartTime': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignDateRangeKpiResponse (dict) --

      Provides the results of a query that retrieved the data for a standard metric that applies to a campaign, and provides information about that query.

      • ApplicationId (string) --

        The unique identifier for the application that the metric applies to.

      • CampaignId (string) --

        The unique identifier for the campaign that the metric applies to.

      • EndTime (datetime) --

        The last date or date and time of the date range that was used to filter the query results, in ISO 8601 format. The date range is inclusive.

      • KpiName (string) --

        The name of the metric, also referred to as a key performance indicator (KPI) , that the data was retrieved for. This value describes the associated metric and consists of two or more terms, which are comprised of lowercase alphanumeric characters, separated by a hyphen. For a list of valid values, see the Amazon Pinpoint Developer Guide .

      • KpiResult (dict) --

        An array of objects that contains the results of the query. Each object contains the value for the metric and metadata about that value.

        • Rows (list) --

          An array of objects that provides the results of a query that retrieved the data for a standard metric that applies to an application or campaign.

          • (dict) --

            Provides the results of a query that retrieved the data for a standard metric that applies to an application or campaign.

            • GroupedBys (list) --

              An array of objects that defines the field and field values that were used to group data in a result set that contains multiple results. This value is null if the data in a result set isn’t grouped.

              • (dict) --

                Provides a single value and metadata about that value as part of an array of query results for a standard metric that applies to an application or campaign.

                • Key (string) --

                  The name of the field that Amazon Pinpoint uses to store the value specified by the Value property.

                • Type (string) --

                  The data type of the value specified by the Value property.

                • Value (string) --

                  In a Values object, the value for the metric that the query retrieved data for. In a GroupedBys object, the value for the field that was used to group data in a result set that contains multiple results (Values objects).

            • Values (list) --

              An array of objects that provides pre-aggregated values for a standard metric that applies to an application or campaign.

              • (dict) --

                Provides a single value and metadata about that value as part of an array of query results for a standard metric that applies to an application or campaign.

                • Key (string) --

                  The name of the field that Amazon Pinpoint uses to store the value specified by the Value property.

                • Type (string) --

                  The data type of the value specified by the Value property.

                • Value (string) --

                  In a Values object, the value for the metric that the query retrieved data for. In a GroupedBys object, the value for the field that was used to group data in a result set that contains multiple results (Values objects).

      • NextToken (string) --

        The string to use in a subsequent request to get the next page of results in a paginated response. This value is null for the Campaign Metrics resource. The Campaign Metrics resource returns all results in a single page.

      • StartTime (datetime) --

        The first date or date and time of the date range that was used to filter the query results, in ISO 8601 format. The date range is inclusive.

get_campaign_version(**kwargs)

Retrieves information about the status, configuration, and other settings for a specific version of a campaign.

See also: AWS API Documentation

Request Syntax

response = client.get_campaign_version(
    ApplicationId='string',
    CampaignId='string',
    Version='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

  • Version (string) --

    [REQUIRED]

    The unique version number (Version property) for the campaign version.

Return type

dict

Returns

Response Syntax

{
    'CampaignResponse': {
        'AdditionalTreatments': [
            {
                'Id': 'string',
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SizePercent': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string'
            },
        ],
        'ApplicationId': 'string',
        'Arn': 'string',
        'CreationDate': 'string',
        'DefaultState': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'Description': 'string',
        'HoldoutPercent': 123,
        'Hook': {
            'LambdaFunctionName': 'string',
            'Mode': 'DELIVERY'|'FILTER',
            'WebUrl': 'string'
        },
        'Id': 'string',
        'IsPaused': True|False,
        'LastModifiedDate': 'string',
        'Limits': {
            'Daily': 123,
            'MaximumDuration': 123,
            'MessagesPerSecond': 123,
            'Total': 123
        },
        'MessageConfiguration': {
            'ADMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'APNSMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'BaiduMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'DefaultMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'EmailMessage': {
                'Body': 'string',
                'FromAddress': 'string',
                'HtmlBody': 'string',
                'Title': 'string'
            },
            'GCMMessage': {
                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                'Body': 'string',
                'ImageIconUrl': 'string',
                'ImageSmallIconUrl': 'string',
                'ImageUrl': 'string',
                'JsonBody': 'string',
                'MediaUrl': 'string',
                'RawContent': 'string',
                'SilentPush': True|False,
                'TimeToLive': 123,
                'Title': 'string',
                'Url': 'string'
            },
            'SMSMessage': {
                'Body': 'string',
                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                'SenderId': 'string'
            }
        },
        'Name': 'string',
        'Schedule': {
            'EndTime': 'string',
            'EventFilter': {
                'Dimensions': {
                    'Attributes': {
                        'string': {
                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                            'Values': [
                                'string',
                            ]
                        }
                    },
                    'EventType': {
                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                        'Values': [
                            'string',
                        ]
                    },
                    'Metrics': {
                        'string': {
                            'ComparisonOperator': 'string',
                            'Value': 123.0
                        }
                    }
                },
                'FilterType': 'SYSTEM'|'ENDPOINT'
            },
            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
            'IsLocalTime': True|False,
            'QuietTime': {
                'End': 'string',
                'Start': 'string'
            },
            'StartTime': 'string',
            'Timezone': 'string'
        },
        'SegmentId': 'string',
        'SegmentVersion': 123,
        'State': {
            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
        },
        'tags': {
            'string': 'string'
        },
        'TreatmentDescription': 'string',
        'TreatmentName': 'string',
        'Version': 123
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignResponse (dict) --

      Provides information about the status, configuration, and other settings for a campaign.

      • AdditionalTreatments (list) --

        An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

        • (dict) --

          Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

          • Id (string) --

            The unique identifier for the treatment.

          • MessageConfiguration (dict) --

            The message configuration settings for the treatment.

            • ADMMessage (dict) --

              The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • APNSMessage (dict) --

              The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • BaiduMessage (dict) --

              The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • DefaultMessage (dict) --

              The default message that the campaign sends through all the channels that are configured for the campaign.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • EmailMessage (dict) --

              The message that the campaign sends through the email channel.

              • Body (string) --

                The body of the email for recipients whose email clients don't support HTML content.

              • FromAddress (string) --

                The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

              • HtmlBody (string) --

                The body of the email, in HTML format, for recipients whose email clients support HTML content.

              • Title (string) --

                The subject line, or title, of the email.

            • GCMMessage (dict) --

              The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • SMSMessage (dict) --

              The message that the campaign sends through the SMS channel.

              • Body (string) --

                The body of the SMS message.

              • MessageType (string) --

                The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

              • SenderId (string) --

                The sender ID to display on recipients' devices when they receive the SMS message.

          • Schedule (dict) --

            The schedule settings for the treatment.

            • EndTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to end.

            • EventFilter (dict) --

              The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

              • Dimensions (dict) --

                The dimension settings of the event filter for the campaign.

                • Attributes (dict) --

                  One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • EventType (dict) --

                  The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Metrics (dict) --

                  One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

              • FilterType (string) --

                The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

            • Frequency (string) --

              Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

            • IsLocalTime (boolean) --

              Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

            • QuietTime (dict) --

              The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

              • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
              • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
              • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

              If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

              • End (string) --

                The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

              • Start (string) --

                The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • StartTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to begin.

            • Timezone (string) --

              The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

          • SizePercent (integer) --

            The allocated percentage of users (segment members) that the treatment is sent to.

          • State (dict) --

            The status of the treatment.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • TreatmentDescription (string) --

            The custom description of the treatment.

          • TreatmentName (string) --

            The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

      • ApplicationId (string) --

        The unique identifier for the application that the campaign applies to.

      • Arn (string) --

        The Amazon Resource Name (ARN) of the campaign.

      • CreationDate (string) --

        The date, ISO 8601 format, when the campaign was created.

      • DefaultState (dict) --

        The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment, to support A/B testing.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • Description (string) --

        The custom description of the campaign.

      • HoldoutPercent (integer) --

        The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

      • Hook (dict) --

        The settings for the AWS Lambda function to use as a code hook for the campaign.

        • LambdaFunctionName (string) --

          The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

        • Mode (string) --

          Specifies which Lambda mode to use when invoking the AWS Lambda function.

        • WebUrl (string) --

          The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

      • Id (string) --

        The unique identifier for the campaign.

      • IsPaused (boolean) --

        Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false.

      • LastModifiedDate (string) --

        The date, in ISO 8601 format, when the campaign was last modified.

      • Limits (dict) --

        The messaging limits for the campaign.

        • Daily (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

        • MaximumDuration (integer) --

          The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

        • MessagesPerSecond (integer) --

          The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

        • Total (integer) --

          The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

      • MessageConfiguration (dict) --

        The message configuration settings for the campaign.

        • ADMMessage (dict) --

          The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • APNSMessage (dict) --

          The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • BaiduMessage (dict) --

          The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • DefaultMessage (dict) --

          The default message that the campaign sends through all the channels that are configured for the campaign.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • EmailMessage (dict) --

          The message that the campaign sends through the email channel.

          • Body (string) --

            The body of the email for recipients whose email clients don't support HTML content.

          • FromAddress (string) --

            The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

          • HtmlBody (string) --

            The body of the email, in HTML format, for recipients whose email clients support HTML content.

          • Title (string) --

            The subject line, or title, of the email.

        • GCMMessage (dict) --

          The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

          • Action (string) --

            The action to occur if a recipient taps the push notification. Valid values are:

            • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
            • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
            • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
          • Body (string) --

            The body of the notification message. The maximum number of characters is 200.

          • ImageIconUrl (string) --

            The URL of the image to display as the push-notification icon, such as the icon for the app.

          • ImageSmallIconUrl (string) --

            The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

          • ImageUrl (string) --

            The URL of an image to display in the push notification.

          • JsonBody (string) --

            The JSON payload to use for a silent push notification.

          • MediaUrl (string) --

            The URL of the image or video to display in the push notification.

          • RawContent (string) --

            The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

          • SilentPush (boolean) --

            Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

          • TimeToLive (integer) --

            The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

            This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

          • Title (string) --

            The title to display above the notification message on a recipient's device.

          • Url (string) --

            The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

        • SMSMessage (dict) --

          The message that the campaign sends through the SMS channel.

          • Body (string) --

            The body of the SMS message.

          • MessageType (string) --

            The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

          • SenderId (string) --

            The sender ID to display on recipients' devices when they receive the SMS message.

      • Name (string) --

        The name of the campaign.

      • Schedule (dict) --

        The schedule settings for the campaign.

        • EndTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to end.

        • EventFilter (dict) --

          The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

          • Dimensions (dict) --

            The dimension settings of the event filter for the campaign.

            • Attributes (dict) --

              One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies attribute-based criteria for including or excluding endpoints from a segment.

                  • AttributeType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                    • (string) --
            • EventType (dict) --

              The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

              • DimensionType (string) --

                The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

              • Values (list) --

                The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                • (string) --
            • Metrics (dict) --

              One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

              • (string) --

                • (dict) --

                  Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                  • ComparisonOperator (string) --

                    The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                  • Value (float) --

                    The value to compare.

          • FilterType (string) --

            The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

        • Frequency (string) --

          Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

        • IsLocalTime (boolean) --

          Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

        • QuietTime (dict) --

          The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

          • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
          • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
          • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

          If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

          • End (string) --

            The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

          • Start (string) --

            The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

        • StartTime (string) --

          The scheduled time, in ISO 8601 format, for the campaign to begin.

        • Timezone (string) --

          The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

      • SegmentId (string) --

        The unique identifier for the segment that's associated with the campaign.

      • SegmentVersion (integer) --

        The version number of the segment that's associated with the campaign.

      • State (dict) --

        The current status of the campaign.

        • CampaignStatus (string) --

          The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

      • tags (dict) --

        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.

        • (string) --
          • (string) --
      • TreatmentDescription (string) --

        The custom description of a variation of the campaign that's used for A/B testing.

      • TreatmentName (string) --

        The custom name of a variation of the campaign that's used for A/B testing.

      • Version (integer) --

        The version number of the campaign.

get_campaign_versions(**kwargs)

Retrieves information about the status, configuration, and other settings for all versions of a specific campaign.

See also: AWS API Documentation

Request Syntax

response = client.get_campaign_versions(
    ApplicationId='string',
    CampaignId='string',
    PageSize='string',
    Token='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • CampaignId (string) --

    [REQUIRED]

    The unique identifier for the campaign.

  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • Token (string) -- The NextToken string that specifies which page of results to return in a paginated response.
Return type

dict

Returns

Response Syntax

{
    'CampaignsResponse': {
        'Item': [
            {
                'AdditionalTreatments': [
                    {
                        'Id': 'string',
                        'MessageConfiguration': {
                            'ADMMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'APNSMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'BaiduMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'DefaultMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'EmailMessage': {
                                'Body': 'string',
                                'FromAddress': 'string',
                                'HtmlBody': 'string',
                                'Title': 'string'
                            },
                            'GCMMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'SMSMessage': {
                                'Body': 'string',
                                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                                'SenderId': 'string'
                            }
                        },
                        'Schedule': {
                            'EndTime': 'string',
                            'EventFilter': {
                                'Dimensions': {
                                    'Attributes': {
                                        'string': {
                                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                            'Values': [
                                                'string',
                                            ]
                                        }
                                    },
                                    'EventType': {
                                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                        'Values': [
                                            'string',
                                        ]
                                    },
                                    'Metrics': {
                                        'string': {
                                            'ComparisonOperator': 'string',
                                            'Value': 123.0
                                        }
                                    }
                                },
                                'FilterType': 'SYSTEM'|'ENDPOINT'
                            },
                            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                            'IsLocalTime': True|False,
                            'QuietTime': {
                                'End': 'string',
                                'Start': 'string'
                            },
                            'StartTime': 'string',
                            'Timezone': 'string'
                        },
                        'SizePercent': 123,
                        'State': {
                            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                        },
                        'TreatmentDescription': 'string',
                        'TreatmentName': 'string'
                    },
                ],
                'ApplicationId': 'string',
                'Arn': 'string',
                'CreationDate': 'string',
                'DefaultState': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'Description': 'string',
                'HoldoutPercent': 123,
                'Hook': {
                    'LambdaFunctionName': 'string',
                    'Mode': 'DELIVERY'|'FILTER',
                    'WebUrl': 'string'
                },
                'Id': 'string',
                'IsPaused': True|False,
                'LastModifiedDate': 'string',
                'Limits': {
                    'Daily': 123,
                    'MaximumDuration': 123,
                    'MessagesPerSecond': 123,
                    'Total': 123
                },
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Name': 'string',
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SegmentId': 'string',
                'SegmentVersion': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'tags': {
                    'string': 'string'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string',
                'Version': 123
            },
        ],
        'NextToken': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignsResponse (dict) --

      Provides information about the configuration and other settings for all the campaigns that are associated with an application.

      • Item (list) --

        An array of responses, one for each campaign that's associated with the application.

        • (dict) --

          Provides information about the status, configuration, and other settings for a campaign.

          • AdditionalTreatments (list) --

            An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

            • (dict) --

              Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

              • Id (string) --

                The unique identifier for the treatment.

              • MessageConfiguration (dict) --

                The message configuration settings for the treatment.

                • ADMMessage (dict) --

                  The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • APNSMessage (dict) --

                  The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • BaiduMessage (dict) --

                  The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • DefaultMessage (dict) --

                  The default message that the campaign sends through all the channels that are configured for the campaign.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • EmailMessage (dict) --

                  The message that the campaign sends through the email channel.

                  • Body (string) --

                    The body of the email for recipients whose email clients don't support HTML content.

                  • FromAddress (string) --

                    The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

                  • HtmlBody (string) --

                    The body of the email, in HTML format, for recipients whose email clients support HTML content.

                  • Title (string) --

                    The subject line, or title, of the email.

                • GCMMessage (dict) --

                  The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • SMSMessage (dict) --

                  The message that the campaign sends through the SMS channel.

                  • Body (string) --

                    The body of the SMS message.

                  • MessageType (string) --

                    The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

                  • SenderId (string) --

                    The sender ID to display on recipients' devices when they receive the SMS message.

              • Schedule (dict) --

                The schedule settings for the treatment.

                • EndTime (string) --

                  The scheduled time, in ISO 8601 format, for the campaign to end.

                • EventFilter (dict) --

                  The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

                  • Dimensions (dict) --

                    The dimension settings of the event filter for the campaign.

                    • Attributes (dict) --

                      One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                      • (string) --

                        • (dict) --

                          Specifies attribute-based criteria for including or excluding endpoints from a segment.

                          • AttributeType (string) --

                            The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                          • Values (list) --

                            The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                            • (string) --
                    • EventType (dict) --

                      The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                      • DimensionType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                        • (string) --
                    • Metrics (dict) --

                      One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                      • (string) --

                        • (dict) --

                          Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                          • ComparisonOperator (string) --

                            The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                          • Value (float) --

                            The value to compare.

                  • FilterType (string) --

                    The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

                • Frequency (string) --

                  Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

                • IsLocalTime (boolean) --

                  Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

                • QuietTime (dict) --

                  The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

                  • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
                  • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
                  • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

                  If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

                  • End (string) --

                    The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

                  • Start (string) --

                    The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

                • StartTime (string) --

                  The scheduled time, in ISO 8601 format, for the campaign to begin.

                • Timezone (string) --

                  The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

              • SizePercent (integer) --

                The allocated percentage of users (segment members) that the treatment is sent to.

              • State (dict) --

                The status of the treatment.

                • CampaignStatus (string) --

                  The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

              • TreatmentDescription (string) --

                The custom description of the treatment.

              • TreatmentName (string) --

                The custom name of the treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

          • ApplicationId (string) --

            The unique identifier for the application that the campaign applies to.

          • Arn (string) --

            The Amazon Resource Name (ARN) of the campaign.

          • CreationDate (string) --

            The date, ISO 8601 format, when the campaign was created.

          • DefaultState (dict) --

            The current status of the campaign's default treatment. This value exists only for campaigns that have more than one treatment, to support A/B testing.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • Description (string) --

            The custom description of the campaign.

          • HoldoutPercent (integer) --

            The allocated percentage of users (segment members) who shouldn't receive messages from the campaign.

          • Hook (dict) --

            The settings for the AWS Lambda function to use as a code hook for the campaign.

            • LambdaFunctionName (string) --

              The name or Amazon Resource Name (ARN) of the AWS Lambda function that Amazon Pinpoint invokes to send messages for a campaign.

            • Mode (string) --

              Specifies which Lambda mode to use when invoking the AWS Lambda function.

            • WebUrl (string) --

              The web URL that Amazon Pinpoint calls to invoke the AWS Lambda function over HTTPS.

          • Id (string) --

            The unique identifier for the campaign.

          • IsPaused (boolean) --

            Specifies whether the campaign is paused. A paused campaign doesn't run unless you resume it by changing this value to false.

          • LastModifiedDate (string) --

            The date, in ISO 8601 format, when the campaign was last modified.

          • Limits (dict) --

            The messaging limits for the campaign.

            • Daily (integer) --

              The maximum number of messages that a campaign can send to a single endpoint during a 24-hour period. The maximum value is 100.

            • MaximumDuration (integer) --

              The maximum amount of time, in seconds, that a campaign can attempt to deliver a message after the scheduled start time for the campaign. The minimum value is 60 seconds.

            • MessagesPerSecond (integer) --

              The maximum number of messages that a campaign can send each second. The minimum value is 50. The maximum value is 20,000.

            • Total (integer) --

              The maximum number of messages that a campaign can send to a single endpoint during the course of the campaign. The maximum value is 100.

          • MessageConfiguration (dict) --

            The message configuration settings for the campaign.

            • ADMMessage (dict) --

              The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • APNSMessage (dict) --

              The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • BaiduMessage (dict) --

              The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • DefaultMessage (dict) --

              The default message that the campaign sends through all the channels that are configured for the campaign.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • EmailMessage (dict) --

              The message that the campaign sends through the email channel.

              • Body (string) --

                The body of the email for recipients whose email clients don't support HTML content.

              • FromAddress (string) --

                The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

              • HtmlBody (string) --

                The body of the email, in HTML format, for recipients whose email clients support HTML content.

              • Title (string) --

                The subject line, or title, of the email.

            • GCMMessage (dict) --

              The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This message overrides the default message.

              • Action (string) --

                The action to occur if a recipient taps the push notification. Valid values are:

                • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
              • Body (string) --

                The body of the notification message. The maximum number of characters is 200.

              • ImageIconUrl (string) --

                The URL of the image to display as the push-notification icon, such as the icon for the app.

              • ImageSmallIconUrl (string) --

                The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

              • ImageUrl (string) --

                The URL of an image to display in the push notification.

              • JsonBody (string) --

                The JSON payload to use for a silent push notification.

              • MediaUrl (string) --

                The URL of the image or video to display in the push notification.

              • RawContent (string) --

                The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

              • SilentPush (boolean) --

                Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

              • TimeToLive (integer) --

                The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

              • Title (string) --

                The title to display above the notification message on a recipient's device.

              • Url (string) --

                The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

            • SMSMessage (dict) --

              The message that the campaign sends through the SMS channel.

              • Body (string) --

                The body of the SMS message.

              • MessageType (string) --

                The type of SMS message. Valid values are: TRANSACTIONAL, the message is critical or time-sensitive, such as a one-time password that supports a customer transaction; and, PROMOTIONAL, the message isn't critical or time-sensitive, such as a marketing message.

              • SenderId (string) --

                The sender ID to display on recipients' devices when they receive the SMS message.

          • Name (string) --

            The name of the campaign.

          • Schedule (dict) --

            The schedule settings for the campaign.

            • EndTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to end.

            • EventFilter (dict) --

              The type of event that causes the campaign to be sent, if the value of the Frequency property is EVENT.

              • Dimensions (dict) --

                The dimension settings of the event filter for the campaign.

                • Attributes (dict) --

                  One or more custom attributes that your app reports to Amazon Pinpoint. You can use these attributes as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies attribute-based criteria for including or excluding endpoints from a segment.

                      • AttributeType (string) --

                        The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                      • Values (list) --

                        The criteria values to use for the segment dimension. Depending on the value of the AttributeType property, endpoints are included or excluded from the segment if their attribute values match the criteria values.

                        • (string) --
                • EventType (dict) --

                  The name of the event that causes the campaign to be sent. This can be a standard type of event that Amazon Pinpoint generates, such as _session.start, or a custom event that's specific to your app.

                  • DimensionType (string) --

                    The type of segment dimension to use. Valid values are: INCLUSIVE, endpoints that match the criteria are included in the segment; and, EXCLUSIVE, endpoints that match the criteria are excluded from the segment.

                  • Values (list) --

                    The criteria values to use for the segment dimension. Depending on the value of the DimensionType property, endpoints are included or excluded from the segment if their values match the criteria values.

                    • (string) --
                • Metrics (dict) --

                  One or more custom metrics that your app reports to Amazon Pinpoint. You can use these metrics as selection criteria when you create an event filter.

                  • (string) --

                    • (dict) --

                      Specifies metric-based criteria for including or excluding endpoints from a segment. These criteria derive from custom metrics that you define for endpoints.

                      • ComparisonOperator (string) --

                        The operator to use when comparing metric values. Valid values are: GREATER_THAN, LESS_THAN, GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, and EQUAL.

                      • Value (float) --

                        The value to compare.

              • FilterType (string) --

                The type of event that causes the campaign to be sent. Valid values are: SYSTEM, sends the campaign when a system event occurs; and, ENDPOINT, sends the campaign when an endpoint event (Eventsresource) occurs.

            • Frequency (string) --

              Specifies how often the campaign is sent or whether the campaign is sent in response to a specific event.

            • IsLocalTime (boolean) --

              Specifies whether the start and end times for the campaign schedule use each recipient's local time. To base the schedule on each recipient's local time, set this value to true.

            • QuietTime (dict) --

              The default quiet time for the campaign. Quiet time is a specific time range when a campaign doesn't send messages to endpoints, if all the following conditions are met:

              • The EndpointDemographic.Timezone property of the endpoint is set to a valid value.
              • The current time in the endpoint's time zone is later than or equal to the time specified by the QuietTime.Start property for the campaign.
              • The current time in the endpoint's time zone is earlier than or equal to the time specified by the QuietTime.End property for the campaign.

              If any of the preceding conditions isn't met, the endpoint will receive messages from the campaign, even if quiet time is enabled.

              • End (string) --

                The specific time when quiet time ends. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

              • Start (string) --

                The specific time when quiet time begins. This value has to use 24-hour notation and be in HH:MM format, where HH is the hour (with a leading zero, if applicable) and MM is the minutes. For example, use 02:30 to represent 2:30 AM, or 14:30 to represent 2:30 PM.

            • StartTime (string) --

              The scheduled time, in ISO 8601 format, for the campaign to begin.

            • Timezone (string) --

              The starting UTC offset for the campaign schedule, if the value of the IsLocalTime property is true. Valid values are: UTC, UTC+01, UTC+02, UTC+03, UTC+03:30, UTC+04, UTC+04:30, UTC+05, UTC+05:30, UTC+05:45, UTC+06, UTC+06:30, UTC+07, UTC+08, UTC+09, UTC+09:30, UTC+10, UTC+10:30, UTC+11, UTC+12, UTC+13, UTC-02, UTC-03, UTC-04, UTC-05, UTC-06, UTC-07, UTC-08, UTC-09, UTC-10, and UTC-11.

          • SegmentId (string) --

            The unique identifier for the segment that's associated with the campaign.

          • SegmentVersion (integer) --

            The version number of the segment that's associated with the campaign.

          • State (dict) --

            The current status of the campaign.

            • CampaignStatus (string) --

              The status of the campaign, or the status of a treatment that belongs to an A/B test campaign. If a campaign uses A/B testing, the campaign has a status of COMPLETED only when all campaign treatments have a status of COMPLETED.

          • tags (dict) --

            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.

            • (string) --
              • (string) --
          • TreatmentDescription (string) --

            The custom description of a variation of the campaign that's used for A/B testing.

          • TreatmentName (string) --

            The custom name of a variation of the campaign that's used for A/B testing.

          • Version (integer) --

            The version number of the campaign.

      • NextToken (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.

get_campaigns(**kwargs)

Retrieves information about the status, configuration, and other settings for all the campaigns that are associated with an application.

See also: AWS API Documentation

Request Syntax

response = client.get_campaigns(
    ApplicationId='string',
    PageSize='string',
    Token='string'
)
Parameters
  • ApplicationId (string) --

    [REQUIRED]

    The unique identifier for the application. This identifier is displayed as the Project ID on the Amazon Pinpoint console.

  • PageSize (string) -- The maximum number of items to include in each page of a paginated response. This parameter is currently not supported by the App Metrics and Campaign Metrics resources.
  • Token (string) -- The NextToken string that specifies which page of results to return in a paginated response.
Return type

dict

Returns

Response Syntax

{
    'CampaignsResponse': {
        'Item': [
            {
                'AdditionalTreatments': [
                    {
                        'Id': 'string',
                        'MessageConfiguration': {
                            'ADMMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'APNSMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'BaiduMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'DefaultMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'EmailMessage': {
                                'Body': 'string',
                                'FromAddress': 'string',
                                'HtmlBody': 'string',
                                'Title': 'string'
                            },
                            'GCMMessage': {
                                'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                                'Body': 'string',
                                'ImageIconUrl': 'string',
                                'ImageSmallIconUrl': 'string',
                                'ImageUrl': 'string',
                                'JsonBody': 'string',
                                'MediaUrl': 'string',
                                'RawContent': 'string',
                                'SilentPush': True|False,
                                'TimeToLive': 123,
                                'Title': 'string',
                                'Url': 'string'
                            },
                            'SMSMessage': {
                                'Body': 'string',
                                'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                                'SenderId': 'string'
                            }
                        },
                        'Schedule': {
                            'EndTime': 'string',
                            'EventFilter': {
                                'Dimensions': {
                                    'Attributes': {
                                        'string': {
                                            'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                            'Values': [
                                                'string',
                                            ]
                                        }
                                    },
                                    'EventType': {
                                        'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                        'Values': [
                                            'string',
                                        ]
                                    },
                                    'Metrics': {
                                        'string': {
                                            'ComparisonOperator': 'string',
                                            'Value': 123.0
                                        }
                                    }
                                },
                                'FilterType': 'SYSTEM'|'ENDPOINT'
                            },
                            'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                            'IsLocalTime': True|False,
                            'QuietTime': {
                                'End': 'string',
                                'Start': 'string'
                            },
                            'StartTime': 'string',
                            'Timezone': 'string'
                        },
                        'SizePercent': 123,
                        'State': {
                            'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                        },
                        'TreatmentDescription': 'string',
                        'TreatmentName': 'string'
                    },
                ],
                'ApplicationId': 'string',
                'Arn': 'string',
                'CreationDate': 'string',
                'DefaultState': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'Description': 'string',
                'HoldoutPercent': 123,
                'Hook': {
                    'LambdaFunctionName': 'string',
                    'Mode': 'DELIVERY'|'FILTER',
                    'WebUrl': 'string'
                },
                'Id': 'string',
                'IsPaused': True|False,
                'LastModifiedDate': 'string',
                'Limits': {
                    'Daily': 123,
                    'MaximumDuration': 123,
                    'MessagesPerSecond': 123,
                    'Total': 123
                },
                'MessageConfiguration': {
                    'ADMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'APNSMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'BaiduMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'DefaultMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'EmailMessage': {
                        'Body': 'string',
                        'FromAddress': 'string',
                        'HtmlBody': 'string',
                        'Title': 'string'
                    },
                    'GCMMessage': {
                        'Action': 'OPEN_APP'|'DEEP_LINK'|'URL',
                        'Body': 'string',
                        'ImageIconUrl': 'string',
                        'ImageSmallIconUrl': 'string',
                        'ImageUrl': 'string',
                        'JsonBody': 'string',
                        'MediaUrl': 'string',
                        'RawContent': 'string',
                        'SilentPush': True|False,
                        'TimeToLive': 123,
                        'Title': 'string',
                        'Url': 'string'
                    },
                    'SMSMessage': {
                        'Body': 'string',
                        'MessageType': 'TRANSACTIONAL'|'PROMOTIONAL',
                        'SenderId': 'string'
                    }
                },
                'Name': 'string',
                'Schedule': {
                    'EndTime': 'string',
                    'EventFilter': {
                        'Dimensions': {
                            'Attributes': {
                                'string': {
                                    'AttributeType': 'INCLUSIVE'|'EXCLUSIVE',
                                    'Values': [
                                        'string',
                                    ]
                                }
                            },
                            'EventType': {
                                'DimensionType': 'INCLUSIVE'|'EXCLUSIVE',
                                'Values': [
                                    'string',
                                ]
                            },
                            'Metrics': {
                                'string': {
                                    'ComparisonOperator': 'string',
                                    'Value': 123.0
                                }
                            }
                        },
                        'FilterType': 'SYSTEM'|'ENDPOINT'
                    },
                    'Frequency': 'ONCE'|'HOURLY'|'DAILY'|'WEEKLY'|'MONTHLY'|'EVENT',
                    'IsLocalTime': True|False,
                    'QuietTime': {
                        'End': 'string',
                        'Start': 'string'
                    },
                    'StartTime': 'string',
                    'Timezone': 'string'
                },
                'SegmentId': 'string',
                'SegmentVersion': 123,
                'State': {
                    'CampaignStatus': 'SCHEDULED'|'EXECUTING'|'PENDING_NEXT_RUN'|'COMPLETED'|'PAUSED'|'DELETED'
                },
                'tags': {
                    'string': 'string'
                },
                'TreatmentDescription': 'string',
                'TreatmentName': 'string',
                'Version': 123
            },
        ],
        'NextToken': 'string'
    }
}

Response Structure

  • (dict) --

    The request succeeded.

    • CampaignsResponse (dict) --

      Provides information about the configuration and other settings for all the campaigns that are associated with an application.

      • Item (list) --

        An array of responses, one for each campaign that's associated with the application.

        • (dict) --

          Provides information about the status, configuration, and other settings for a campaign.

          • AdditionalTreatments (list) --

            An array of responses, one for each treatment that you defined for the campaign, in addition to the default treatment.

            • (dict) --

              Specifies the settings for a campaign treatment. A treatment is a variation of a campaign that's used for A/B testing of a campaign.

              • Id (string) --

                The unique identifier for the treatment.

              • MessageConfiguration (dict) --

                The message configuration settings for the treatment.

                • ADMMessage (dict) --

                  The message that the campaign sends through the ADM (Amazon Device Messaging) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • APNSMessage (dict) --

                  The message that the campaign sends through the APNs (Apple Push Notification service) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • BaiduMessage (dict) --

                  The message that the campaign sends through the Baidu (Baidu Cloud Push) channel. This message overrides the default message.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • DefaultMessage (dict) --

                  The default message that the campaign sends through all the channels that are configured for the campaign.

                  • Action (string) --

                    The action to occur if a recipient taps the push notification. Valid values are:

                    • OPEN_APP - Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.
                    • DEEP_LINK - Your app opens and displays a designated user interface in the app. This setting uses the deep-linking features of iOS and Android.
                    • URL - The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
                  • Body (string) --

                    The body of the notification message. The maximum number of characters is 200.

                  • ImageIconUrl (string) --

                    The URL of the image to display as the push-notification icon, such as the icon for the app.

                  • ImageSmallIconUrl (string) --

                    The URL of the image to display as the small, push-notification icon, such as a small version of the icon for the app.

                  • ImageUrl (string) --

                    The URL of an image to display in the push notification.

                  • JsonBody (string) --

                    The JSON payload to use for a silent push notification.

                  • MediaUrl (string) --

                    The URL of the image or video to display in the push notification.

                  • RawContent (string) --

                    The raw, JSON-formatted string to use as the payload for the notification message. This value overrides other values for the message.

                  • SilentPush (boolean) --

                    Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. Silent push notifications can be used for cases such as updating an app's configuration, displaying messages in an in-app message center, or supporting phone home functionality.

                  • TimeToLive (integer) --

                    The number of seconds that the push-notification service should keep the message, if the service is unable to deliver the notification the first time. This value is converted to an expiration value when it's sent to a push-notification service. If this value is 0, the service treats the notification as if it expires immediately and the service doesn't store or try to deliver the notification again.

                    This value doesn't apply to messages that are sent through the Amazon Device Messaging (ADM) service.

                  • Title (string) --

                    The title to display above the notification message on a recipient's device.

                  • Url (string) --

                    The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the Action property is URL.

                • EmailMessage (dict) --

                  The message that the campaign sends through the email channel.

                  • Body (string) --

                    The body of the email for recipients whose email clients don't support HTML content.

                  • FromAddress (string) --

                    The verified email address to send the email from. The default address is the FromAddress specified for the email channel for the application.

                  • HtmlBody (string) --

                    The body of the email, in HTML format, for recipients whose email clients support HTML content.

                  • Title (string) --

                    The subject line, or title, of the email.

                • GCMMessage (dict) --

                  The message that the campaign sends through the GCM channel, which enables Amazon Pinpoint to send push notifications through the Firebase Cloud Messaging (FCM), formerly Google Cloud Messaging (GCM), service. This mess