import * as pulumi from "@pulumi/pulumi"; /** * Manages one usage quota in the authenticated organization's account. Existing quotas must be imported, and each quota must be managed by only one Terraform resource. The usage quotas API must be enabled for the organization. This resource doesn't manage pending limits or descendant organizations. Disabling enforcement clears any pending limit; other updates preserve it. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as datadog from "@pulumi/datadog"; * * const example = new datadog.Role("example", {name: "quota-example"}); * const exampleUsageQuota = new datadog.UsageQuota("example", { * quotaNamespace: "ai_credits", * scope: { * role_uuid: example.id, * }, * usageLimit: 1000, * enforced: true, * }); * ``` * * ## Import * * The `pulumi import` command can be used, for example: * * Import one quota owned by the organization authenticated by the provider. * Obtain the opaque quota ID from the usage quotas API; do not decode or alter it. * * ```sh * $ pulumi import datadog:index/usageQuota:UsageQuota example 'ai_credits/' * ``` */ export declare class UsageQuota extends pulumi.CustomResource { /** * Get an existing UsageQuota 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, state?: UsageQuotaState, opts?: pulumi.CustomResourceOptions): UsageQuota; /** * Check whether an existing UsageQuota resource with the given ID exists. * * @param id The _unique_ provider ID of the resource to check. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static exists(id: pulumi.Input, state?: UsageQuotaState, opts?: pulumi.CustomResourceOptions): pulumi.Output; /** * Returns true if the given object is an instance of UsageQuota. 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 UsageQuota; /** * Whether the quota blocks usage. Setting false clears pending limits. */ readonly enforced: pulumi.Output; /** * Public ID of the organization owning the quota. */ readonly orgPublicId: pulumi.Output; /** * Opaque API quota identifier. Quota IDs can contain encoded scope values, such as user handles. These values are encoded, not encrypted. */ readonly quotaId: pulumi.Output; /** * Product-specific namespace. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported namespaces. Changing this value replaces the quota. Must be nonempty and contain no whitespace or slash. */ readonly quotaNamespace: pulumi.Output; /** * Namespace-specific scope. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported scopes. Omit for an organization-wide quota. Use `*` as the value for a default scope. Changing the scope replaces the quota. To avoid unplanned replacements, use scope values that consistently identify the same user, role, or team across runs. */ readonly scope: pulumi.Output<{ [key: string]: string; } | undefined>; /** * Usage limit, as a non-negative whole number of usage units. For `aiCredits`, the unit is credits per UTC calendar month. Imported legacy fractional values are preserved in state, but configuration requires a whole number. */ readonly usageLimit: pulumi.Output; /** * Create a UsageQuota 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: UsageQuotaArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering UsageQuota resources. */ export interface UsageQuotaState { /** * Whether the quota blocks usage. Setting false clears pending limits. */ enforced?: pulumi.Input; /** * Public ID of the organization owning the quota. */ orgPublicId?: pulumi.Input; /** * Opaque API quota identifier. Quota IDs can contain encoded scope values, such as user handles. These values are encoded, not encrypted. */ quotaId?: pulumi.Input; /** * Product-specific namespace. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported namespaces. Changing this value replaces the quota. Must be nonempty and contain no whitespace or slash. */ quotaNamespace?: pulumi.Input; /** * Namespace-specific scope. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported scopes. Omit for an organization-wide quota. Use `*` as the value for a default scope. Changing the scope replaces the quota. To avoid unplanned replacements, use scope values that consistently identify the same user, role, or team across runs. */ scope?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * Usage limit, as a non-negative whole number of usage units. For `aiCredits`, the unit is credits per UTC calendar month. Imported legacy fractional values are preserved in state, but configuration requires a whole number. */ usageLimit?: pulumi.Input; } /** * The set of arguments for constructing a UsageQuota resource. */ export interface UsageQuotaArgs { /** * Whether the quota blocks usage. Setting false clears pending limits. */ enforced: pulumi.Input; /** * Product-specific namespace. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported namespaces. Changing this value replaces the quota. Must be nonempty and contain no whitespace or slash. */ quotaNamespace: pulumi.Input; /** * Namespace-specific scope. See the [Usage Quotas API documentation](https://docs.datadoghq.com/api/latest/usage-metering/create-or-update-usage-quotas/) for supported scopes. Omit for an organization-wide quota. Use `*` as the value for a default scope. Changing the scope replaces the quota. To avoid unplanned replacements, use scope values that consistently identify the same user, role, or team across runs. */ scope?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * Usage limit, as a non-negative whole number of usage units. For `aiCredits`, the unit is credits per UTC calendar month. Imported legacy fractional values are preserved in state, but configuration requires a whole number. */ usageLimit: pulumi.Input; } //# sourceMappingURL=usageQuota.d.ts.map