Class: Aws::Pinpoint::Types::WriteCampaignRequest

Inherits:
Struct
  • Object
show all
Includes:
Structure
Defined in:
lib/aws-sdk-pinpoint/types.rb

Overview

Note:

When making an API call, you may pass WriteCampaignRequest data as a hash:

{
  additional_treatments: [
    {
      message_configuration: {
        adm_message: {
          action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
          body: "__string",
          image_icon_url: "__string",
          image_small_icon_url: "__string",
          image_url: "__string",
          json_body: "__string",
          media_url: "__string",
          raw_content: "__string",
          silent_push: false,
          title: "__string",
          url: "__string",
        },
        apns_message: {
          action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
          body: "__string",
          image_icon_url: "__string",
          image_small_icon_url: "__string",
          image_url: "__string",
          json_body: "__string",
          media_url: "__string",
          raw_content: "__string",
          silent_push: false,
          title: "__string",
          url: "__string",
        },
        baidu_message: {
          action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
          body: "__string",
          image_icon_url: "__string",
          image_small_icon_url: "__string",
          image_url: "__string",
          json_body: "__string",
          media_url: "__string",
          raw_content: "__string",
          silent_push: false,
          title: "__string",
          url: "__string",
        },
        default_message: {
          action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
          body: "__string",
          image_icon_url: "__string",
          image_small_icon_url: "__string",
          image_url: "__string",
          json_body: "__string",
          media_url: "__string",
          raw_content: "__string",
          silent_push: false,
          title: "__string",
          url: "__string",
        },
        email_message: {
          body: "__string",
          from_address: "__string",
          html_body: "__string",
          title: "__string",
        },
        gcm_message: {
          action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
          body: "__string",
          image_icon_url: "__string",
          image_small_icon_url: "__string",
          image_url: "__string",
          json_body: "__string",
          media_url: "__string",
          raw_content: "__string",
          silent_push: false,
          title: "__string",
          url: "__string",
        },
        sms_message: {
          body: "__string",
          message_type: "TRANSACTIONAL", # accepts TRANSACTIONAL, PROMOTIONAL
          sender_id: "__string",
        },
      },
      schedule: {
        end_time: "__string",
        frequency: "ONCE", # accepts ONCE, HOURLY, DAILY, WEEKLY, MONTHLY
        is_local_time: false,
        quiet_time: {
          end: "__string",
          start: "__string",
        },
        start_time: "__string",
        timezone: "__string",
      },
      size_percent: 1,
      treatment_description: "__string",
      treatment_name: "__string",
    },
  ],
  description: "__string",
  holdout_percent: 1,
  hook: {
    lambda_function_name: "__string",
    mode: "DELIVERY", # accepts DELIVERY, FILTER
    web_url: "__string",
  },
  is_paused: false,
  limits: {
    daily: 1,
    maximum_duration: 1,
    messages_per_second: 1,
    total: 1,
  },
  message_configuration: {
    adm_message: {
      action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
      body: "__string",
      image_icon_url: "__string",
      image_small_icon_url: "__string",
      image_url: "__string",
      json_body: "__string",
      media_url: "__string",
      raw_content: "__string",
      silent_push: false,
      title: "__string",
      url: "__string",
    },
    apns_message: {
      action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
      body: "__string",
      image_icon_url: "__string",
      image_small_icon_url: "__string",
      image_url: "__string",
      json_body: "__string",
      media_url: "__string",
      raw_content: "__string",
      silent_push: false,
      title: "__string",
      url: "__string",
    },
    baidu_message: {
      action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
      body: "__string",
      image_icon_url: "__string",
      image_small_icon_url: "__string",
      image_url: "__string",
      json_body: "__string",
      media_url: "__string",
      raw_content: "__string",
      silent_push: false,
      title: "__string",
      url: "__string",
    },
    default_message: {
      action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
      body: "__string",
      image_icon_url: "__string",
      image_small_icon_url: "__string",
      image_url: "__string",
      json_body: "__string",
      media_url: "__string",
      raw_content: "__string",
      silent_push: false,
      title: "__string",
      url: "__string",
    },
    email_message: {
      body: "__string",
      from_address: "__string",
      html_body: "__string",
      title: "__string",
    },
    gcm_message: {
      action: "OPEN_APP", # accepts OPEN_APP, DEEP_LINK, URL
      body: "__string",
      image_icon_url: "__string",
      image_small_icon_url: "__string",
      image_url: "__string",
      json_body: "__string",
      media_url: "__string",
      raw_content: "__string",
      silent_push: false,
      title: "__string",
      url: "__string",
    },
    sms_message: {
      body: "__string",
      message_type: "TRANSACTIONAL", # accepts TRANSACTIONAL, PROMOTIONAL
      sender_id: "__string",
    },
  },
  name: "__string",
  schedule: {
    end_time: "__string",
    frequency: "ONCE", # accepts ONCE, HOURLY, DAILY, WEEKLY, MONTHLY
    is_local_time: false,
    quiet_time: {
      end: "__string",
      start: "__string",
    },
    start_time: "__string",
    timezone: "__string",
  },
  segment_id: "__string",
  segment_version: 1,
  treatment_description: "__string",
  treatment_name: "__string",
}

Used to create a campaign.

Instance Attribute Summary collapse

Instance Attribute Details

#additional_treatmentsArray<Types::WriteTreatmentResource>

Treatments that are defined in addition to the default treatment.

Returns:



8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#descriptionString

A description of the campaign.

Returns:

  • (String)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#holdout_percentInteger

The allocated percentage of end users who will not receive messages from this campaign.

Returns:

  • (Integer)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#hookTypes::CampaignHook

Campaign hook information.

Returns:



8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#is_pausedBoolean

Indicates whether the campaign is paused. A paused campaign does not send messages unless you resume it by setting IsPaused to false.

Returns:

  • (Boolean)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#limitsTypes::CampaignLimits

The campaign limits settings.



8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#message_configurationTypes::MessageConfiguration

The message configuration settings.



8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#nameString

The custom name of the campaign.

Returns:

  • (String)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#scheduleTypes::Schedule

The campaign schedule.

Returns:



8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#segment_idString

The ID of the segment to which the campaign sends messages.

Returns:

  • (String)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#segment_versionInteger

The version of the segment to which the campaign sends messages.

Returns:

  • (Integer)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#treatment_descriptionString

A custom description for the treatment.

Returns:

  • (String)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end

#treatment_nameString

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

Returns:

  • (String)


8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
# File 'lib/aws-sdk-pinpoint/types.rb', line 8150

class WriteCampaignRequest < Struct.new(
  :additional_treatments,
  :description,
  :holdout_percent,
  :hook,
  :is_paused,
  :limits,
  :message_configuration,
  :name,
  :schedule,
  :segment_id,
  :segment_version,
  :treatment_description,
  :treatment_name)
  include Aws::Structure
end