/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace VerifiedPermissions { namespace Model { /** */ class CreatePolicyTemplateRequest : public VerifiedPermissionsRequest { public: AWS_VERIFIEDPERMISSIONS_API CreatePolicyTemplateRequest(); // 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 "CreatePolicyTemplate"; } AWS_VERIFIEDPERMISSIONS_API Aws::String SerializePayload() const override; AWS_VERIFIEDPERMISSIONS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline const Aws::String& GetClientToken() const{ return m_clientToken; } /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; } /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline void SetClientToken(const Aws::String& value) { m_clientTokenHasBeenSet = true; m_clientToken = value; } /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline void SetClientToken(Aws::String&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::move(value); } /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline void SetClientToken(const char* value) { m_clientTokenHasBeenSet = true; m_clientToken.assign(value); } /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline CreatePolicyTemplateRequest& WithClientToken(const Aws::String& value) { SetClientToken(value); return *this;} /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline CreatePolicyTemplateRequest& WithClientToken(Aws::String&& value) { SetClientToken(std::move(value)); return *this;} /** *

Specifies a unique, case-sensitive ID that you provide to ensure the * idempotency of the request. This lets you safely retry the request without * accidentally performing the same operation a second time. Passing the same value * to a later call to an operation requires that you also pass the same value for * all other parameters. We recommend that you use a UUID type of * value..

If you don't provide this value, then Amazon Web Services * generates a random one for you.

If you retry the operation with the same * ClientToken, but with different parameters, the retry fails with an * IdempotentParameterMismatch error.

*/ inline CreatePolicyTemplateRequest& WithClientToken(const char* value) { SetClientToken(value); return *this;} /** *

The ID of the policy store in which to create the policy template.

*/ inline const Aws::String& GetPolicyStoreId() const{ return m_policyStoreId; } /** *

The ID of the policy store in which to create the policy template.

*/ inline bool PolicyStoreIdHasBeenSet() const { return m_policyStoreIdHasBeenSet; } /** *

The ID of the policy store in which to create the policy template.

*/ inline void SetPolicyStoreId(const Aws::String& value) { m_policyStoreIdHasBeenSet = true; m_policyStoreId = value; } /** *

The ID of the policy store in which to create the policy template.

*/ inline void SetPolicyStoreId(Aws::String&& value) { m_policyStoreIdHasBeenSet = true; m_policyStoreId = std::move(value); } /** *

The ID of the policy store in which to create the policy template.

*/ inline void SetPolicyStoreId(const char* value) { m_policyStoreIdHasBeenSet = true; m_policyStoreId.assign(value); } /** *

The ID of the policy store in which to create the policy template.

*/ inline CreatePolicyTemplateRequest& WithPolicyStoreId(const Aws::String& value) { SetPolicyStoreId(value); return *this;} /** *

The ID of the policy store in which to create the policy template.

*/ inline CreatePolicyTemplateRequest& WithPolicyStoreId(Aws::String&& value) { SetPolicyStoreId(std::move(value)); return *this;} /** *

The ID of the policy store in which to create the policy template.

*/ inline CreatePolicyTemplateRequest& WithPolicyStoreId(const char* value) { SetPolicyStoreId(value); return *this;} /** *

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies a description for the policy template.

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

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline const Aws::String& GetStatement() const{ return m_statement; } /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline bool StatementHasBeenSet() const { return m_statementHasBeenSet; } /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline void SetStatement(const Aws::String& value) { m_statementHasBeenSet = true; m_statement = value; } /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline void SetStatement(Aws::String&& value) { m_statementHasBeenSet = true; m_statement = std::move(value); } /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline void SetStatement(const char* value) { m_statementHasBeenSet = true; m_statement.assign(value); } /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline CreatePolicyTemplateRequest& WithStatement(const Aws::String& value) { SetStatement(value); return *this;} /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline CreatePolicyTemplateRequest& WithStatement(Aws::String&& value) { SetStatement(std::move(value)); return *this;} /** *

Specifies the content that you want to use for the new policy template, * written in the Cedar policy language.

*/ inline CreatePolicyTemplateRequest& WithStatement(const char* value) { SetStatement(value); return *this;} private: Aws::String m_clientToken; bool m_clientTokenHasBeenSet = false; Aws::String m_policyStoreId; bool m_policyStoreIdHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::String m_statement; bool m_statementHasBeenSet = false; }; } // namespace Model } // namespace VerifiedPermissions } // namespace Aws