BillingConductor.Client.
create_pricing_rule
(**kwargs)¶Creates a pricing rule can be associated to a pricing plan, or a set of pricing plans.
See also: AWS API Documentation
Request Syntax
response = client.create_pricing_rule(
ClientToken='string',
Name='string',
Description='string',
Scope='GLOBAL'|'SERVICE'|'BILLING_ENTITY'|'SKU',
Type='MARKUP'|'DISCOUNT'|'TIERING',
ModifierPercentage=123.0,
Service='string',
Tags={
'string': 'string'
},
BillingEntity='string',
Tiering={
'FreeTier': {
'Activated': True|False
}
},
UsageType='string',
Operation='string'
)
The token that's needed to support idempotency. Idempotency isn't currently supported, but will be implemented in a future update.
This field is autopopulated if not provided.
[REQUIRED]
The pricing rule name. The names must be unique to each pricing rule.
[REQUIRED]
The scope of pricing rule that indicates if it's globally applicable, or it's service-specific.
[REQUIRED]
The type of pricing rule.
Scope
attribute is set to SERVICE
or SKU
, the attribute indicates which service the PricingRule
is applicable for.A map that contains tag keys and tag values that are attached to a pricing rule.
The set of tiering configurations for the pricing rule.
The possible Amazon Web Services Free Tier configurations.
Activate or deactivate Amazon Web Services Free Tier.
Usage type is the unit that each service uses to measure the usage of a specific type of resource.
If the Scope
attribute is set to SKU
, this attribute indicates which usage type the PricingRule
is modifying. For example, USW2-BoxUsage:m2.2xlarge
describes an M2 High Memory Double Extra Large
instance in the US West (Oregon) Region. </p>
Operation is the specific Amazon Web Services action covered by this line item. This describes the specific usage of the line item.
If the Scope
attribute is set to SKU
, this attribute indicates which operation the PricingRule
is modifying. For example, a value of RunInstances:0202
indicates the operation of running an Amazon EC2 instance.
dict
Response Syntax
{
'Arn': 'string'
}
Response Structure
(dict) --
Arn (string) --
The Amazon Resource Name (ARN) of the created pricing rule.
Exceptions
BillingConductor.Client.exceptions.ThrottlingException
BillingConductor.Client.exceptions.ConflictException
BillingConductor.Client.exceptions.AccessDeniedException
BillingConductor.Client.exceptions.ValidationException
BillingConductor.Client.exceptions.ServiceLimitExceededException
BillingConductor.Client.exceptions.InternalServerException