java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.pricingplanmanager.CfnSubscription
All Implemented Interfaces:
IInspectable, IEnvironmentAware, ISubscriptionRef, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.139.0 (build 26a6b54)", date="2026-09-10T17:51:50.373Z") @Stability(Stable) public class CfnSubscription extends CfnResource implements IInspectable, ISubscriptionRef
Resource type definition for AWS::PricingPlanManager::Subscription.

Deleting an activated subscription does not terminate it immediately; it schedules a cancellation that takes effect at the end of the current billing period. Until that date the subscription remains active and billing continues. Deleting a subscription that has not yet been activated (PENDING_APPROVAL status) removes it immediately with no further charges.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.pricingplanmanager.*;
 CfnSubscription cfnSubscription = CfnSubscription.Builder.create(this, "MyCfnSubscription")
         .planFamily("planFamily")
         .planTier("planTier")
         .resourceArns(List.of("resourceArns"))
         // the properties below are optional
         .usageLevel("usageLevel")
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnSubscription

      protected CfnSubscription(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnSubscription

      protected CfnSubscription(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnSubscription

      @Stability(Stable) public CfnSubscription(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnSubscriptionProps props)
      Create a new AWS::PricingPlanManager::Subscription.

      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • arnForSubscription

      @Stability(Stable) @NotNull public static String arnForSubscription(@NotNull ISubscriptionRef resource)
      Parameters:
      resource - This parameter is required.
    • isCfnSubscription

      @Stability(Stable) @NotNull public static Boolean isCfnSubscription(@NotNull Object x)
      Checks whether the given object is a CfnSubscription.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrArn

      @Stability(Stable) @NotNull public String getAttrArn()
      The ARN of the subscription.
    • getAttrCreatedAt

      @Stability(Stable) @NotNull public String getAttrCreatedAt()
      The time the subscription was created, in ISO 8601 format.
    • getAttrCurrentPlanTier

      @Stability(Stable) @NotNull public String getAttrCurrentPlanTier()
      The plan tier currently active on the subscription as reported by the API.

      Populated by the Read handler. Diverges from PlanTier after a non-reversible CloudFormation rollback; surface via drift detection.

    • getAttrStatus

      @Stability(Stable) @NotNull public String getAttrStatus()
      The status of the subscription.

      PENDING_APPROVAL means a paid-tier subscription has been created but is not yet active and incurs no charges until it is approved out of band via a separate ApprovePaidSubscription call; CloudFormation never approves it. Free-tier subscriptions are activated immediately and do not use this status. ACTIVE means the subscription is in effect and, for paid tiers, billing has started. SYNC_IN_PROGRESS means a change is being applied. FAILED means provisioning did not complete; see StatusReason.

    • getAttrStatusReason

      @Stability(Stable) @NotNull public String getAttrStatusReason()
      A human-readable explanation of why the subscription is in its current status.

      Populated only when Status is FAILED, where it carries the reason the subscription could not be provisioned. Empty for all other statuses.

    • getAttrUpdatedAt

      @Stability(Stable) @NotNull public String getAttrUpdatedAt()
      The time the subscription was last modified, in ISO 8601 format.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getCfnPropertyNames

      @Stability(Stable) @NotNull protected Map<String,String> getCfnPropertyNames()
      Overrides:
      getCfnPropertyNames in class CfnResource
    • getSubscriptionRef

      @Stability(Stable) @NotNull public SubscriptionReference getSubscriptionRef()
      A reference to a Subscription resource.
      Specified by:
      getSubscriptionRef in interface ISubscriptionRef
    • getPlanFamily

      @Stability(Stable) @NotNull public String getPlanFamily()
      The name of the pricing plan family.
    • setPlanFamily

      @Stability(Stable) public void setPlanFamily(@NotNull String value)
      The name of the pricing plan family.
    • getPlanTier

      @Stability(Stable) @NotNull public String getPlanTier()
      The tier of the pricing plan.
    • setPlanTier

      @Stability(Stable) public void setPlanTier(@NotNull String value)
      The tier of the pricing plan.
    • getResourceArns

      @Stability(Stable) @NotNull public List<String> getResourceArns()
      The ARNs of resources associated with the subscription.
    • setResourceArns

      @Stability(Stable) public void setResourceArns(@NotNull List<String> value)
      The ARNs of resources associated with the subscription.
    • getUsageLevel

      @Stability(Stable) @Nullable public String getUsageLevel()
    • setUsageLevel

      @Stability(Stable) public void setUsageLevel(@Nullable String value)