/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include namespace Aws { namespace CloudWatchEvidently { namespace Model { /** */ class CreateExperimentRequest : public CloudWatchEvidentlyRequest { public: AWS_CLOUDWATCHEVIDENTLY_API CreateExperimentRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "CreateExperiment"; } AWS_CLOUDWATCHEVIDENTLY_API Aws::String SerializePayload() const override; /** *

An optional description of the experiment.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

An optional description of the experiment.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

An optional description of the experiment.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

An optional description of the experiment.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

An optional description of the experiment.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

An optional description of the experiment.

*/ inline CreateExperimentRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

An optional description of the experiment.

*/ inline CreateExperimentRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

An optional description of the experiment.

*/ inline CreateExperimentRequest& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline const Aws::Vector& GetMetricGoals() const{ return m_metricGoals; } /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline bool MetricGoalsHasBeenSet() const { return m_metricGoalsHasBeenSet; } /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline void SetMetricGoals(const Aws::Vector& value) { m_metricGoalsHasBeenSet = true; m_metricGoals = value; } /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline void SetMetricGoals(Aws::Vector&& value) { m_metricGoalsHasBeenSet = true; m_metricGoals = std::move(value); } /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline CreateExperimentRequest& WithMetricGoals(const Aws::Vector& value) { SetMetricGoals(value); return *this;} /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline CreateExperimentRequest& WithMetricGoals(Aws::Vector&& value) { SetMetricGoals(std::move(value)); return *this;} /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline CreateExperimentRequest& AddMetricGoals(const MetricGoalConfig& value) { m_metricGoalsHasBeenSet = true; m_metricGoals.push_back(value); return *this; } /** *

An array of structures that defines the metrics used for the experiment, and * whether a higher or lower value for each metric is the goal.

*/ inline CreateExperimentRequest& AddMetricGoals(MetricGoalConfig&& value) { m_metricGoalsHasBeenSet = true; m_metricGoals.push_back(std::move(value)); return *this; } /** *

A name for the new experiment.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

A name for the new experiment.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

A name for the new experiment.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

A name for the new experiment.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

A name for the new experiment.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

A name for the new experiment.

*/ inline CreateExperimentRequest& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

A name for the new experiment.

*/ inline CreateExperimentRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

A name for the new experiment.

*/ inline CreateExperimentRequest& WithName(const char* value) { SetName(value); return *this;} /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline const OnlineAbConfig& GetOnlineAbConfig() const{ return m_onlineAbConfig; } /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline bool OnlineAbConfigHasBeenSet() const { return m_onlineAbConfigHasBeenSet; } /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline void SetOnlineAbConfig(const OnlineAbConfig& value) { m_onlineAbConfigHasBeenSet = true; m_onlineAbConfig = value; } /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline void SetOnlineAbConfig(OnlineAbConfig&& value) { m_onlineAbConfigHasBeenSet = true; m_onlineAbConfig = std::move(value); } /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline CreateExperimentRequest& WithOnlineAbConfig(const OnlineAbConfig& value) { SetOnlineAbConfig(value); return *this;} /** *

A structure that contains the configuration of which variation to use as the * "control" version. tThe "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

*/ inline CreateExperimentRequest& WithOnlineAbConfig(OnlineAbConfig&& value) { SetOnlineAbConfig(std::move(value)); return *this;} /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline const Aws::String& GetProject() const{ return m_project; } /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline bool ProjectHasBeenSet() const { return m_projectHasBeenSet; } /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline void SetProject(const Aws::String& value) { m_projectHasBeenSet = true; m_project = value; } /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline void SetProject(Aws::String&& value) { m_projectHasBeenSet = true; m_project = std::move(value); } /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline void SetProject(const char* value) { m_projectHasBeenSet = true; m_project.assign(value); } /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline CreateExperimentRequest& WithProject(const Aws::String& value) { SetProject(value); return *this;} /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline CreateExperimentRequest& WithProject(Aws::String&& value) { SetProject(std::move(value)); return *this;} /** *

The name or ARN of the project that you want to create the new experiment * in.

*/ inline CreateExperimentRequest& WithProject(const char* value) { SetProject(value); return *this;} /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline const Aws::String& GetRandomizationSalt() const{ return m_randomizationSalt; } /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline bool RandomizationSaltHasBeenSet() const { return m_randomizationSaltHasBeenSet; } /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline void SetRandomizationSalt(const Aws::String& value) { m_randomizationSaltHasBeenSet = true; m_randomizationSalt = value; } /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline void SetRandomizationSalt(Aws::String&& value) { m_randomizationSaltHasBeenSet = true; m_randomizationSalt = std::move(value); } /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline void SetRandomizationSalt(const char* value) { m_randomizationSaltHasBeenSet = true; m_randomizationSalt.assign(value); } /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline CreateExperimentRequest& WithRandomizationSalt(const Aws::String& value) { SetRandomizationSalt(value); return *this;} /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline CreateExperimentRequest& WithRandomizationSalt(Aws::String&& value) { SetRandomizationSalt(std::move(value)); return *this;} /** *

When Evidently assigns a particular user session to an experiment, it must * use a randomization ID to determine which variation the user session is served. * This randomization ID is a combination of the entity ID and * randomizationSalt. If you omit randomizationSalt, * Evidently uses the experiment name as the randomizationSalt.

*/ inline CreateExperimentRequest& WithRandomizationSalt(const char* value) { SetRandomizationSalt(value); return *this;} /** *

The portion of the available audience that you want to allocate to this * experiment, in thousandths of a percent. The available audience is the total * audience minus the audience that you have allocated to overrides or current * launches of this feature.

This is represented in thousandths of a * percent. For example, specify 10,000 to allocate 10% of the available * audience.

*/ inline long long GetSamplingRate() const{ return m_samplingRate; } /** *

The portion of the available audience that you want to allocate to this * experiment, in thousandths of a percent. The available audience is the total * audience minus the audience that you have allocated to overrides or current * launches of this feature.

This is represented in thousandths of a * percent. For example, specify 10,000 to allocate 10% of the available * audience.

*/ inline bool SamplingRateHasBeenSet() const { return m_samplingRateHasBeenSet; } /** *

The portion of the available audience that you want to allocate to this * experiment, in thousandths of a percent. The available audience is the total * audience minus the audience that you have allocated to overrides or current * launches of this feature.

This is represented in thousandths of a * percent. For example, specify 10,000 to allocate 10% of the available * audience.

*/ inline void SetSamplingRate(long long value) { m_samplingRateHasBeenSet = true; m_samplingRate = value; } /** *

The portion of the available audience that you want to allocate to this * experiment, in thousandths of a percent. The available audience is the total * audience minus the audience that you have allocated to overrides or current * launches of this feature.

This is represented in thousandths of a * percent. For example, specify 10,000 to allocate 10% of the available * audience.

*/ inline CreateExperimentRequest& WithSamplingRate(long long value) { SetSamplingRate(value); return *this;} /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline const Aws::String& GetSegment() const{ return m_segment; } /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline bool SegmentHasBeenSet() const { return m_segmentHasBeenSet; } /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline void SetSegment(const Aws::String& value) { m_segmentHasBeenSet = true; m_segment = value; } /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline void SetSegment(Aws::String&& value) { m_segmentHasBeenSet = true; m_segment = std::move(value); } /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline void SetSegment(const char* value) { m_segmentHasBeenSet = true; m_segment.assign(value); } /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline CreateExperimentRequest& WithSegment(const Aws::String& value) { SetSegment(value); return *this;} /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline CreateExperimentRequest& WithSegment(Aws::String&& value) { SetSegment(std::move(value)); return *this;} /** *

Specifies an audience segment to use in the experiment. When a segment * is used in an experiment, only user sessions that match the segment pattern are * used in the experiment.

*/ inline CreateExperimentRequest& WithSegment(const char* value) { SetSegment(value); return *this;} /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline const Aws::Map& GetTags() const{ return m_tags; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline void SetTags(const Aws::Map& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline void SetTags(Aws::Map&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& WithTags(const Aws::Map& value) { SetTags(value); return *this;} /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& WithTags(Aws::Map&& value) { SetTags(std::move(value)); return *this;} /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(const Aws::String& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(Aws::String&& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(const Aws::String& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(Aws::String&& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), std::move(value)); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(const char* key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(Aws::String&& key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

Assigns one or more tags (key-value pairs) to the experiment.

Tags can * help you organize and categorize your resources. You can also use them to scope * user permissions by granting a user permission to access or change only * resources with certain tag values.

Tags don't have any semantic meaning * to Amazon Web Services and are interpreted strictly as strings of * characters.

You can associate as many as 50 tags with an experiment.

*

For more information, see Tagging * Amazon Web Services resources.

*/ inline CreateExperimentRequest& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline const Aws::Vector& GetTreatments() const{ return m_treatments; } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline bool TreatmentsHasBeenSet() const { return m_treatmentsHasBeenSet; } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline void SetTreatments(const Aws::Vector& value) { m_treatmentsHasBeenSet = true; m_treatments = value; } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline void SetTreatments(Aws::Vector&& value) { m_treatmentsHasBeenSet = true; m_treatments = std::move(value); } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline CreateExperimentRequest& WithTreatments(const Aws::Vector& value) { SetTreatments(value); return *this;} /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline CreateExperimentRequest& WithTreatments(Aws::Vector&& value) { SetTreatments(std::move(value)); return *this;} /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline CreateExperimentRequest& AddTreatments(const TreatmentConfig& value) { m_treatmentsHasBeenSet = true; m_treatments.push_back(value); return *this; } /** *

An array of structures that describe the configuration of each feature * variation used in the experiment.

*/ inline CreateExperimentRequest& AddTreatments(TreatmentConfig&& value) { m_treatmentsHasBeenSet = true; m_treatments.push_back(std::move(value)); return *this; } private: Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::Vector m_metricGoals; bool m_metricGoalsHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; OnlineAbConfig m_onlineAbConfig; bool m_onlineAbConfigHasBeenSet = false; Aws::String m_project; bool m_projectHasBeenSet = false; Aws::String m_randomizationSalt; bool m_randomizationSaltHasBeenSet = false; long long m_samplingRate; bool m_samplingRateHasBeenSet = false; Aws::String m_segment; bool m_segmentHasBeenSet = false; Aws::Map m_tags; bool m_tagsHasBeenSet = false; Aws::Vector m_treatments; bool m_treatmentsHasBeenSet = false; }; } // namespace Model } // namespace CloudWatchEvidently } // namespace Aws