SDK for PHP V3

Client: Aws\PricingPlanManager\PricingPlanManagerClient
Service ID: pricing-plan-manager
Version: 2025-08-05

This page describes the parameters and results for the operations of the PricingPlanManager (2025-08-05), and shows how to use the Aws\PricingPlanManager\PricingPlanManagerClient object to call the described operations. This documentation is specific to the 2025-08-05 API version of the service.

Operation Summary

Each of the following operations can be created from a client using $client->getCommand('CommandName'), where "CommandName" is the name of one of the following operations. Note: a command is a value that encapsulates an operation and the parameters used to create an HTTP request.

You can also create and send a command immediately using the magic methods available on a client object: $client->commandName(/* parameters */). You can send the command asynchronously (returning a promise) by appending the word "Async" to the operation name: $client->commandNameAsync(/* parameters */).

ApprovePaidSubscription ( array $params = [] )
Approves a subscription that is in PENDING_APPROVAL status, activating it and starting billing.
AssociateResourcesToSubscription ( array $params = [] )
Adds one or more resources to an existing subscription.
CancelSubscription ( array $params = [] )
Cancels a flat-rate pricing subscription.
CancelSubscriptionChange ( array $params = [] )
Cancels a pending scheduled change on a subscription, such as a pending downgrade or cancellation.
CreateSubscription ( array $params = [] )
Creates a flat-rate pricing subscription for the specified resources.
DisassociateResourcesFromSubscription ( array $params = [] )
Removes one or more resources from an existing subscription.
GetSubscription ( array $params = [] )
Returns the details of a flat-rate pricing subscription, including its current status, associated resources, and any pending scheduled changes.
ListSubscriptions ( array $params = [] )
Returns a summary of all flat-rate pricing subscriptions in the calling account.
UpdateSubscription ( array $params = [] )
Changes the plan tier of an existing subscription.

Paginators

Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:

ListSubscriptions

Operations

ApprovePaidSubscription

$result = $client->approvePaidSubscription([/* ... */]);
$promise = $client->approvePaidSubscriptionAsync([/* ... */]);

Approves a subscription that is in PENDING_APPROVAL status, activating it and starting billing.

This operation requires the current ETag value for concurrency control. Retrieve it from a previous GetSubscription or ListSubscriptions response.

Parameter Syntax

$result = $client->approvePaidSubscription([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to approve.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response. This ensures you are approving the expected version of the subscription.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the approved subscription.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Approve a pending paid subscription
$result = $client->approvePaidSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '1',
]);

Result syntax:

[
    'eTag' => '2',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'SYNC_IN_PROGRESS',
        'updatedAt' => ,
    ],
]

AssociateResourcesToSubscription

$result = $client->associateResourcesToSubscription([/* ... */]);
$promise = $client->associateResourcesToSubscriptionAsync([/* ... */]);

Adds one or more resources to an existing subscription. The subscription must be in an active state that is not pending other changes.

For subscriptions in the CloudFront plan family, the associated resources must include exactly one Amazon CloudFront distribution and one AWS WAF web ACL. You can also include other supported resources, such as Amazon Route 53 hosted zones, and CloudFront KeyValueStores.

Parameter Syntax

$result = $client->associateResourcesToSubscription([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
    'resourceArns' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to add resources to.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response.

resourceArns
Required: Yes
Type: Array of strings

The ARNs of the resources to add to the subscription.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the subscription with the newly added resources.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Associate additional resources to a subscription
$result = $client->associateResourcesToSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '1',
    'resourceArns' => [
        'arn:aws:route53:::hostedzone/Z0123456789EXAMPLE',
    ],
]);

Result syntax:

[
    'eTag' => '2',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
            'arn:aws:route53:::hostedzone/Z0123456789EXAMPLE',
        ],
        'status' => 'SYNC_IN_PROGRESS',
        'updatedAt' => ,
    ],
]

CancelSubscription

$result = $client->cancelSubscription([/* ... */]);
$promise = $client->cancelSubscriptionAsync([/* ... */]);

Cancels a flat-rate pricing subscription.

For active subscriptions, the cancellation is scheduled to take effect at the end of the current billing period. The subscription remains active until that date. To revert a pending cancellation, use CancelSubscriptionChange.

For subscriptions in PENDING_APPROVAL status, the subscription is deleted immediately without scheduling.

Parameter Syntax

$result = $client->cancelSubscription([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to cancel.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the subscription with the pending cancellation. For active subscriptions, a scheduledChange of type CANCELLATION is included.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Cancel a subscription
$result = $client->cancelSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '2',
]);

Result syntax:

[
    'eTag' => '3',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'BUSINESS',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'scheduledChange' => [
            'changeType' => 'CANCELLATION',
            'effectiveDate' => ,
        ],
        'status' => 'ACTIVE',
        'updatedAt' => ,
    ],
]

CancelSubscriptionChange

$result = $client->cancelSubscriptionChange([/* ... */]);
$promise = $client->cancelSubscriptionChangeAsync([/* ... */]);

Cancels a pending scheduled change on a subscription, such as a pending downgrade or cancellation. The subscription returns to its state before the change was scheduled.

You cannot cancel a scheduled change close to its effective date. If the change is within the processing window, this operation returns an error.

Parameter Syntax

$result = $client->cancelSubscriptionChange([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription whose pending change you want to cancel.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the subscription with the pending change removed.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Cancel a pending subscription change
$result = $client->cancelSubscriptionChange([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '3',
]);

Result syntax:

[
    'eTag' => '4',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'BUSINESS',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'ACTIVE',
        'updatedAt' => ,
    ],
]

CreateSubscription

$result = $client->createSubscription([/* ... */]);
$promise = $client->createSubscriptionAsync([/* ... */]);

Creates a flat-rate pricing subscription for the specified resources.

When approvalMode is set to MANUAL, paid-tier subscriptions are created in PENDING_APPROVAL status and require a separate ApprovePaidSubscription call before billing starts. Free-tier subscriptions are always activated immediately regardless of approval mode.

When approvalMode is set to IMMEDIATE or is not specified, the subscription is activated immediately.

Parameter Syntax

$result = $client->createSubscription([
    'approvalMode' => 'MANUAL|IMMEDIATE',
    'clientToken' => '<string>',
    'planFamily' => '<string>', // REQUIRED
    'planTier' => '<string>', // REQUIRED
    'resourceArns' => ['<string>', ...], // REQUIRED
    'usageLevel' => '<string>',
]);

Parameter Details

Members
approvalMode
Type: string

Determines whether the subscription requires explicit approval before billing starts. Set to MANUAL to require a separate ApprovePaidSubscription call, or IMMEDIATE to activate the subscription right away. Defaults to IMMEDIATE if not specified.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure that the request is handled only once. If you send the same request with the same client token, the API returns the original response without creating a duplicate subscription.

planFamily
Required: Yes
Type: string

The pricing plan family to subscribe to, such as CloudFront.

planTier
Required: Yes
Type: string

The tier level for the subscription, such as FREE, PRO, BUSINESS, or PREMIUM.

resourceArns
Required: Yes
Type: Array of strings

The ARNs of the AWS resources to include in the subscription. Specify one or more supported resources.

For subscriptions in the CloudFront plan family, the resources must include exactly one Amazon CloudFront distribution and exactly one AWS WAF web ACL. You can also include other supported resources, such as Amazon Route 53 hosted zones and CloudFront KeyValueStores.

usageLevel
Type: string

The usage level within the plan tier. Specify DEFAULT for the base configuration, or a higher level if your plan tier supports it.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The entity tag for concurrency control. Use this value in the If-Match header for subsequent operations on this subscription.

subscription
Required: Yes
Type: Subscription structure

The details of the newly created subscription.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ServiceQuotaExceededException:

The request would exceed a service limit. You have reached the maximum number of subscriptions allowed for your account.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Create a flat-rate pricing subscription (deferred approval)
$result = $client->createSubscription([
    'approvalMode' => 'MANUAL',
    'planFamily' => 'CloudFront',
    'planTier' => 'PRO',
    'resourceArns' => [
        'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
        'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
    ],
]);

Result syntax:

[
    'eTag' => '1',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'PENDING_APPROVAL',
        'updatedAt' => ,
    ],
]
Example 2: Create a subscription with approval mode
$result = $client->createSubscription([
    'approvalMode' => 'IMMEDIATE',
    'planFamily' => 'CloudFront',
    'planTier' => 'PRO',
    'resourceArns' => [
        'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
        'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
    ],
]);

Result syntax:

[
    'eTag' => '1',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'SYNC_IN_PROGRESS',
        'updatedAt' => ,
    ],
]

DisassociateResourcesFromSubscription

$result = $client->disassociateResourcesFromSubscription([/* ... */]);
$promise = $client->disassociateResourcesFromSubscriptionAsync([/* ... */]);

Removes one or more resources from an existing subscription.

For subscriptions in the CloudFront plan family, the associated resources must always include exactly one Amazon CloudFront distribution and exactly one AWS WAF web ACL. You cannot remove these required resources.

Parameter Syntax

$result = $client->disassociateResourcesFromSubscription([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
    'resourceArns' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to remove resources from.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response.

resourceArns
Required: Yes
Type: Array of strings

The ARNs of the resources to remove from the subscription. For subscriptions in the CloudFront plan family, you cannot remove the required CloudFront distribution or WAF web ACL.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the subscription with the specified resources removed.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Remove a resource from a subscription
$result = $client->disassociateResourcesFromSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '2',
    'resourceArns' => [
        'arn:aws:route53:::hostedzone/Z0123456789EXAMPLE',
    ],
]);

Result syntax:

[
    'eTag' => '3',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'SYNC_IN_PROGRESS',
        'updatedAt' => ,
    ],
]

GetSubscription

$result = $client->getSubscription([/* ... */]);
$promise = $client->getSubscriptionAsync([/* ... */]);

Returns the details of a flat-rate pricing subscription, including its current status, associated resources, and any pending scheduled changes.

Parameter Syntax

$result = $client->getSubscription([
    'arn' => '<string>', // REQUIRED
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to retrieve.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The entity tag for concurrency control. Use this value in the If-Match header for subsequent operations on this subscription.

subscription
Required: Yes
Type: Subscription structure

The details of the requested subscription.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Get subscription details
$result = $client->getSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
]);

Result syntax:

[
    'eTag' => '1',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'PRO',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'ACTIVE',
        'updatedAt' => ,
    ],
]

ListSubscriptions

$result = $client->listSubscriptions([/* ... */]);
$promise = $client->listSubscriptionsAsync([/* ... */]);

Returns a summary of all flat-rate pricing subscriptions in the calling account.

Parameter Syntax

$result = $client->listSubscriptions([
    'nextToken' => '<string>',
]);

Parameter Details

Members
nextToken
Type: string

A token from a previous ListSubscriptions response. If the response included a nextToken, there are more results available. Pass this value to retrieve the next page of results.

Result Syntax

[
    'nextToken' => '<string>',
    'subscriptionSummaries' => [
        [
            'arn' => '<string>',
            'createdAt' => <DateTime>,
            'eTag' => '<string>',
            'planFamily' => '<string>',
            'planTier' => '<string>',
            'resourceArns' => ['<string>', ...],
            'scheduledChange' => [
                'changeType' => 'DOWNGRADE|CANCELLATION',
                'effectiveDate' => <DateTime>,
                'planTier' => '<string>',
                'usageLevel' => '<string>',
            ],
            'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
            'statusReason' => '<string>',
            'updatedAt' => <DateTime>,
            'usageLevel' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
nextToken
Type: string

A token that indicates there are more results available. Pass this value in a subsequent ListSubscriptions request to retrieve the next page of results.

subscriptionSummaries
Required: Yes
Type: Array of SubscriptionSummary structures

The list of subscription summaries for the calling account.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: List all subscriptions
$result = $client->listSubscriptions([
]);

Result syntax:

[
    'subscriptionSummaries' => [
        [
            'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
            'createdAt' => ,
            'eTag' => '1',
            'planFamily' => 'CloudFront',
            'planTier' => 'PRO',
            'resourceArns' => [
                'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
                'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
            ],
            'status' => 'ACTIVE',
            'updatedAt' => ,
        ],
    ],
]

UpdateSubscription

$result = $client->updateSubscription([/* ... */]);
$promise = $client->updateSubscriptionAsync([/* ... */]);

Changes the plan tier of an existing subscription.

Upgrades take effect immediately. Downgrades are scheduled and the current tier remains unchanged until the end of the billing cycle (calendar month). You cannot update a subscription while a scheduled change is pending. To make a new change, first cancel the pending change using CancelSubscriptionChange.

This operation replaces the plan tier value. If you omit the optional usageLevel field, it is reset to the default.

Parameter Syntax

$result = $client->updateSubscription([
    'arn' => '<string>', // REQUIRED
    'clientToken' => '<string>',
    'ifMatch' => '<string>', // REQUIRED
    'planTier' => '<string>', // REQUIRED
    'usageLevel' => '<string>',
]);

Parameter Details

Members
arn
Required: Yes
Type: string

The ARN of the subscription to update.

clientToken
Type: string

A unique, case-sensitive identifier that you provide to ensure the request is handled only once.

ifMatch
Required: Yes
Type: string

The ETag value from a previous GetSubscription or ListSubscriptions response. This ensures you are updating the expected version of the subscription.

planTier
Required: Yes
Type: string

The new tier level for the subscription.

usageLevel
Type: string

The usage level within the plan tier. Specify DEFAULT for the base configuration. If omitted, the usage level is reset to the default.

Result Syntax

[
    'eTag' => '<string>',
    'subscription' => [
        'arn' => '<string>',
        'createdAt' => <DateTime>,
        'planFamily' => '<string>',
        'planTier' => '<string>',
        'resourceArns' => ['<string>', ...],
        'scheduledChange' => [
            'changeType' => 'DOWNGRADE|CANCELLATION',
            'effectiveDate' => <DateTime>,
            'planTier' => '<string>',
            'usageLevel' => '<string>',
        ],
        'status' => 'PENDING_APPROVAL|ACTIVE|SYNC_IN_PROGRESS|FAILED',
        'statusReason' => '<string>',
        'updatedAt' => <DateTime>,
        'usageLevel' => '<string>',
    ],
]

Result Details

Members
eTag
Required: Yes
Type: string

The updated entity tag for concurrency control.

subscription
Required: Yes
Type: Subscription structure

The details of the updated subscription. For downgrades, the current tier remains unchanged and a scheduledChange indicates the pending change.

Errors

AccessDeniedException:

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

InternalServerException:

An unexpected error occurred on the server. Retry the request.

ValidationException:

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

ConflictException:

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

ServiceQuotaExceededException:

The request would exceed a service limit. You have reached the maximum number of subscriptions allowed for your account.

ResourceNotFoundException:

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

ThrottlingException:

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Examples

Example 1: Update a subscription plan tier
$result = $client->updateSubscription([
    'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
    'ifMatch' => '1',
    'planTier' => 'BUSINESS',
]);

Result syntax:

[
    'eTag' => '2',
    'subscription' => [
        'arn' => 'arn:aws:pricingplanmanager::123456789012:subscription/sub-1234567890',
        'createdAt' => ,
        'planFamily' => 'CloudFront',
        'planTier' => 'BUSINESS',
        'resourceArns' => [
            'arn:aws:cloudfront::123456789012:distribution/EDFDVBD6EXAMPLE',
            'arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4',
        ],
        'status' => 'SYNC_IN_PROGRESS',
        'updatedAt' => ,
    ],
]

Shapes

AccessDeniedException

Description

You do not have the required permissions to perform this operation. Verify that your IAM policy grants access to this action.

Members
message
Required: Yes
Type: string

ConflictException

Description

The request conflicts with the current state of the resource. This typically occurs when the ETag value in the If-Match header does not match the current version of the subscription. Retrieve the latest version and retry.

Members
message
Required: Yes
Type: string
resourceId
Required: Yes
Type: string

The identifier of the resource that has a conflicting state.

InternalServerException

Description

An unexpected error occurred on the server. Retry the request.

Members
message
Required: Yes
Type: string

ResourceNotFoundException

Description

The specified subscription was not found. Verify that the ARN is correct and that the subscription belongs to your account.

Members
message
Required: Yes
Type: string
resourceId
Required: Yes
Type: string

The identifier of the resource that was not found.

ScheduledChange

Description

A pending change on a subscription that takes effect at the end of the current billing period, such as a tier downgrade or cancellation.

Members
changeType
Required: Yes
Type: string

The type of pending change. Possible values are DOWNGRADE (a tier change to a lower level) and CANCELLATION (subscription termination).

effectiveDate
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the change takes effect, in ISO 8601 format. This value is populated after the change is confirmed by the billing system.

planTier
Type: string

For downgrades, the tier level that the subscription will change to. Not present for cancellations.

usageLevel
Type: string

For downgrades, the target usage level after the change takes effect.

ServiceQuotaExceededException

Description

The request would exceed a service limit. You have reached the maximum number of subscriptions allowed for your account.

Members
message
Required: Yes
Type: string

Subscription

Description

The full details of a flat-rate pricing subscription, including its current configuration, status, and associated resources.

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) that uniquely identifies this subscription.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the subscription was created, in ISO 8601 format.

planFamily
Required: Yes
Type: string

The pricing plan family for the subscription, such as CloudFront.

planTier
Required: Yes
Type: string

The current tier level of the pricing plan, such as FREE, PRO, BUSINESS, or PREMIUM.

resourceArns
Required: Yes
Type: Array of strings

The ARNs of the AWS resources covered by this subscription.

scheduledChange
Type: ScheduledChange structure

A pending change that will take effect at the end of the current billing period. This field is present only when a downgrade or cancellation is scheduled.

status
Required: Yes
Type: string

The current status of the subscription. For the list of possible values, see the Status type.

statusReason
Type: string

A human-readable explanation of the current status, present when additional context is available.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the subscription was last modified, in ISO 8601 format.

usageLevel
Type: string

The usage level within the plan tier. When present, indicates a specific capacity configuration beyond the base tier.

SubscriptionSummary

Description

Summary information for a flat-rate pricing subscription, as returned by list operations.

Members
arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) that uniquely identifies this subscription.

createdAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the subscription was created, in ISO 8601 format.

eTag
Required: Yes
Type: string

The entity tag for concurrency control. Pass this value in the If-Match header when making changes to this subscription.

planFamily
Required: Yes
Type: string

The pricing plan family for the subscription, such as CloudFront.

planTier
Required: Yes
Type: string

The current tier level of the pricing plan.

resourceArns
Required: Yes
Type: Array of strings

The ARNs of the AWS resources covered by this subscription.

scheduledChange
Type: ScheduledChange structure

A pending change that will take effect at the end of the current billing period, if any.

status
Required: Yes
Type: string

The current status of the subscription.

statusReason
Type: string

A human-readable explanation of the current status, present when additional context is available.

updatedAt
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the subscription was last modified, in ISO 8601 format.

usageLevel
Type: string

The usage level within the plan tier.

ThrottlingException

Description

The request rate exceeds the allowed limit. Wait briefly and retry the request.

Members
message
Type: string

ValidationException

Description

The request failed a business rule validation. For example, the specified resource might already be associated with another subscription, or the subscription might not be in the required state for this operation.

Members
message
Required: Yes
Type: string
resourceId
Type: string

The identifier of the resource that failed validation.