Interface AccessKeyProps

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
AccessKeyProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.104.0 (build e79254c)", date="2024-11-21T06:34:09.206Z") @Stability(Stable) public interface AccessKeyProps extends software.amazon.jsii.JsiiSerializable
Properties for defining an IAM access key.

Example:

 // Creates a new IAM user, access and secret keys, and stores the secret access key in a Secret.
 User user = new User(this, "User");
 AccessKey accessKey = AccessKey.Builder.create(this, "AccessKey").user(user).build();
 Secret secret = Secret.Builder.create(this, "Secret")
         .secretStringValue(accessKey.getSecretAccessKey())
         .build();
 
  • Method Details

    • getUser

      @Stability(Stable) @NotNull IUser getUser()
      The IAM user this key will belong to.

      Changing this value will result in the access key being deleted and a new access key (with a different ID and secret value) being assigned to the new user.

    • getSerial

      @Stability(Stable) @Nullable default Number getSerial()
      A CloudFormation-specific value that signifies the access key should be replaced/rotated.

      This value can only be incremented. Incrementing this value will cause CloudFormation to replace the Access Key resource.

      Default: - No serial value

    • getStatus

      @Stability(Stable) @Nullable default AccessKeyStatus getStatus()
      The status of the access key.

      An Active access key is allowed to be used to make API calls; An Inactive key cannot.

      Default: - The access key is active

    • builder

      @Stability(Stable) static AccessKeyProps.Builder builder()
      Returns:
      a AccessKeyProps.Builder of AccessKeyProps