published on Tuesday, Sep 8, 2026 by Pulumi
published on Tuesday, Sep 8, 2026 by Pulumi
This resource allows you to manage Databricks Budgets.
This feature is in Public Preview.
This resource can only be used with an account-level provider!
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
const _this = new databricks.Budget("this", {
displayName: "databricks-workspace-budget",
alertConfigurations: [{
timePeriod: "MONTH",
triggerType: "CUMULATIVE_SPENDING_EXCEEDED",
quantityType: "LIST_PRICE_DOLLARS_USD",
quantityThreshold: "840",
actionConfigurations: [{
actionType: "EMAIL_NOTIFICATION",
target: "abc@gmail.com",
}],
}],
filter: {
workspaceId: {
operator: "IN",
values: [1234567890098765],
},
tags: [
{
key: "Team",
value: {
operator: "IN",
values: ["Data Science"],
},
},
{
key: "Environment",
value: {
operator: "IN",
values: ["Development"],
},
},
],
},
});
import pulumi
import pulumi_databricks as databricks
this = databricks.Budget("this",
display_name="databricks-workspace-budget",
alert_configurations=[{
"time_period": "MONTH",
"trigger_type": "CUMULATIVE_SPENDING_EXCEEDED",
"quantity_type": "LIST_PRICE_DOLLARS_USD",
"quantity_threshold": "840",
"action_configurations": [{
"action_type": "EMAIL_NOTIFICATION",
"target": "abc@gmail.com",
}],
}],
filter={
"workspace_id": {
"operator": "IN",
"values": [int(1234567890098765)],
},
"tags": [
{
"key": "Team",
"value": {
"operator": "IN",
"values": ["Data Science"],
},
},
{
"key": "Environment",
"value": {
"operator": "IN",
"values": ["Development"],
},
},
],
})
package main
import (
"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := databricks.NewBudget(ctx, "this", &databricks.BudgetArgs{
DisplayName: pulumi.String("databricks-workspace-budget"),
AlertConfigurations: databricks.BudgetAlertConfigurationArray{
&databricks.BudgetAlertConfigurationArgs{
TimePeriod: pulumi.String("MONTH"),
TriggerType: pulumi.String("CUMULATIVE_SPENDING_EXCEEDED"),
QuantityType: pulumi.String("LIST_PRICE_DOLLARS_USD"),
QuantityThreshold: pulumi.String("840"),
ActionConfigurations: databricks.BudgetAlertConfigurationActionConfigurationArray{
&databricks.BudgetAlertConfigurationActionConfigurationArgs{
ActionType: pulumi.String("EMAIL_NOTIFICATION"),
Target: pulumi.String("abc@gmail.com"),
},
},
},
},
Filter: &databricks.BudgetFilterArgs{
WorkspaceId: &databricks.BudgetFilterWorkspaceIdArgs{
Operator: pulumi.String("IN"),
Values: pulumi.IntArray{
pulumi.Int(1234567890098765),
},
},
Tags: databricks.BudgetFilterTagArray{
&databricks.BudgetFilterTagArgs{
Key: pulumi.String("Team"),
Value: &databricks.BudgetFilterTagValueArgs{
Operator: pulumi.String("IN"),
Values: pulumi.StringArray{
pulumi.String("Data Science"),
},
},
},
&databricks.BudgetFilterTagArgs{
Key: pulumi.String("Environment"),
Value: &databricks.BudgetFilterTagValueArgs{
Operator: pulumi.String("IN"),
Values: pulumi.StringArray{
pulumi.String("Development"),
},
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
var @this = new Databricks.Budget("this", new()
{
DisplayName = "databricks-workspace-budget",
AlertConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationArgs
{
TimePeriod = "MONTH",
TriggerType = "CUMULATIVE_SPENDING_EXCEEDED",
QuantityType = "LIST_PRICE_DOLLARS_USD",
QuantityThreshold = "840",
ActionConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationActionConfigurationArgs
{
ActionType = "EMAIL_NOTIFICATION",
Target = "abc@gmail.com",
},
},
},
},
Filter = new Databricks.Inputs.BudgetFilterArgs
{
WorkspaceId = new Databricks.Inputs.BudgetFilterWorkspaceIdArgs
{
Operator = "IN",
Values = new[]
{
1234567890098765,
},
},
Tags = new[]
{
new Databricks.Inputs.BudgetFilterTagArgs
{
Key = "Team",
Value = new Databricks.Inputs.BudgetFilterTagValueArgs
{
Operator = "IN",
Values = new[]
{
"Data Science",
},
},
},
new Databricks.Inputs.BudgetFilterTagArgs
{
Key = "Environment",
Value = new Databricks.Inputs.BudgetFilterTagValueArgs
{
Operator = "IN",
Values = new[]
{
"Development",
},
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.databricks.Budget;
import com.pulumi.databricks.BudgetArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationActionConfigurationArgs;
import com.pulumi.databricks.inputs.BudgetFilterArgs;
import com.pulumi.databricks.inputs.BudgetFilterWorkspaceIdArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagValueArgs;
import java.util.ArrayList;
import java.util.Arrays;
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) {
var this_ = new Budget("this", BudgetArgs.builder()
.displayName("databricks-workspace-budget")
.alertConfigurations(BudgetAlertConfigurationArgs.builder()
.timePeriod("MONTH")
.triggerType("CUMULATIVE_SPENDING_EXCEEDED")
.quantityType("LIST_PRICE_DOLLARS_USD")
.quantityThreshold("840")
.actionConfigurations(BudgetAlertConfigurationActionConfigurationArgs.builder()
.actionType("EMAIL_NOTIFICATION")
.target("abc@gmail.com")
.build())
.build())
.filter(BudgetFilterArgs.builder()
.workspaceId(BudgetFilterWorkspaceIdArgs.builder()
.operator("IN")
.values(1234567890098765)
.build())
.tags(
BudgetFilterTagArgs.builder()
.key("Team")
.value(BudgetFilterTagValueArgs.builder()
.operator("IN")
.values("Data Science")
.build())
.build(),
BudgetFilterTagArgs.builder()
.key("Environment")
.value(BudgetFilterTagValueArgs.builder()
.operator("IN")
.values("Development")
.build())
.build())
.build())
.build());
}
}
resources:
this:
type: databricks:Budget
properties:
displayName: databricks-workspace-budget
alertConfigurations:
- timePeriod: MONTH
triggerType: CUMULATIVE_SPENDING_EXCEEDED
quantityType: LIST_PRICE_DOLLARS_USD
quantityThreshold: '840'
actionConfigurations:
- actionType: EMAIL_NOTIFICATION
target: abc@gmail.com
filter:
workspaceId:
operator: IN
values:
- 1.234567890098765e+15
tags:
- key: Team
value:
operator: IN
values:
- Data Science
- key: Environment
value:
operator: IN
values:
- Development
pulumi {
required_providers {
databricks = {
source = "pulumi/databricks"
}
}
}
resource "databricks_budget" "this" {
display_name = "databricks-workspace-budget"
alert_configurations {
time_period = "MONTH"
trigger_type = "CUMULATIVE_SPENDING_EXCEEDED"
quantity_type = "LIST_PRICE_DOLLARS_USD"
quantity_threshold = "840"
action_configurations {
action_type = "EMAIL_NOTIFICATION"
target = "abc@gmail.com"
}
}
filter = {
workspace_id = {
operator = "IN"
values = [1234567890098765]
}
tags = [{
"key" = "Team"
"value" = {
"operator" = "IN"
"values" = ["Data Science"]
}
}, {
"key" = "Environment"
"value" = {
"operator" = "IN"
"values" = ["Development"]
}
}]
}
}
Budgets for AI Gateway Resources
Budgets can also be scoped to track only spend through Unity AI Gateway endpoints by setting resourceType to BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY.
This includes Databricks products that may use Unity AI Gateway endpoints, such as Databricks Genie.
AI Gateway Budget for all endpoints
Create a shared budget tracking all costs for Unity AI Gateway endpoints, and send an email when the budget threshold is exceeded.
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
const aiGatewaySharedBudget = new databricks.Budget("ai_gateway_shared_budget", {
displayName: "aigw-shared-budget",
resourceType: "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
alertConfigurations: [{
quantityThreshold: "10000",
quantityType: "LIST_PRICE_DOLLARS_USD",
triggerType: "CUMULATIVE_SPENDING_EXCEEDED",
timePeriod: "MONTH",
scopeType: "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
actionConfigurations: [{
actionType: "EMAIL_NOTIFICATION",
target: "abc@gmail.com",
}],
}],
});
import pulumi
import pulumi_databricks as databricks
ai_gateway_shared_budget = databricks.Budget("ai_gateway_shared_budget",
display_name="aigw-shared-budget",
resource_type="BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
alert_configurations=[{
"quantity_threshold": "10000",
"quantity_type": "LIST_PRICE_DOLLARS_USD",
"trigger_type": "CUMULATIVE_SPENDING_EXCEEDED",
"time_period": "MONTH",
"scope_type": "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
"action_configurations": [{
"action_type": "EMAIL_NOTIFICATION",
"target": "abc@gmail.com",
}],
}])
package main
import (
"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := databricks.NewBudget(ctx, "ai_gateway_shared_budget", &databricks.BudgetArgs{
DisplayName: pulumi.String("aigw-shared-budget"),
ResourceType: pulumi.String("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"),
AlertConfigurations: databricks.BudgetAlertConfigurationArray{
&databricks.BudgetAlertConfigurationArgs{
QuantityThreshold: pulumi.String("10000"),
QuantityType: pulumi.String("LIST_PRICE_DOLLARS_USD"),
TriggerType: pulumi.String("CUMULATIVE_SPENDING_EXCEEDED"),
TimePeriod: pulumi.String("MONTH"),
ScopeType: pulumi.String("ALERT_CONFIGURATION_SCOPE_TYPE_SHARED"),
ActionConfigurations: databricks.BudgetAlertConfigurationActionConfigurationArray{
&databricks.BudgetAlertConfigurationActionConfigurationArgs{
ActionType: pulumi.String("EMAIL_NOTIFICATION"),
Target: pulumi.String("abc@gmail.com"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
var aiGatewaySharedBudget = new Databricks.Budget("ai_gateway_shared_budget", new()
{
DisplayName = "aigw-shared-budget",
ResourceType = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
AlertConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationArgs
{
QuantityThreshold = "10000",
QuantityType = "LIST_PRICE_DOLLARS_USD",
TriggerType = "CUMULATIVE_SPENDING_EXCEEDED",
TimePeriod = "MONTH",
ScopeType = "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
ActionConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationActionConfigurationArgs
{
ActionType = "EMAIL_NOTIFICATION",
Target = "abc@gmail.com",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.databricks.Budget;
import com.pulumi.databricks.BudgetArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationActionConfigurationArgs;
import java.util.ArrayList;
import java.util.Arrays;
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) {
var aiGatewaySharedBudget = new Budget("aiGatewaySharedBudget", BudgetArgs.builder()
.displayName("aigw-shared-budget")
.resourceType("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY")
.alertConfigurations(BudgetAlertConfigurationArgs.builder()
.quantityThreshold("10000")
.quantityType("LIST_PRICE_DOLLARS_USD")
.triggerType("CUMULATIVE_SPENDING_EXCEEDED")
.timePeriod("MONTH")
.scopeType("ALERT_CONFIGURATION_SCOPE_TYPE_SHARED")
.actionConfigurations(BudgetAlertConfigurationActionConfigurationArgs.builder()
.actionType("EMAIL_NOTIFICATION")
.target("abc@gmail.com")
.build())
.build())
.build());
}
}
resources:
aiGatewaySharedBudget:
type: databricks:Budget
name: ai_gateway_shared_budget
properties:
displayName: aigw-shared-budget
resourceType: BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY
alertConfigurations:
- quantityThreshold: '10000'
quantityType: LIST_PRICE_DOLLARS_USD
triggerType: CUMULATIVE_SPENDING_EXCEEDED
timePeriod: MONTH
scopeType: ALERT_CONFIGURATION_SCOPE_TYPE_SHARED
actionConfigurations:
- actionType: EMAIL_NOTIFICATION
target: abc@gmail.com
pulumi {
required_providers {
databricks = {
source = "pulumi/databricks"
}
}
}
resource "databricks_budget" "ai_gateway_shared_budget" {
display_name = "aigw-shared-budget"
resource_type = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"
alert_configurations {
quantity_threshold = "10000"
quantity_type = "LIST_PRICE_DOLLARS_USD"
trigger_type = "CUMULATIVE_SPENDING_EXCEEDED"
time_period = "MONTH"
scope_type = "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED"
action_configurations {
action_type = "EMAIL_NOTIFICATION"
target = "abc@gmail.com"
}
}
}
Shared Genie budget
Genie budgets use the Unity AI Gateway resource type and the databricks-product: genie tag. Do not add other resource tags to a Genie budget.
A shared Genie budget for all users. Spend is tracked in aggregate.
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
const genieSharedBudget = new databricks.Budget("genie_shared_budget", {
displayName: "genie-shared-budget",
resourceType: "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
filter: {
tags: [{
key: "databricks-product",
value: {
operator: "IN",
values: ["genie"],
},
}],
},
alertConfigurations: [{
quantityThreshold: "2000",
quantityType: "LIST_PRICE_DOLLARS_USD",
triggerType: "CUMULATIVE_SPENDING_EXCEEDED",
timePeriod: "MONTH",
scopeType: "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
actionConfigurations: [{
actionType: "EMAIL_NOTIFICATION",
target: "abc@gmail.com",
}],
}],
});
import pulumi
import pulumi_databricks as databricks
genie_shared_budget = databricks.Budget("genie_shared_budget",
display_name="genie-shared-budget",
resource_type="BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
filter={
"tags": [{
"key": "databricks-product",
"value": {
"operator": "IN",
"values": ["genie"],
},
}],
},
alert_configurations=[{
"quantity_threshold": "2000",
"quantity_type": "LIST_PRICE_DOLLARS_USD",
"trigger_type": "CUMULATIVE_SPENDING_EXCEEDED",
"time_period": "MONTH",
"scope_type": "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
"action_configurations": [{
"action_type": "EMAIL_NOTIFICATION",
"target": "abc@gmail.com",
}],
}])
package main
import (
"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := databricks.NewBudget(ctx, "genie_shared_budget", &databricks.BudgetArgs{
DisplayName: pulumi.String("genie-shared-budget"),
ResourceType: pulumi.String("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"),
Filter: &databricks.BudgetFilterArgs{
Tags: databricks.BudgetFilterTagArray{
&databricks.BudgetFilterTagArgs{
Key: pulumi.String("databricks-product"),
Value: &databricks.BudgetFilterTagValueArgs{
Operator: pulumi.String("IN"),
Values: pulumi.StringArray{
pulumi.String("genie"),
},
},
},
},
},
AlertConfigurations: databricks.BudgetAlertConfigurationArray{
&databricks.BudgetAlertConfigurationArgs{
QuantityThreshold: pulumi.String("2000"),
QuantityType: pulumi.String("LIST_PRICE_DOLLARS_USD"),
TriggerType: pulumi.String("CUMULATIVE_SPENDING_EXCEEDED"),
TimePeriod: pulumi.String("MONTH"),
ScopeType: pulumi.String("ALERT_CONFIGURATION_SCOPE_TYPE_SHARED"),
ActionConfigurations: databricks.BudgetAlertConfigurationActionConfigurationArray{
&databricks.BudgetAlertConfigurationActionConfigurationArgs{
ActionType: pulumi.String("EMAIL_NOTIFICATION"),
Target: pulumi.String("abc@gmail.com"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
var genieSharedBudget = new Databricks.Budget("genie_shared_budget", new()
{
DisplayName = "genie-shared-budget",
ResourceType = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
Filter = new Databricks.Inputs.BudgetFilterArgs
{
Tags = new[]
{
new Databricks.Inputs.BudgetFilterTagArgs
{
Key = "databricks-product",
Value = new Databricks.Inputs.BudgetFilterTagValueArgs
{
Operator = "IN",
Values = new[]
{
"genie",
},
},
},
},
},
AlertConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationArgs
{
QuantityThreshold = "2000",
QuantityType = "LIST_PRICE_DOLLARS_USD",
TriggerType = "CUMULATIVE_SPENDING_EXCEEDED",
TimePeriod = "MONTH",
ScopeType = "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED",
ActionConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationActionConfigurationArgs
{
ActionType = "EMAIL_NOTIFICATION",
Target = "abc@gmail.com",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.databricks.Budget;
import com.pulumi.databricks.BudgetArgs;
import com.pulumi.databricks.inputs.BudgetFilterArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagValueArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationActionConfigurationArgs;
import java.util.ArrayList;
import java.util.Arrays;
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) {
var genieSharedBudget = new Budget("genieSharedBudget", BudgetArgs.builder()
.displayName("genie-shared-budget")
.resourceType("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY")
.filter(BudgetFilterArgs.builder()
.tags(BudgetFilterTagArgs.builder()
.key("databricks-product")
.value(BudgetFilterTagValueArgs.builder()
.operator("IN")
.values("genie")
.build())
.build())
.build())
.alertConfigurations(BudgetAlertConfigurationArgs.builder()
.quantityThreshold("2000")
.quantityType("LIST_PRICE_DOLLARS_USD")
.triggerType("CUMULATIVE_SPENDING_EXCEEDED")
.timePeriod("MONTH")
.scopeType("ALERT_CONFIGURATION_SCOPE_TYPE_SHARED")
.actionConfigurations(BudgetAlertConfigurationActionConfigurationArgs.builder()
.actionType("EMAIL_NOTIFICATION")
.target("abc@gmail.com")
.build())
.build())
.build());
}
}
resources:
genieSharedBudget:
type: databricks:Budget
name: genie_shared_budget
properties:
displayName: genie-shared-budget
resourceType: BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY
filter:
tags:
- key: databricks-product
value:
operator: IN
values:
- genie
alertConfigurations:
- quantityThreshold: '2000'
quantityType: LIST_PRICE_DOLLARS_USD
triggerType: CUMULATIVE_SPENDING_EXCEEDED
timePeriod: MONTH
scopeType: ALERT_CONFIGURATION_SCOPE_TYPE_SHARED
actionConfigurations:
- actionType: EMAIL_NOTIFICATION
target: abc@gmail.com
pulumi {
required_providers {
databricks = {
source = "pulumi/databricks"
}
}
}
resource "databricks_budget" "genie_shared_budget" {
display_name = "genie-shared-budget"
resource_type = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"
filter = {
tags = [{
"key" = "databricks-product"
"value" = {
"operator" = "IN"
"values" = ["genie"]
}
}]
}
alert_configurations {
quantity_threshold = "2000"
quantity_type = "LIST_PRICE_DOLLARS_USD"
trigger_type = "CUMULATIVE_SPENDING_EXCEEDED"
time_period = "MONTH"
scope_type = "ALERT_CONFIGURATION_SCOPE_TYPE_SHARED"
action_configurations {
action_type = "EMAIL_NOTIFICATION"
target = "abc@gmail.com"
}
}
}
Per-user budget overrides with block usage
A per-user threshold applies to each user in the budget’s scope. Use principalOverrides to override the threshold for specific users, groups, or service principals. BLOCK_USAGE prevents further requests through Unity AI Gateway when the threshold is reached.
import * as pulumi from "@pulumi/pulumi";
import * as databricks from "@pulumi/databricks";
// Find a group we want to apply
const genie_power_users = databricks.getGroup({
displayName: "genie-power-users",
});
// Create a budget for Genie of $100 per user, and override
// the threshold to $300 per user for the genie-power-users group.
const geniePerUserBudget = new databricks.Budget("genie_per_user_budget", {
displayName: "genie-tier-1-budget",
resourceType: "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
filter: {
tags: [{
key: "databricks-product",
value: {
operator: "IN",
values: ["genie"],
},
}],
},
alertConfigurations: [{
quantityThreshold: "100",
quantityType: "LIST_PRICE_DOLLARS_USD",
triggerType: "CUMULATIVE_SPENDING_EXCEEDED",
timePeriod: "MONTH",
scopeType: "ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER",
principalOverrides: [{
principalId: genie_power_usersDatabricksGroup.id,
overrideThreshold: "300",
}],
actionConfigurations: [{
actionType: "BLOCK_USAGE",
}],
}],
});
import pulumi
import pulumi_databricks as databricks
# Find a group we want to apply
genie_power_users = databricks.get_group(display_name="genie-power-users")
# Create a budget for Genie of $100 per user, and override
# the threshold to $300 per user for the genie-power-users group.
genie_per_user_budget = databricks.Budget("genie_per_user_budget",
display_name="genie-tier-1-budget",
resource_type="BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
filter={
"tags": [{
"key": "databricks-product",
"value": {
"operator": "IN",
"values": ["genie"],
},
}],
},
alert_configurations=[{
"quantity_threshold": "100",
"quantity_type": "LIST_PRICE_DOLLARS_USD",
"trigger_type": "CUMULATIVE_SPENDING_EXCEEDED",
"time_period": "MONTH",
"scope_type": "ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER",
"principal_overrides": [{
"principal_id": genie_power_users_databricks_group["id"],
"override_threshold": "300",
}],
"action_configurations": [{
"action_type": "BLOCK_USAGE",
}],
}])
package main
import (
"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
// Find a group we want to apply
_, err := databricks.GetGroup(ctx, &databricks.LookupGroupArgs{
DisplayName: "genie-power-users",
}, nil)
if err != nil {
return err
}
// Create a budget for Genie of $100 per user, and override
// the threshold to $300 per user for the genie-power-users group.
_, err = databricks.NewBudget(ctx, "genie_per_user_budget", &databricks.BudgetArgs{
DisplayName: pulumi.String("genie-tier-1-budget"),
ResourceType: pulumi.String("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"),
Filter: &databricks.BudgetFilterArgs{
Tags: databricks.BudgetFilterTagArray{
&databricks.BudgetFilterTagArgs{
Key: pulumi.String("databricks-product"),
Value: &databricks.BudgetFilterTagValueArgs{
Operator: pulumi.String("IN"),
Values: pulumi.StringArray{
pulumi.String("genie"),
},
},
},
},
},
AlertConfigurations: databricks.BudgetAlertConfigurationArray{
&databricks.BudgetAlertConfigurationArgs{
QuantityThreshold: pulumi.String("100"),
QuantityType: pulumi.String("LIST_PRICE_DOLLARS_USD"),
TriggerType: pulumi.String("CUMULATIVE_SPENDING_EXCEEDED"),
TimePeriod: pulumi.String("MONTH"),
ScopeType: pulumi.String("ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER"),
PrincipalOverrides: databricks.BudgetAlertConfigurationPrincipalOverrideArray{
&databricks.BudgetAlertConfigurationPrincipalOverrideArgs{
PrincipalId: pulumi.Any(genie_power_usersDatabricksGroup.Id),
OverrideThreshold: pulumi.String("300"),
},
},
ActionConfigurations: databricks.BudgetAlertConfigurationActionConfigurationArray{
&databricks.BudgetAlertConfigurationActionConfigurationArgs{
ActionType: pulumi.String("BLOCK_USAGE"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Databricks = Pulumi.Databricks;
return await Deployment.RunAsync(() =>
{
// Find a group we want to apply
var genie_power_users = Databricks.GetGroup.Invoke(new()
{
DisplayName = "genie-power-users",
});
// Create a budget for Genie of $100 per user, and override
// the threshold to $300 per user for the genie-power-users group.
var geniePerUserBudget = new Databricks.Budget("genie_per_user_budget", new()
{
DisplayName = "genie-tier-1-budget",
ResourceType = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY",
Filter = new Databricks.Inputs.BudgetFilterArgs
{
Tags = new[]
{
new Databricks.Inputs.BudgetFilterTagArgs
{
Key = "databricks-product",
Value = new Databricks.Inputs.BudgetFilterTagValueArgs
{
Operator = "IN",
Values = new[]
{
"genie",
},
},
},
},
},
AlertConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationArgs
{
QuantityThreshold = "100",
QuantityType = "LIST_PRICE_DOLLARS_USD",
TriggerType = "CUMULATIVE_SPENDING_EXCEEDED",
TimePeriod = "MONTH",
ScopeType = "ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER",
PrincipalOverrides = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationPrincipalOverrideArgs
{
PrincipalId = genie_power_usersDatabricksGroup.Id,
OverrideThreshold = "300",
},
},
ActionConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationActionConfigurationArgs
{
ActionType = "BLOCK_USAGE",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.databricks.DatabricksFunctions;
import com.pulumi.databricks.inputs.GetGroupArgs;
import com.pulumi.databricks.Budget;
import com.pulumi.databricks.BudgetArgs;
import com.pulumi.databricks.inputs.BudgetFilterArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagArgs;
import com.pulumi.databricks.inputs.BudgetFilterTagValueArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationPrincipalOverrideArgs;
import com.pulumi.databricks.inputs.BudgetAlertConfigurationActionConfigurationArgs;
import java.util.ArrayList;
import java.util.Arrays;
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) {
// Find a group we want to apply
final var genie-power-users = DatabricksFunctions.getGroup(GetGroupArgs.builder()
.displayName("genie-power-users")
.build());
// Create a budget for Genie of $100 per user, and override
// the threshold to $300 per user for the genie-power-users group.
var geniePerUserBudget = new Budget("geniePerUserBudget", BudgetArgs.builder()
.displayName("genie-tier-1-budget")
.resourceType("BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY")
.filter(BudgetFilterArgs.builder()
.tags(BudgetFilterTagArgs.builder()
.key("databricks-product")
.value(BudgetFilterTagValueArgs.builder()
.operator("IN")
.values("genie")
.build())
.build())
.build())
.alertConfigurations(BudgetAlertConfigurationArgs.builder()
.quantityThreshold("100")
.quantityType("LIST_PRICE_DOLLARS_USD")
.triggerType("CUMULATIVE_SPENDING_EXCEEDED")
.timePeriod("MONTH")
.scopeType("ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER")
.principalOverrides(BudgetAlertConfigurationPrincipalOverrideArgs.builder()
.principalId(genie_power_usersDatabricksGroup.id())
.overrideThreshold("300")
.build())
.actionConfigurations(BudgetAlertConfigurationActionConfigurationArgs.builder()
.actionType("BLOCK_USAGE")
.build())
.build())
.build());
}
}
resources:
# Create a budget for Genie of $100 per user, and override
# // the threshold to $300 per user for the genie-power-users group.
geniePerUserBudget:
type: databricks:Budget
name: genie_per_user_budget
properties:
displayName: genie-tier-1-budget
resourceType: BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY
filter:
tags:
- key: databricks-product
value:
operator: IN
values:
- genie
alertConfigurations:
- quantityThreshold: '100'
quantityType: LIST_PRICE_DOLLARS_USD
triggerType: CUMULATIVE_SPENDING_EXCEEDED
timePeriod: MONTH
scopeType: ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER
principalOverrides:
- principalId: ${["genie-power-usersDatabricksGroup"].id}
overrideThreshold: '300'
actionConfigurations:
- actionType: BLOCK_USAGE
variables:
# Find a group we want to apply
genie-power-users:
fn::invoke:
function: databricks:getGroup
arguments:
displayName: genie-power-users
pulumi {
required_providers {
databricks = {
source = "pulumi/databricks"
}
}
}
data "databricks_getgroup" "genie-power-users" {
display_name = "genie-power-users"
}
// Create a budget for Genie of $100 per user, and override
// the threshold to $300 per user for the genie-power-users group.
resource "databricks_budget" "genie_per_user_budget" {
display_name = "genie-tier-1-budget"
resource_type = "BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY"
filter = {
tags = [{
"key" = "databricks-product"
"value" = {
"operator" = "IN"
"values" = ["genie"]
}
}]
}
alert_configurations {
quantity_threshold = "100"
quantity_type = "LIST_PRICE_DOLLARS_USD"
trigger_type = "CUMULATIVE_SPENDING_EXCEEDED"
time_period = "MONTH"
scope_type = "ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER"
principal_overrides {
principal_id = genie-power-usersDatabricksGroup.id
override_threshold = "300"
}
action_configurations {
action_type = "BLOCK_USAGE"
}
}
}
// Find a group we want to apply
Related Resources
The following resources are used in the context:
- databricks.MwsWorkspaces to set up Databricks workspaces.
Create Budget Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Budget(name: string, args?: BudgetArgs, opts?: CustomResourceOptions);@overload
def Budget(resource_name: str,
args: Optional[BudgetArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Budget(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
alert_configurations: Optional[Sequence[BudgetAlertConfigurationArgs]] = None,
budget_configuration_id: Optional[str] = None,
create_time: Optional[int] = None,
display_name: Optional[str] = None,
filter: Optional[BudgetFilterArgs] = None,
resource_type: Optional[str] = None,
update_time: Optional[int] = None)func NewBudget(ctx *Context, name string, args *BudgetArgs, opts ...ResourceOption) (*Budget, error)public Budget(string name, BudgetArgs? args = null, CustomResourceOptions? opts = null)
public Budget(String name, BudgetArgs args)
public Budget(String name, BudgetArgs args, CustomResourceOptions options)
type: databricks:Budget
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "databricks_budget" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args BudgetArgs
- 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 BudgetArgs
- 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 BudgetArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args BudgetArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args BudgetArgs
- 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 budgetResource = new Databricks.Budget("budgetResource", new()
{
AccountId = "string",
AlertConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationArgs
{
ActionConfigurations = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationActionConfigurationArgs
{
ActionConfigurationId = "string",
ActionType = "string",
Target = "string",
},
},
AlertConfigurationId = "string",
PrincipalOverrides = new[]
{
new Databricks.Inputs.BudgetAlertConfigurationPrincipalOverrideArgs
{
OverrideThreshold = "string",
PrincipalId = "string",
},
},
QuantityThreshold = "string",
QuantityType = "string",
ScopeType = "string",
TimePeriod = "string",
TriggerType = "string",
},
},
BudgetConfigurationId = "string",
CreateTime = 0,
DisplayName = "string",
Filter = new Databricks.Inputs.BudgetFilterArgs
{
Tags = new[]
{
new Databricks.Inputs.BudgetFilterTagArgs
{
Key = "string",
Value = new Databricks.Inputs.BudgetFilterTagValueArgs
{
Operator = "string",
Values = new[]
{
"string",
},
},
},
},
WorkspaceId = new Databricks.Inputs.BudgetFilterWorkspaceIdArgs
{
Operator = "string",
Values = new[]
{
0,
},
},
},
ResourceType = "string",
UpdateTime = 0,
});
example, err := databricks.NewBudget(ctx, "budgetResource", &databricks.BudgetArgs{
AccountId: pulumi.String("string"),
AlertConfigurations: databricks.BudgetAlertConfigurationArray{
&databricks.BudgetAlertConfigurationArgs{
ActionConfigurations: databricks.BudgetAlertConfigurationActionConfigurationArray{
&databricks.BudgetAlertConfigurationActionConfigurationArgs{
ActionConfigurationId: pulumi.String("string"),
ActionType: pulumi.String("string"),
Target: pulumi.String("string"),
},
},
AlertConfigurationId: pulumi.String("string"),
PrincipalOverrides: databricks.BudgetAlertConfigurationPrincipalOverrideArray{
&databricks.BudgetAlertConfigurationPrincipalOverrideArgs{
OverrideThreshold: pulumi.String("string"),
PrincipalId: pulumi.String("string"),
},
},
QuantityThreshold: pulumi.String("string"),
QuantityType: pulumi.String("string"),
ScopeType: pulumi.String("string"),
TimePeriod: pulumi.String("string"),
TriggerType: pulumi.String("string"),
},
},
BudgetConfigurationId: pulumi.String("string"),
CreateTime: pulumi.Int(0),
DisplayName: pulumi.String("string"),
Filter: &databricks.BudgetFilterArgs{
Tags: databricks.BudgetFilterTagArray{
&databricks.BudgetFilterTagArgs{
Key: pulumi.String("string"),
Value: &databricks.BudgetFilterTagValueArgs{
Operator: pulumi.String("string"),
Values: pulumi.StringArray{
pulumi.String("string"),
},
},
},
},
WorkspaceId: &databricks.BudgetFilterWorkspaceIdArgs{
Operator: pulumi.String("string"),
Values: pulumi.IntArray{
pulumi.Int(0),
},
},
},
ResourceType: pulumi.String("string"),
UpdateTime: pulumi.Int(0),
})
resource "databricks_budget" "budgetResource" {
lifecycle {
create_before_destroy = true
}
account_id = "string"
alert_configurations {
action_configurations {
action_configuration_id = "string"
action_type = "string"
target = "string"
}
alert_configuration_id = "string"
principal_overrides {
override_threshold = "string"
principal_id = "string"
}
quantity_threshold = "string"
quantity_type = "string"
scope_type = "string"
time_period = "string"
trigger_type = "string"
}
budget_configuration_id = "string"
create_time = 0
display_name = "string"
filter = {
tags = [{
key = "string"
value = {
operator = "string"
values = ["string"]
}
}]
workspace_id = {
operator = "string"
values = [0]
}
}
resource_type = "string"
update_time = 0
}
var budgetResource = new Budget("budgetResource", BudgetArgs.builder()
.accountId("string")
.alertConfigurations(BudgetAlertConfigurationArgs.builder()
.actionConfigurations(BudgetAlertConfigurationActionConfigurationArgs.builder()
.actionConfigurationId("string")
.actionType("string")
.target("string")
.build())
.alertConfigurationId("string")
.principalOverrides(BudgetAlertConfigurationPrincipalOverrideArgs.builder()
.overrideThreshold("string")
.principalId("string")
.build())
.quantityThreshold("string")
.quantityType("string")
.scopeType("string")
.timePeriod("string")
.triggerType("string")
.build())
.budgetConfigurationId("string")
.createTime(0)
.displayName("string")
.filter(BudgetFilterArgs.builder()
.tags(BudgetFilterTagArgs.builder()
.key("string")
.value(BudgetFilterTagValueArgs.builder()
.operator("string")
.values("string")
.build())
.build())
.workspaceId(BudgetFilterWorkspaceIdArgs.builder()
.operator("string")
.values(0)
.build())
.build())
.resourceType("string")
.updateTime(0)
.build());
budget_resource = databricks.Budget("budgetResource",
account_id="string",
alert_configurations=[{
"action_configurations": [{
"action_configuration_id": "string",
"action_type": "string",
"target": "string",
}],
"alert_configuration_id": "string",
"principal_overrides": [{
"override_threshold": "string",
"principal_id": "string",
}],
"quantity_threshold": "string",
"quantity_type": "string",
"scope_type": "string",
"time_period": "string",
"trigger_type": "string",
}],
budget_configuration_id="string",
create_time=0,
display_name="string",
filter={
"tags": [{
"key": "string",
"value": {
"operator": "string",
"values": ["string"],
},
}],
"workspace_id": {
"operator": "string",
"values": [0],
},
},
resource_type="string",
update_time=0)
const budgetResource = new databricks.Budget("budgetResource", {
accountId: "string",
alertConfigurations: [{
actionConfigurations: [{
actionConfigurationId: "string",
actionType: "string",
target: "string",
}],
alertConfigurationId: "string",
principalOverrides: [{
overrideThreshold: "string",
principalId: "string",
}],
quantityThreshold: "string",
quantityType: "string",
scopeType: "string",
timePeriod: "string",
triggerType: "string",
}],
budgetConfigurationId: "string",
createTime: 0,
displayName: "string",
filter: {
tags: [{
key: "string",
value: {
operator: "string",
values: ["string"],
},
}],
workspaceId: {
operator: "string",
values: [0],
},
},
resourceType: "string",
updateTime: 0,
});
type: databricks:Budget
properties:
accountId: string
alertConfigurations:
- actionConfigurations:
- actionConfigurationId: string
actionType: string
target: string
alertConfigurationId: string
principalOverrides:
- overrideThreshold: string
principalId: string
quantityThreshold: string
quantityType: string
scopeType: string
timePeriod: string
triggerType: string
budgetConfigurationId: string
createTime: 0
displayName: string
filter:
tags:
- key: string
value:
operator: string
values:
- string
workspaceId:
operator: string
values:
- 0
resourceType: string
updateTime: 0
Budget 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 Budget resource accepts the following input properties:
- Account
Id string - The ID of the Databricks Account.
- Alert
Configurations List<BudgetAlert Configuration> - Budget
Configuration stringId - The ID of the budget configuration.
- Create
Time int - Display
Name string - Name of the budget in Databricks Account.
- Filter
Budget
Filter - Resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - Update
Time int
- Account
Id string - The ID of the Databricks Account.
- Alert
Configurations []BudgetAlert Configuration Args - Budget
Configuration stringId - The ID of the budget configuration.
- Create
Time int - Display
Name string - Name of the budget in Databricks Account.
- Filter
Budget
Filter Args - Resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - Update
Time int
- account_
id string - The ID of the Databricks Account.
- alert_
configurations list(object) - budget_
configuration_ stringid - The ID of the budget configuration.
- create_
time number - display_
name string - Name of the budget in Databricks Account.
- filter object
- resource_
type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update_
time number
- account
Id String - The ID of the Databricks Account.
- alert
Configurations List<BudgetAlert Configuration> - budget
Configuration StringId - The ID of the budget configuration.
- create
Time Integer - display
Name String - Name of the budget in Databricks Account.
- filter
Budget
Filter - resource
Type String - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time Integer
- account
Id string - The ID of the Databricks Account.
- alert
Configurations BudgetAlert Configuration[] - budget
Configuration stringId - The ID of the budget configuration.
- create
Time number - display
Name string - Name of the budget in Databricks Account.
- filter
Budget
Filter - resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time number
- account_
id str - The ID of the Databricks Account.
- alert_
configurations Sequence[BudgetAlert Configuration Args] - budget_
configuration_ strid - The ID of the budget configuration.
- create_
time int - display_
name str - Name of the budget in Databricks Account.
- filter
Budget
Filter Args - resource_
type str - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update_
time int
- account
Id String - The ID of the Databricks Account.
- alert
Configurations List<Property Map> - budget
Configuration StringId - The ID of the budget configuration.
- create
Time Number - display
Name String - Name of the budget in Databricks Account.
- filter Property Map
- resource
Type String - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time Number
Outputs
All input properties are implicitly available as output properties. Additionally, the Budget resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Budget Resource
Get an existing Budget 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?: BudgetState, opts?: CustomResourceOptions): Budget@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
alert_configurations: Optional[Sequence[BudgetAlertConfigurationArgs]] = None,
budget_configuration_id: Optional[str] = None,
create_time: Optional[int] = None,
display_name: Optional[str] = None,
filter: Optional[BudgetFilterArgs] = None,
resource_type: Optional[str] = None,
update_time: Optional[int] = None) -> Budgetfunc GetBudget(ctx *Context, name string, id IDInput, state *BudgetState, opts ...ResourceOption) (*Budget, error)public static Budget Get(string name, Input<string> id, BudgetState? state, CustomResourceOptions? opts = null)public static Budget get(String name, Output<String> id, BudgetState state, CustomResourceOptions options)resources: _: type: databricks:Budget get: id: ${id}import {
to = databricks_budget.example
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.
- Account
Id string - The ID of the Databricks Account.
- Alert
Configurations List<BudgetAlert Configuration> - Budget
Configuration stringId - The ID of the budget configuration.
- Create
Time int - Display
Name string - Name of the budget in Databricks Account.
- Filter
Budget
Filter - Resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - Update
Time int
- Account
Id string - The ID of the Databricks Account.
- Alert
Configurations []BudgetAlert Configuration Args - Budget
Configuration stringId - The ID of the budget configuration.
- Create
Time int - Display
Name string - Name of the budget in Databricks Account.
- Filter
Budget
Filter Args - Resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - Update
Time int
- account_
id string - The ID of the Databricks Account.
- alert_
configurations list(object) - budget_
configuration_ stringid - The ID of the budget configuration.
- create_
time number - display_
name string - Name of the budget in Databricks Account.
- filter object
- resource_
type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update_
time number
- account
Id String - The ID of the Databricks Account.
- alert
Configurations List<BudgetAlert Configuration> - budget
Configuration StringId - The ID of the budget configuration.
- create
Time Integer - display
Name String - Name of the budget in Databricks Account.
- filter
Budget
Filter - resource
Type String - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time Integer
- account
Id string - The ID of the Databricks Account.
- alert
Configurations BudgetAlert Configuration[] - budget
Configuration stringId - The ID of the budget configuration.
- create
Time number - display
Name string - Name of the budget in Databricks Account.
- filter
Budget
Filter - resource
Type string - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time number
- account_
id str - The ID of the Databricks Account.
- alert_
configurations Sequence[BudgetAlert Configuration Args] - budget_
configuration_ strid - The ID of the budget configuration.
- create_
time int - display_
name str - Name of the budget in Databricks Account.
- filter
Budget
Filter Args - resource_
type str - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update_
time int
- account
Id String - The ID of the Databricks Account.
- alert
Configurations List<Property Map> - budget
Configuration StringId - The ID of the budget configuration.
- create
Time Number - display
Name String - Name of the budget in Databricks Account.
- filter Property Map
- resource
Type String - The resource scope for this budget. Determines whether the budget tracks all resources or a specific resource. (Enum:
BUDGET_RESOURCE_TYPE_ALL_RESOURCES,BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY) - update
Time Number
Supporting Types
BudgetAlertConfiguration, BudgetAlertConfigurationArgs
- Action
Configurations List<BudgetAlert Configuration Action Configuration> - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- Alert
Configuration stringId - Principal
Overrides List<BudgetAlert Configuration Principal Override> - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - Quantity
Threshold string - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - Quantity
Type string - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - Scope
Type string - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - Time
Period string - The time window of usage data for the budget. (Enum:
MONTH) - Trigger
Type string - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- Action
Configurations []BudgetAlert Configuration Action Configuration - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- Alert
Configuration stringId - Principal
Overrides []BudgetAlert Configuration Principal Override - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - Quantity
Threshold string - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - Quantity
Type string - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - Scope
Type string - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - Time
Period string - The time window of usage data for the budget. (Enum:
MONTH) - Trigger
Type string - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- action_
configurations list(object) - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- alert_
configuration_ stringid - principal_
overrides list(object) - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - quantity_
threshold string - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - quantity_
type string - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - scope_
type string - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - time_
period string - The time window of usage data for the budget. (Enum:
MONTH) - trigger_
type string - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- action
Configurations List<BudgetAlert Configuration Action Configuration> - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- alert
Configuration StringId - principal
Overrides List<BudgetAlert Configuration Principal Override> - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - quantity
Threshold String - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - quantity
Type String - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - scope
Type String - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - time
Period String - The time window of usage data for the budget. (Enum:
MONTH) - trigger
Type String - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- action
Configurations BudgetAlert Configuration Action Configuration[] - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- alert
Configuration stringId - principal
Overrides BudgetAlert Configuration Principal Override[] - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - quantity
Threshold string - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - quantity
Type string - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - scope
Type string - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - time
Period string - The time window of usage data for the budget. (Enum:
MONTH) - trigger
Type string - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- action_
configurations Sequence[BudgetAlert Configuration Action Configuration] - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- alert_
configuration_ strid - principal_
overrides Sequence[BudgetAlert Configuration Principal Override] - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - quantity_
threshold str - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - quantity_
type str - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - scope_
type str - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - time_
period str - The time window of usage data for the budget. (Enum:
MONTH) - trigger_
type str - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
- action
Configurations List<Property Map> - List of action configurations to take when the budget alert is triggered. Consists of the following fields:
- alert
Configuration StringId - principal
Overrides List<Property Map> - Per-principal threshold overrides for this alert. Only applies to per-user alerts (
scopeType=ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER); ignored for shared alerts. Consists of the following fields: - quantity
Threshold String - The threshold for the budget alert to determine if it is in a triggered state. The number is evaluated based on
quantityType. - quantity
Type String - The way to calculate cost for this budget alert. This is what quantityThreshold is measured in. (Enum:
LIST_PRICE_DOLLARS_USD) - scope
Type String - How the alert threshold is evaluated. Determines whether spend is tracked in aggregate or per individual user. (Enum:
ALERT_CONFIGURATION_SCOPE_TYPE_SHARED,ALERT_CONFIGURATION_SCOPE_TYPE_PER_USER) - time
Period String - The time window of usage data for the budget. (Enum:
MONTH) - trigger
Type String - The evaluation method to determine when this budget alert is in a triggered state. (Enum:
CUMULATIVE_SPENDING_EXCEEDED)
BudgetAlertConfigurationActionConfiguration, BudgetAlertConfigurationActionConfigurationArgs
- Action
Configuration stringId - Action
Type string - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - Target string
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- Action
Configuration stringId - Action
Type string - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - Target string
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- action_
configuration_ stringid - action_
type string - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - target string
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- action
Configuration StringId - action
Type String - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - target String
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- action
Configuration stringId - action
Type string - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - target string
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- action_
configuration_ strid - action_
type str - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - target str
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
- action
Configuration StringId - action
Type String - The type of action to take when the budget alert is triggered. (Enum:
EMAIL_NOTIFICATION,BLOCK_USAGE). Note:BLOCK_USAGEaction type is only supported on AI Gateway-scoped budgets. - target String
- For
EMAIL_NOTIFICATIONaction type, this is the email address to send the notification to. Required if theactionTypeisEMAIL_NOTIFICATION. Does not apply to theBLOCK_USAGEaction type, and this field must be omitted in that case.
BudgetAlertConfigurationPrincipalOverride, BudgetAlertConfigurationPrincipalOverrideArgs
- Override
Threshold string - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - Principal
Id string - Account-level principal id (user, group, or service principal).
- Override
Threshold string - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - Principal
Id string - Account-level principal id (user, group, or service principal).
- override_
threshold string - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - principal_
id string - Account-level principal id (user, group, or service principal).
- override
Threshold String - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - principal
Id String - Account-level principal id (user, group, or service principal).
- override
Threshold string - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - principal
Id string - Account-level principal id (user, group, or service principal).
- override_
threshold str - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - principal_
id str - Account-level principal id (user, group, or service principal).
- override
Threshold String - Dollar amount that overrides the parent alert's
quantityThresholdfor this principal. - principal
Id String - Account-level principal id (user, group, or service principal).
BudgetFilter, BudgetFilterArgs
-
List<Budget
Filter Tag> - List of tags to filter by. Consists of the following fields:
- Workspace
Id BudgetFilter Workspace Id - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
-
[]Budget
Filter Tag - List of tags to filter by. Consists of the following fields:
- Workspace
Id BudgetFilter Workspace Id - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
- list(object)
- List of tags to filter by. Consists of the following fields:
- workspace_
id object - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
-
List<Budget
Filter Tag> - List of tags to filter by. Consists of the following fields:
- workspace
Id BudgetFilter Workspace Id - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
-
Budget
Filter Tag[] - List of tags to filter by. Consists of the following fields:
- workspace
Id BudgetFilter Workspace Id - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
-
Sequence[Budget
Filter Tag] - List of tags to filter by. Consists of the following fields:
- workspace_
id BudgetFilter Workspace Id - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
- List<Property Map>
- List of tags to filter by. Consists of the following fields:
- workspace
Id Property Map - Filter by workspace ID (if empty, include usage all usage for this account). Consists of the following fields:
BudgetFilterTag, BudgetFilterTagArgs
- Key string
- The key of the tag.
- Value
Budget
Filter Tag Value - Consists of the following fields:
- Key string
- The key of the tag.
- Value
Budget
Filter Tag Value - Consists of the following fields:
- key String
- The key of the tag.
- value
Budget
Filter Tag Value - Consists of the following fields:
- key string
- The key of the tag.
- value
Budget
Filter Tag Value - Consists of the following fields:
- key str
- The key of the tag.
- value
Budget
Filter Tag Value - Consists of the following fields:
- key String
- The key of the tag.
- value Property Map
- Consists of the following fields:
BudgetFilterTagValue, BudgetFilterTagValueArgs
BudgetFilterWorkspaceId, BudgetFilterWorkspaceIdArgs
Package Details
- Repository
- databricks pulumi/pulumi-databricks
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
databricksTerraform Provider.
published on Tuesday, Sep 8, 2026 by Pulumi