/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include Specifies the content and settings for a push notification that's sent to
* recipients of a campaign.See Also:
AWS
* API Reference
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.
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.
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.
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.
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.
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.
The body of the notification message. The maximum number of characters is * 200.
*/ inline const Aws::String& GetBody() const{ return m_body; } /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline bool BodyHasBeenSet() const { return m_bodyHasBeenSet; } /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline void SetBody(const Aws::String& value) { m_bodyHasBeenSet = true; m_body = value; } /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline void SetBody(Aws::String&& value) { m_bodyHasBeenSet = true; m_body = std::move(value); } /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline void SetBody(const char* value) { m_bodyHasBeenSet = true; m_body.assign(value); } /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline Message& WithBody(const Aws::String& value) { SetBody(value); return *this;} /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline Message& WithBody(Aws::String&& value) { SetBody(std::move(value)); return *this;} /** *The body of the notification message. The maximum number of characters is * 200.
*/ inline Message& WithBody(const char* value) { SetBody(value); return *this;} /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline const Aws::String& GetImageIconUrl() const{ return m_imageIconUrl; } /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline bool ImageIconUrlHasBeenSet() const { return m_imageIconUrlHasBeenSet; } /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline void SetImageIconUrl(const Aws::String& value) { m_imageIconUrlHasBeenSet = true; m_imageIconUrl = value; } /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline void SetImageIconUrl(Aws::String&& value) { m_imageIconUrlHasBeenSet = true; m_imageIconUrl = std::move(value); } /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline void SetImageIconUrl(const char* value) { m_imageIconUrlHasBeenSet = true; m_imageIconUrl.assign(value); } /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline Message& WithImageIconUrl(const Aws::String& value) { SetImageIconUrl(value); return *this;} /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline Message& WithImageIconUrl(Aws::String&& value) { SetImageIconUrl(std::move(value)); return *this;} /** *The URL of the image to display as the push-notification icon, such as the * icon for the app.
*/ inline Message& WithImageIconUrl(const char* value) { SetImageIconUrl(value); return *this;} /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline const Aws::String& GetImageSmallIconUrl() const{ return m_imageSmallIconUrl; } /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline bool ImageSmallIconUrlHasBeenSet() const { return m_imageSmallIconUrlHasBeenSet; } /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline void SetImageSmallIconUrl(const Aws::String& value) { m_imageSmallIconUrlHasBeenSet = true; m_imageSmallIconUrl = value; } /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline void SetImageSmallIconUrl(Aws::String&& value) { m_imageSmallIconUrlHasBeenSet = true; m_imageSmallIconUrl = std::move(value); } /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline void SetImageSmallIconUrl(const char* value) { m_imageSmallIconUrlHasBeenSet = true; m_imageSmallIconUrl.assign(value); } /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline Message& WithImageSmallIconUrl(const Aws::String& value) { SetImageSmallIconUrl(value); return *this;} /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline Message& WithImageSmallIconUrl(Aws::String&& value) { SetImageSmallIconUrl(std::move(value)); return *this;} /** *The URL of the image to display as the small, push-notification icon, such as * a small version of the icon for the app.
*/ inline Message& WithImageSmallIconUrl(const char* value) { SetImageSmallIconUrl(value); return *this;} /** *The URL of an image to display in the push notification.
*/ inline const Aws::String& GetImageUrl() const{ return m_imageUrl; } /** *The URL of an image to display in the push notification.
*/ inline bool ImageUrlHasBeenSet() const { return m_imageUrlHasBeenSet; } /** *The URL of an image to display in the push notification.
*/ inline void SetImageUrl(const Aws::String& value) { m_imageUrlHasBeenSet = true; m_imageUrl = value; } /** *The URL of an image to display in the push notification.
*/ inline void SetImageUrl(Aws::String&& value) { m_imageUrlHasBeenSet = true; m_imageUrl = std::move(value); } /** *The URL of an image to display in the push notification.
*/ inline void SetImageUrl(const char* value) { m_imageUrlHasBeenSet = true; m_imageUrl.assign(value); } /** *The URL of an image to display in the push notification.
*/ inline Message& WithImageUrl(const Aws::String& value) { SetImageUrl(value); return *this;} /** *The URL of an image to display in the push notification.
*/ inline Message& WithImageUrl(Aws::String&& value) { SetImageUrl(std::move(value)); return *this;} /** *The URL of an image to display in the push notification.
*/ inline Message& WithImageUrl(const char* value) { SetImageUrl(value); return *this;} /** *The JSON payload to use for a silent push notification.
*/ inline const Aws::String& GetJsonBody() const{ return m_jsonBody; } /** *The JSON payload to use for a silent push notification.
*/ inline bool JsonBodyHasBeenSet() const { return m_jsonBodyHasBeenSet; } /** *The JSON payload to use for a silent push notification.
*/ inline void SetJsonBody(const Aws::String& value) { m_jsonBodyHasBeenSet = true; m_jsonBody = value; } /** *The JSON payload to use for a silent push notification.
*/ inline void SetJsonBody(Aws::String&& value) { m_jsonBodyHasBeenSet = true; m_jsonBody = std::move(value); } /** *The JSON payload to use for a silent push notification.
*/ inline void SetJsonBody(const char* value) { m_jsonBodyHasBeenSet = true; m_jsonBody.assign(value); } /** *The JSON payload to use for a silent push notification.
*/ inline Message& WithJsonBody(const Aws::String& value) { SetJsonBody(value); return *this;} /** *The JSON payload to use for a silent push notification.
*/ inline Message& WithJsonBody(Aws::String&& value) { SetJsonBody(std::move(value)); return *this;} /** *The JSON payload to use for a silent push notification.
*/ inline Message& WithJsonBody(const char* value) { SetJsonBody(value); return *this;} /** *The URL of the image or video to display in the push notification.
*/ inline const Aws::String& GetMediaUrl() const{ return m_mediaUrl; } /** *The URL of the image or video to display in the push notification.
*/ inline bool MediaUrlHasBeenSet() const { return m_mediaUrlHasBeenSet; } /** *The URL of the image or video to display in the push notification.
*/ inline void SetMediaUrl(const Aws::String& value) { m_mediaUrlHasBeenSet = true; m_mediaUrl = value; } /** *The URL of the image or video to display in the push notification.
*/ inline void SetMediaUrl(Aws::String&& value) { m_mediaUrlHasBeenSet = true; m_mediaUrl = std::move(value); } /** *The URL of the image or video to display in the push notification.
*/ inline void SetMediaUrl(const char* value) { m_mediaUrlHasBeenSet = true; m_mediaUrl.assign(value); } /** *The URL of the image or video to display in the push notification.
*/ inline Message& WithMediaUrl(const Aws::String& value) { SetMediaUrl(value); return *this;} /** *The URL of the image or video to display in the push notification.
*/ inline Message& WithMediaUrl(Aws::String&& value) { SetMediaUrl(std::move(value)); return *this;} /** *The URL of the image or video to display in the push notification.
*/ inline Message& WithMediaUrl(const char* value) { SetMediaUrl(value); return *this;} /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline const Aws::String& GetRawContent() const{ return m_rawContent; } /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline bool RawContentHasBeenSet() const { return m_rawContentHasBeenSet; } /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline void SetRawContent(const Aws::String& value) { m_rawContentHasBeenSet = true; m_rawContent = value; } /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline void SetRawContent(Aws::String&& value) { m_rawContentHasBeenSet = true; m_rawContent = std::move(value); } /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline void SetRawContent(const char* value) { m_rawContentHasBeenSet = true; m_rawContent.assign(value); } /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline Message& WithRawContent(const Aws::String& value) { SetRawContent(value); return *this;} /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline Message& WithRawContent(Aws::String&& value) { SetRawContent(std::move(value)); return *this;} /** *The raw, JSON-formatted string to use as the payload for the notification * message. If specified, this value overrides all other content for the * message.
*/ inline Message& WithRawContent(const char* value) { SetRawContent(value); return *this;} /** *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.
*/ inline bool GetSilentPush() const{ return m_silentPush; } /** *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.
*/ inline bool SilentPushHasBeenSet() const { return m_silentPushHasBeenSet; } /** *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.
*/ inline void SetSilentPush(bool value) { m_silentPushHasBeenSet = true; m_silentPush = value; } /** *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.
*/ inline Message& WithSilentPush(bool value) { SetSilentPush(value); return *this;} /** *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.
*/ inline int GetTimeToLive() const{ return m_timeToLive; } /** *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.
*/ inline bool TimeToLiveHasBeenSet() const { return m_timeToLiveHasBeenSet; } /** *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.
*/ inline void SetTimeToLive(int value) { m_timeToLiveHasBeenSet = true; m_timeToLive = value; } /** *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.
*/ inline Message& WithTimeToLive(int value) { SetTimeToLive(value); return *this;} /** *The title to display above the notification message on a recipient's * device.
*/ inline const Aws::String& GetTitle() const{ return m_title; } /** *The title to display above the notification message on a recipient's * device.
*/ inline bool TitleHasBeenSet() const { return m_titleHasBeenSet; } /** *The title to display above the notification message on a recipient's * device.
*/ inline void SetTitle(const Aws::String& value) { m_titleHasBeenSet = true; m_title = value; } /** *The title to display above the notification message on a recipient's * device.
*/ inline void SetTitle(Aws::String&& value) { m_titleHasBeenSet = true; m_title = std::move(value); } /** *The title to display above the notification message on a recipient's * device.
*/ inline void SetTitle(const char* value) { m_titleHasBeenSet = true; m_title.assign(value); } /** *The title to display above the notification message on a recipient's * device.
*/ inline Message& WithTitle(const Aws::String& value) { SetTitle(value); return *this;} /** *The title to display above the notification message on a recipient's * device.
*/ inline Message& WithTitle(Aws::String&& value) { SetTitle(std::move(value)); return *this;} /** *The title to display above the notification message on a recipient's * device.
*/ inline Message& WithTitle(const char* value) { SetTitle(value); return *this;} /** *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.
*/ inline const Aws::String& GetUrl() const{ return m_url; } /** *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.
*/ inline bool UrlHasBeenSet() const { return m_urlHasBeenSet; } /** *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.
*/ inline void SetUrl(const Aws::String& value) { m_urlHasBeenSet = true; m_url = value; } /** *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.
*/ inline void SetUrl(Aws::String&& value) { m_urlHasBeenSet = true; m_url = std::move(value); } /** *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.
*/ inline void SetUrl(const char* value) { m_urlHasBeenSet = true; m_url.assign(value); } /** *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.
*/ inline Message& WithUrl(const Aws::String& value) { SetUrl(value); return *this;} /** *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.
*/ inline Message& WithUrl(Aws::String&& value) { SetUrl(std::move(value)); return *this;} /** *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.
*/ inline Message& WithUrl(const char* value) { SetUrl(value); return *this;} private: Action m_action; bool m_actionHasBeenSet = false; Aws::String m_body; bool m_bodyHasBeenSet = false; Aws::String m_imageIconUrl; bool m_imageIconUrlHasBeenSet = false; Aws::String m_imageSmallIconUrl; bool m_imageSmallIconUrlHasBeenSet = false; Aws::String m_imageUrl; bool m_imageUrlHasBeenSet = false; Aws::String m_jsonBody; bool m_jsonBodyHasBeenSet = false; Aws::String m_mediaUrl; bool m_mediaUrlHasBeenSet = false; Aws::String m_rawContent; bool m_rawContentHasBeenSet = false; bool m_silentPush; bool m_silentPushHasBeenSet = false; int m_timeToLive; bool m_timeToLiveHasBeenSet = false; Aws::String m_title; bool m_titleHasBeenSet = false; Aws::String m_url; bool m_urlHasBeenSet = false; }; } // namespace Model } // namespace Pinpoint } // namespace Aws