import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
 * This resource provides the Tag resource in Oracle Cloud Infrastructure Identity service.
 * Api doc link for the resource: https://docs.oracle.com/iaas/api/#/en/identity/latest/Tag
 *
 * Example terraform configs related to the resource : https://github.com/oracle/terraform-provider-oci/tree/master/examples/identity
 *
 * Creates a new tag in the specified tag namespace.
 *
 * The tag requires either the OCID or the name of the tag namespace that will contain this
 * tag definition.
 *
 * You must specify a *name* for the tag, which must be unique across all tags in the tag namespace
 * and cannot be changed. The name can contain any ASCII character except the space (_) or period (.) characters.
 * Names are case insensitive. That means, for example, "myTag" and "mytag" are not allowed in the same namespace.
 * If you specify a name that's already in use in the tag namespace, a 409 error is returned.
 *
 * The tag must have a *description*. It does not have to be unique, and you can change it with
 * [UpdateTag](https://docs.cloud.oracle.com/iaas/api/#/en/identity/latest/Tag/UpdateTag).
 *
 * The tag must have a value type, which is specified with a validator. Tags can use either a
 * static value or a list of possible values. Static values are entered by a user applying the tag
 * to a resource. Lists are created by you and the user must apply a value from the list. Lists
 * are validiated.
 *
 * * If no `validator` is set, the user applying the tag to a resource can type in a static
 *   value or leave the tag value empty.
 * * If a `validator` is set, the user applying the tag to a resource must select from a list
 *   of values that you supply with [EnumTagDefinitionValidator](https://docs.cloud.oracle.com/iaas/api/#/en/identity/latest/datatypes/EnumTagDefinitionValidator).
 *
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as oci from "@pulumi/oci";
 *
 * const testTag = new oci.identity.Tag("test_tag", {
 *     description: tagDescription,
 *     name: tagName,
 *     tagNamespaceId: testTagNamespace.id,
 *     definedTags: {
 *         "Operations.CostCenter": "42",
 *     },
 *     freeformTags: {
 *         Department: "Finance",
 *     },
 *     isCostTracking: tagIsCostTracking === "true",
 *     validator: {
 *         validatorType: tagValidatorValidatorType,
 *         values: tagValidatorValues,
 *     },
 *     isRetired: false,
 * });
 * ```
 *
 * ## Import
 *
 * Tags can be imported using the `tagNamespaceId` and `tagName`, e.g.
 *
 * ```sh
 * $ pulumi import oci:Identity/tag:Tag test_tag "tagNamespaces/{tagNamespaceId}/tags/{tagName}"
 * ```
 */
export declare class Tag extends pulumi.CustomResource {
    /**
     * Get an existing Tag 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?: TagState, opts?: pulumi.CustomResourceOptions): Tag;
    /**
     * Returns true if the given object is an instance of Tag.  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 Tag;
    /**
     * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Operations.CostCenter": "42"}`
     */
    readonly definedTags: pulumi.Output<{
        [key: string]: string;
    }>;
    /**
     * (Updatable) The description you assign to the tag during creation.
     */
    readonly description: pulumi.Output<string>;
    /**
     * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Department": "Finance"}`
     */
    readonly freeformTags: pulumi.Output<{
        [key: string]: string;
    }>;
    /**
     * (Updatable) Indicates whether the tag is enabled for cost tracking.
     */
    readonly isCostTracking: pulumi.Output<boolean>;
    /**
     * (Updatable) Indicates whether the tag is retired. See [Retiring Key Definitions and Namespace Definitions](https://docs.us-phoenix-1.oraclecloud.com/Content/Identity/Concepts/taggingoverview.htm#Retiring).
     *
     *
     * ** IMPORTANT **
     * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
     */
    readonly isRetired: pulumi.Output<boolean>;
    /**
     * The name you assign to the tag during creation. This is the tag key definition. The name must be unique within the tag namespace and cannot be changed.
     */
    readonly name: pulumi.Output<string>;
    /**
     * The tag's current state. After creating a tag, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tag, make sure its `lifecycleState` is INACTIVE before using it. If you delete a tag, you cannot delete another tag until the deleted tag's `lifecycleState` changes from DELETING to DELETED.
     */
    readonly state: pulumi.Output<string>;
    /**
     * The OCID of the tag namespace.
     */
    readonly tagNamespaceId: pulumi.Output<string>;
    /**
     * Date and time the tag was created, in the format defined by RFC3339.  Example: `2016-08-25T21:10:29.600Z`
     */
    readonly timeCreated: pulumi.Output<string>;
    /**
     * (Updatable) Validates a definedTag value. Each validator performs validation steps in addition to the standard validation for definedTag values. For more information, see [Limits on Tags](https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/taggingoverview.htm#Limits).
     *
     * If you define a validator after a value has been set for a defined tag, then any updates that attempt to change the value must pass the additional validation defined by the current rule. Previously set values (even those that would fail the current validation) are not updated. You can still update other attributes to resources that contain a non-valid defined tag.
     *
     * To clear the validator call UpdateTag with [DefaultTagDefinitionValidator](https://docs.cloud.oracle.com/iaas/api/#/en/identity/latest/datatypes/DefaultTagDefinitionValidator).
     */
    readonly validator: pulumi.Output<outputs.Identity.TagValidator | undefined>;
    /**
     * Create a Tag 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: TagArgs, opts?: pulumi.CustomResourceOptions);
}
/**
 * Input properties used for looking up and filtering Tag resources.
 */
export interface TagState {
    /**
     * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Operations.CostCenter": "42"}`
     */
    definedTags?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    } | undefined>;
    /**
     * (Updatable) The description you assign to the tag during creation.
     */
    description?: pulumi.Input<string | undefined>;
    /**
     * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Department": "Finance"}`
     */
    freeformTags?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    } | undefined>;
    /**
     * (Updatable) Indicates whether the tag is enabled for cost tracking.
     */
    isCostTracking?: pulumi.Input<boolean | undefined>;
    /**
     * (Updatable) Indicates whether the tag is retired. See [Retiring Key Definitions and Namespace Definitions](https://docs.us-phoenix-1.oraclecloud.com/Content/Identity/Concepts/taggingoverview.htm#Retiring).
     *
     *
     * ** IMPORTANT **
     * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
     */
    isRetired?: pulumi.Input<boolean | undefined>;
    /**
     * The name you assign to the tag during creation. This is the tag key definition. The name must be unique within the tag namespace and cannot be changed.
     */
    name?: pulumi.Input<string | undefined>;
    /**
     * The tag's current state. After creating a tag, make sure its `lifecycleState` is ACTIVE before using it. After retiring a tag, make sure its `lifecycleState` is INACTIVE before using it. If you delete a tag, you cannot delete another tag until the deleted tag's `lifecycleState` changes from DELETING to DELETED.
     */
    state?: pulumi.Input<string | undefined>;
    /**
     * The OCID of the tag namespace.
     */
    tagNamespaceId?: pulumi.Input<string | undefined>;
    /**
     * Date and time the tag was created, in the format defined by RFC3339.  Example: `2016-08-25T21:10:29.600Z`
     */
    timeCreated?: pulumi.Input<string | undefined>;
    /**
     * (Updatable) Validates a definedTag value. Each validator performs validation steps in addition to the standard validation for definedTag values. For more information, see [Limits on Tags](https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/taggingoverview.htm#Limits).
     *
     * If you define a validator after a value has been set for a defined tag, then any updates that attempt to change the value must pass the additional validation defined by the current rule. Previously set values (even those that would fail the current validation) are not updated. You can still update other attributes to resources that contain a non-valid defined tag.
     *
     * To clear the validator call UpdateTag with [DefaultTagDefinitionValidator](https://docs.cloud.oracle.com/iaas/api/#/en/identity/latest/datatypes/DefaultTagDefinitionValidator).
     */
    validator?: pulumi.Input<inputs.Identity.TagValidator | undefined>;
}
/**
 * The set of arguments for constructing a Tag resource.
 */
export interface TagArgs {
    /**
     * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Operations.CostCenter": "42"}`
     */
    definedTags?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    } | undefined>;
    /**
     * (Updatable) The description you assign to the tag during creation.
     */
    description: pulumi.Input<string>;
    /**
     * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).  Example: `{"Department": "Finance"}`
     */
    freeformTags?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    } | undefined>;
    /**
     * (Updatable) Indicates whether the tag is enabled for cost tracking.
     */
    isCostTracking?: pulumi.Input<boolean | undefined>;
    /**
     * (Updatable) Indicates whether the tag is retired. See [Retiring Key Definitions and Namespace Definitions](https://docs.us-phoenix-1.oraclecloud.com/Content/Identity/Concepts/taggingoverview.htm#Retiring).
     *
     *
     * ** IMPORTANT **
     * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
     */
    isRetired?: pulumi.Input<boolean | undefined>;
    /**
     * The name you assign to the tag during creation. This is the tag key definition. The name must be unique within the tag namespace and cannot be changed.
     */
    name?: pulumi.Input<string | undefined>;
    /**
     * The OCID of the tag namespace.
     */
    tagNamespaceId: pulumi.Input<string>;
    /**
     * (Updatable) Validates a definedTag value. Each validator performs validation steps in addition to the standard validation for definedTag values. For more information, see [Limits on Tags](https://docs.cloud.oracle.com/iaas/Content/Identity/Concepts/taggingoverview.htm#Limits).
     *
     * If you define a validator after a value has been set for a defined tag, then any updates that attempt to change the value must pass the additional validation defined by the current rule. Previously set values (even those that would fail the current validation) are not updated. You can still update other attributes to resources that contain a non-valid defined tag.
     *
     * To clear the validator call UpdateTag with [DefaultTagDefinitionValidator](https://docs.cloud.oracle.com/iaas/api/#/en/identity/latest/datatypes/DefaultTagDefinitionValidator).
     */
    validator?: pulumi.Input<inputs.Identity.TagValidator | undefined>;
}
//# sourceMappingURL=tag.d.ts.map