Class CfnCampaign.MessageProperty
Specifies the content and settings for a push notification that's sent to recipients of a campaign.
Implements
Inherited Members
Namespace: Amazon.CDK.AWS.Pinpoint
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnCampaign.MessageProperty : CfnCampaign.IMessageProperty
Syntax (vb)
Public Class CfnCampaign.MessageProperty Implements CfnCampaign.IMessageProperty
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Pinpoint;
var messageProperty = new MessageProperty {
Action = "action",
Body = "body",
ImageIconUrl = "imageIconUrl",
ImageSmallIconUrl = "imageSmallIconUrl",
ImageUrl = "imageUrl",
JsonBody = "jsonBody",
MediaUrl = "mediaUrl",
RawContent = "rawContent",
SilentPush = false,
TimeToLive = 123,
Title = "title",
Url = "url"
};
Synopsis
Constructors
| MessageProperty() | Specifies the content and settings for a push notification that's sent to recipients of a campaign. |
Properties
| Action | The action to occur if a recipient taps the push notification. Valid values are:. |
| Body | The body of the notification message. |
| ImageIconUrl | The URL of the image to display as the push notification icon, such as the icon for the app. |
| 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. |
| ImageUrl | The URL of an image to display in the push notification. |
| JsonBody | The JSON payload to use for a silent push notification. |
| MediaUrl | The URL of the image or video to display in the push notification. |
| RawContent | The raw, JSON-formatted string to use as the payload for the notification message. |
| SilentPush | Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device. |
| 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. |
| Title | The title to display above the notification message on a recipient's device. |
| Url | The URL to open in a recipient's default mobile browser, if a recipient taps the push notification and the value of the |
Constructors
MessageProperty()
Specifies the content and settings for a push notification that's sent to recipients of a campaign.
public MessageProperty()
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Pinpoint;
var messageProperty = new MessageProperty {
Action = "action",
Body = "body",
ImageIconUrl = "imageIconUrl",
ImageSmallIconUrl = "imageSmallIconUrl",
ImageUrl = "imageUrl",
JsonBody = "jsonBody",
MediaUrl = "mediaUrl",
RawContent = "rawContent",
SilentPush = false,
TimeToLive = 123,
Title = "title",
Url = "url"
};
Properties
Action
The action to occur if a recipient taps the push notification. Valid values are:.
public string? Action { get; set; }
Property Value
Remarks
Body
The body of the notification message.
public string? Body { get; set; }
Property Value
Remarks
The maximum number of characters is 200.
ImageIconUrl
The URL of the image to display as the push notification icon, such as the icon for the app.
public string? ImageIconUrl { get; set; }
Property Value
Remarks
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.
public string? ImageSmallIconUrl { get; set; }
Property Value
Remarks
ImageUrl
The URL of an image to display in the push notification.
public string? ImageUrl { get; set; }
Property Value
Remarks
JsonBody
The JSON payload to use for a silent push notification.
public string? JsonBody { get; set; }
Property Value
Remarks
MediaUrl
The URL of the image or video to display in the push notification.
public string? MediaUrl { get; set; }
Property Value
Remarks
RawContent
The raw, JSON-formatted string to use as the payload for the notification message.
public string? RawContent { get; set; }
Property Value
Remarks
If specified, this value overrides all other content for the message.
SilentPush
Specifies whether the notification is a silent push notification, which is a push notification that doesn't display on a recipient's device.
public object? SilentPush { get; set; }
Property Value
Remarks
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.
Type union: either bool or IResolvable
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.
public double? TimeToLive { get; set; }
Property Value
Remarks
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
The title to display above the notification message on a recipient's device.
public string? Title { get; set; }
Property Value
Remarks
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 .
public string? Url { get; set; }