Provides a KMS Value Added Service resource.
Value Added Service.
For information about KMS Value Added Service and how to use it, see What is Value Added Service.
NOTE: Available since v1.267.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "terraform-example";
const _default = new alicloud.kms.ValueAddedService("default", {
valueAddedService: "2",
period: 1,
paymentType: "Subscription",
renewPeriod: 1,
renewStatus: "AutoRenewal",
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "terraform-example"
default = alicloud.kms.ValueAddedService("default",
value_added_service="2",
period=1,
payment_type="Subscription",
renew_period=1,
renew_status="AutoRenewal")
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/kms"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "terraform-example"
if param := cfg.Get("name"); param != "" {
name = param
}
_, err := kms.NewValueAddedService(ctx, "default", &kms.ValueAddedServiceArgs{
ValueAddedService: pulumi.String("2"),
Period: pulumi.Int(1),
PaymentType: pulumi.String("Subscription"),
RenewPeriod: pulumi.Int(1),
RenewStatus: pulumi.String("AutoRenewal"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "terraform-example";
var @default = new AliCloud.Kms.ValueAddedService("default", new()
{
ServiceType = "2",
Period = 1,
PaymentType = "Subscription",
RenewPeriod = 1,
RenewStatus = "AutoRenewal",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.kms.ValueAddedService;
import com.pulumi.alicloud.kms.ValueAddedServiceArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var config = ctx.config();
final var name = config.get("name").orElse("terraform-example");
var default_ = new ValueAddedService("default", ValueAddedServiceArgs.builder()
.valueAddedService("2")
.period(1)
.paymentType("Subscription")
.renewPeriod(1)
.renewStatus("AutoRenewal")
.build());
}
}
configuration:
name:
type: string
default: terraform-example
resources:
default:
type: alicloud:kms:ValueAddedService
properties:
valueAddedService: '2'
period: '1'
paymentType: Subscription
renewPeriod: '1'
renewStatus: AutoRenewal
📚 Need more examples? VIEW MORE EXAMPLES
Create ValueAddedService Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ValueAddedService(name: string, args: ValueAddedServiceArgs, opts?: CustomResourceOptions);@overload
def ValueAddedService(resource_name: str,
args: ValueAddedServiceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ValueAddedService(resource_name: str,
opts: Optional[ResourceOptions] = None,
payment_type: Optional[str] = None,
period: Optional[int] = None,
renew_period: Optional[int] = None,
renew_status: Optional[str] = None,
value_added_service: Optional[str] = None)func NewValueAddedService(ctx *Context, name string, args ValueAddedServiceArgs, opts ...ResourceOption) (*ValueAddedService, error)public ValueAddedService(string name, ValueAddedServiceArgs args, CustomResourceOptions? opts = null)
public ValueAddedService(String name, ValueAddedServiceArgs args)
public ValueAddedService(String name, ValueAddedServiceArgs args, CustomResourceOptions options)
type: alicloud:kms:ValueAddedService
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ValueAddedServiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ValueAddedServiceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ValueAddedServiceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ValueAddedServiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ValueAddedServiceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var valueAddedServiceResource = new AliCloud.Kms.ValueAddedService("valueAddedServiceResource", new()
{
PaymentType = "string",
Period = 0,
RenewPeriod = 0,
RenewStatus = "string",
ServiceType = "string",
});
example, err := kms.NewValueAddedService(ctx, "valueAddedServiceResource", &kms.ValueAddedServiceArgs{
PaymentType: pulumi.String("string"),
Period: pulumi.Int(0),
RenewPeriod: pulumi.Int(0),
RenewStatus: pulumi.String("string"),
ValueAddedService: pulumi.String("string"),
})
var valueAddedServiceResource = new ValueAddedService("valueAddedServiceResource", ValueAddedServiceArgs.builder()
.paymentType("string")
.period(0)
.renewPeriod(0)
.renewStatus("string")
.valueAddedService("string")
.build());
value_added_service_resource = alicloud.kms.ValueAddedService("valueAddedServiceResource",
payment_type="string",
period=0,
renew_period=0,
renew_status="string",
value_added_service="string")
const valueAddedServiceResource = new alicloud.kms.ValueAddedService("valueAddedServiceResource", {
paymentType: "string",
period: 0,
renewPeriod: 0,
renewStatus: "string",
valueAddedService: "string",
});
type: alicloud:kms:ValueAddedService
properties:
paymentType: string
period: 0
renewPeriod: 0
renewStatus: string
valueAddedService: string
ValueAddedService Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The ValueAddedService resource accepts the following input properties:
- Payment
Type string - The payment type of the resource
- Period int
- Renew
Period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- Renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- Service
Type string value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- Payment
Type string - The payment type of the resource
- Period int
- Renew
Period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- Renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- Value
Added stringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- payment
Type String - The payment type of the resource
- period Integer
- renew
Period Integer Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status String - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- value
Added StringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- payment
Type string - The payment type of the resource
- period number
- renew
Period number Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- value
Added stringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- payment_
type str - The payment type of the resource
- period int
- renew_
period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew_
status str - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- value_
added_ strservice value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- payment
Type String - The payment type of the resource
- period Number
- renew
Period Number Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status String - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- value
Added StringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
Outputs
All input properties are implicitly available as output properties. Additionally, the ValueAddedService resource produces the following output properties:
- Create
Time string - The creation time of the resource
- Id string
- The provider-assigned unique ID for this managed resource.
- Region
Id string - The region ID of the resource
- Status string
- The status of the resource
- Create
Time string - The creation time of the resource
- Id string
- The provider-assigned unique ID for this managed resource.
- Region
Id string - The region ID of the resource
- Status string
- The status of the resource
- create
Time String - The creation time of the resource
- id String
- The provider-assigned unique ID for this managed resource.
- region
Id String - The region ID of the resource
- status String
- The status of the resource
- create
Time string - The creation time of the resource
- id string
- The provider-assigned unique ID for this managed resource.
- region
Id string - The region ID of the resource
- status string
- The status of the resource
- create_
time str - The creation time of the resource
- id str
- The provider-assigned unique ID for this managed resource.
- region_
id str - The region ID of the resource
- status str
- The status of the resource
- create
Time String - The creation time of the resource
- id String
- The provider-assigned unique ID for this managed resource.
- region
Id String - The region ID of the resource
- status String
- The status of the resource
Look up Existing ValueAddedService Resource
Get an existing ValueAddedService resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ValueAddedServiceState, opts?: CustomResourceOptions): ValueAddedService@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
create_time: Optional[str] = None,
payment_type: Optional[str] = None,
period: Optional[int] = None,
region_id: Optional[str] = None,
renew_period: Optional[int] = None,
renew_status: Optional[str] = None,
status: Optional[str] = None,
value_added_service: Optional[str] = None) -> ValueAddedServicefunc GetValueAddedService(ctx *Context, name string, id IDInput, state *ValueAddedServiceState, opts ...ResourceOption) (*ValueAddedService, error)public static ValueAddedService Get(string name, Input<string> id, ValueAddedServiceState? state, CustomResourceOptions? opts = null)public static ValueAddedService get(String name, Output<String> id, ValueAddedServiceState state, CustomResourceOptions options)resources: _: type: alicloud:kms:ValueAddedService get: id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Create
Time string - The creation time of the resource
- Payment
Type string - The payment type of the resource
- Period int
- Region
Id string - The region ID of the resource
- Renew
Period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- Renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- Service
Type string value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- Status string
- The status of the resource
- Create
Time string - The creation time of the resource
- Payment
Type string - The payment type of the resource
- Period int
- Region
Id string - The region ID of the resource
- Renew
Period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- Renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- Status string
- The status of the resource
- Value
Added stringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- create
Time String - The creation time of the resource
- payment
Type String - The payment type of the resource
- period Integer
- region
Id String - The region ID of the resource
- renew
Period Integer Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status String - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- status String
- The status of the resource
- value
Added StringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- create
Time string - The creation time of the resource
- payment
Type string - The payment type of the resource
- period number
- region
Id string - The region ID of the resource
- renew
Period number Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status string - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- status string
- The status of the resource
- value
Added stringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- create_
time str - The creation time of the resource
- payment_
type str - The payment type of the resource
- period int
- region_
id str - The region ID of the resource
- renew_
period int Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew_
status str - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- status str
- The status of the resource
- value_
added_ strservice value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
- create
Time String - The creation time of the resource
- payment
Type String - The payment type of the resource
- period Number
- region
Id String - The region ID of the resource
- renew
Period Number Automatic renewal period, in years.
NOTE: When setting
RenewalStatustoAutoRenewal, it must be set.- renew
Status String - The renewal status of the specified instance. Valid values:
- AutoRenewal: The instance is automatically renewed.
- ManualRenewal: The instance is manually renewed.
- NotRenewal: The instance is not renewed.
- status String
- The status of the resource
- value
Added StringService value added service type, Instance Backup 1 default key rotation 2 Expert service 3
NOTE: The parameter is immutable after resource creation. It only applies during resource creation and has no effect when modified post-creation.
Import
KMS Value Added Service can be imported using the id, e.g.
$ pulumi import alicloud:kms/valueAddedService:ValueAddedService example <id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloudTerraform Provider.
