UNPKG

@huaweicloudos/pulumi

Version:

A Pulumi package for creating and managing Huaweicloud cloud resources.

123 lines (122 loc) 4.92 kB
import * as pulumi from "@pulumi/pulumi"; /** * Manages a VOD media category resource within HuaweiCloud. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as huaweicloud from "@pulumi/huaweicloud"; * * const test = new huaweicloud.Vod.MediaCategory("test", {}); * ``` * * ## Import * * The category can be imported using the `id`, e.g. bash * * ```sh * $ pulumi import huaweicloud:Vod/mediaCategory:MediaCategory test 132945 * ``` * * Note that the imported state may not be identical to your resource definition, due to some attributes missing from the API response, security or some other reason. The missing attributes include`parent_id`. It is generally recommended running `terraform plan` after importing a media category. You can then decide if changes should be applied to the media category, or the resource definition should be updated to align with the media category. Also you can ignore changes as below. hcl resource "huaweicloud_vod_media_category" "test" { * * ... * * lifecycle { * * ignore_changes = [ * * parent_id, * * ] * * } } */ export declare class MediaCategory extends pulumi.CustomResource { /** * Get an existing MediaCategory resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: MediaCategoryState, opts?: pulumi.CustomResourceOptions): MediaCategory; /** * Returns true if the given object is an instance of MediaCategory. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is MediaCategory; /** * The json string of subcategory information. It supports up to `3` levels of categories, * and each category supports up to 128 subcategories. */ readonly children: pulumi.Output<string>; /** * Specifies the category name, which contains a maximum of `64` characters. */ readonly name: pulumi.Output<string>; /** * Specifies the parent category ID. If this parameter is left blank, * the root category is generated by default. The root category ID is "0". Changing this creates a new resource. */ readonly parentId: pulumi.Output<string | undefined>; /** * Specifies the region in which to create the resource. If omitted, the * provider-level region will be used. Changing this creates a new resource. */ readonly region: pulumi.Output<string>; /** * Create a MediaCategory resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args?: MediaCategoryArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering MediaCategory resources. */ export interface MediaCategoryState { /** * The json string of subcategory information. It supports up to `3` levels of categories, * and each category supports up to 128 subcategories. */ children?: pulumi.Input<string>; /** * Specifies the category name, which contains a maximum of `64` characters. */ name?: pulumi.Input<string>; /** * Specifies the parent category ID. If this parameter is left blank, * the root category is generated by default. The root category ID is "0". Changing this creates a new resource. */ parentId?: pulumi.Input<string>; /** * Specifies the region in which to create the resource. If omitted, the * provider-level region will be used. Changing this creates a new resource. */ region?: pulumi.Input<string>; } /** * The set of arguments for constructing a MediaCategory resource. */ export interface MediaCategoryArgs { /** * Specifies the category name, which contains a maximum of `64` characters. */ name?: pulumi.Input<string>; /** * Specifies the parent category ID. If this parameter is left blank, * the root category is generated by default. The root category ID is "0". Changing this creates a new resource. */ parentId?: pulumi.Input<string>; /** * Specifies the region in which to create the resource. If omitted, the * provider-level region will be used. Changing this creates a new resource. */ region?: pulumi.Input<string>; }