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

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline const Aws::String& GetDbName() const{ return m_dbName; } /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline bool DbNameHasBeenSet() const { return m_dbNameHasBeenSet; } /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline void SetDbName(const Aws::String& value) { m_dbNameHasBeenSet = true; m_dbName = value; } /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline void SetDbName(Aws::String&& value) { m_dbNameHasBeenSet = true; m_dbName = std::move(value); } /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline void SetDbName(const char* value) { m_dbNameHasBeenSet = true; m_dbName.assign(value); } /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline GetCredentialsRequest& WithDbName(const Aws::String& value) { SetDbName(value); return *this;} /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline GetCredentialsRequest& WithDbName(Aws::String&& value) { SetDbName(std::move(value)); return *this;} /** *

The name of the database to get temporary authorization to log on to.

*

Constraints:

  • Must be 1 to 64 alphanumeric characters or * hyphens.

  • Must contain only uppercase or lowercase letters, * numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen.

    *
  • The first character must be a letter.

  • Must not * contain a colon ( : ) or slash ( / ).

  • Cannot be a reserved * word. A list of reserved words can be found in Reserved * Words in the Amazon Redshift Database Developer Guide

*/ inline GetCredentialsRequest& WithDbName(const char* value) { SetDbName(value); return *this;} /** *

The number of seconds until the returned temporary password expires. The * minimum is 900 seconds, and the maximum is 3600 seconds.

*/ inline int GetDurationSeconds() const{ return m_durationSeconds; } /** *

The number of seconds until the returned temporary password expires. The * minimum is 900 seconds, and the maximum is 3600 seconds.

*/ inline bool DurationSecondsHasBeenSet() const { return m_durationSecondsHasBeenSet; } /** *

The number of seconds until the returned temporary password expires. The * minimum is 900 seconds, and the maximum is 3600 seconds.

*/ inline void SetDurationSeconds(int value) { m_durationSecondsHasBeenSet = true; m_durationSeconds = value; } /** *

The number of seconds until the returned temporary password expires. The * minimum is 900 seconds, and the maximum is 3600 seconds.

*/ inline GetCredentialsRequest& WithDurationSeconds(int value) { SetDurationSeconds(value); return *this;} /** *

The name of the workgroup associated with the database.

*/ inline const Aws::String& GetWorkgroupName() const{ return m_workgroupName; } /** *

The name of the workgroup associated with the database.

*/ inline bool WorkgroupNameHasBeenSet() const { return m_workgroupNameHasBeenSet; } /** *

The name of the workgroup associated with the database.

*/ inline void SetWorkgroupName(const Aws::String& value) { m_workgroupNameHasBeenSet = true; m_workgroupName = value; } /** *

The name of the workgroup associated with the database.

*/ inline void SetWorkgroupName(Aws::String&& value) { m_workgroupNameHasBeenSet = true; m_workgroupName = std::move(value); } /** *

The name of the workgroup associated with the database.

*/ inline void SetWorkgroupName(const char* value) { m_workgroupNameHasBeenSet = true; m_workgroupName.assign(value); } /** *

The name of the workgroup associated with the database.

*/ inline GetCredentialsRequest& WithWorkgroupName(const Aws::String& value) { SetWorkgroupName(value); return *this;} /** *

The name of the workgroup associated with the database.

*/ inline GetCredentialsRequest& WithWorkgroupName(Aws::String&& value) { SetWorkgroupName(std::move(value)); return *this;} /** *

The name of the workgroup associated with the database.

*/ inline GetCredentialsRequest& WithWorkgroupName(const char* value) { SetWorkgroupName(value); return *this;} private: Aws::String m_dbName; bool m_dbNameHasBeenSet = false; int m_durationSeconds; bool m_durationSecondsHasBeenSet = false; Aws::String m_workgroupName; bool m_workgroupNameHasBeenSet = false; }; } // namespace Model } // namespace RedshiftServerless } // namespace Aws