1. Packages
  2. Vantage Provider
  3. API Docs
  4. Budget
vantage 0.1.50 published on Monday, Apr 7, 2025 by vantage-sh

vantage.Budget

Explore with Pulumi AI

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as vantage from "@pulumi/vantage";

const demoBudget = new vantage.Budget("demoBudget", {
    costReportToken: vantage_cost_report.demo_report.token,
    periods: [{
        startAt: "2023-12-01",
        endAt: "2024-01-01",
        amount: 1000,
    }],
});
Copy
import pulumi
import pulumi_vantage as vantage

demo_budget = vantage.Budget("demoBudget",
    cost_report_token=vantage_cost_report["demo_report"]["token"],
    periods=[{
        "start_at": "2023-12-01",
        "end_at": "2024-01-01",
        "amount": 1000,
    }])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vantage/vantage"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := vantage.NewBudget(ctx, "demoBudget", &vantage.BudgetArgs{
			CostReportToken: pulumi.Any(vantage_cost_report.Demo_report.Token),
			Periods: vantage.BudgetPeriodArray{
				&vantage.BudgetPeriodArgs{
					StartAt: pulumi.String("2023-12-01"),
					EndAt:   pulumi.String("2024-01-01"),
					Amount:  pulumi.Float64(1000),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vantage = Pulumi.Vantage;

return await Deployment.RunAsync(() => 
{
    var demoBudget = new Vantage.Budget("demoBudget", new()
    {
        CostReportToken = vantage_cost_report.Demo_report.Token,
        Periods = new[]
        {
            new Vantage.Inputs.BudgetPeriodArgs
            {
                StartAt = "2023-12-01",
                EndAt = "2024-01-01",
                Amount = 1000,
            },
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vantage.Budget;
import com.pulumi.vantage.BudgetArgs;
import com.pulumi.vantage.inputs.BudgetPeriodArgs;
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) {
        var demoBudget = new Budget("demoBudget", BudgetArgs.builder()
            .costReportToken(vantage_cost_report.demo_report().token())
            .periods(BudgetPeriodArgs.builder()
                .startAt("2023-12-01")
                .endAt("2024-01-01")
                .amount(1000)
                .build())
            .build());

    }
}
Copy
resources:
  demoBudget:
    type: vantage:Budget
    properties:
      costReportToken: ${vantage_cost_report.demo_report.token}
      periods:
        - startAt: 2023-12-01
          endAt: 2024-01-01
          amount: 1000
Copy

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,
           child_budget_tokens: Optional[Sequence[str]] = None,
           cost_report_token: Optional[str] = None,
           name: Optional[str] = None,
           periods: Optional[Sequence[BudgetPeriodArgs]] = None,
           workspace_token: Optional[str] = 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: vantage:Budget
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. 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 This property is required. 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 This property is required. 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 This property is required. 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 This property is required. String
The unique name of the resource.
args This property is required. 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 Vantage.Budget("budgetResource", new()
{
    ChildBudgetTokens = new[]
    {
        "string",
    },
    CostReportToken = "string",
    Name = "string",
    Periods = new[]
    {
        new Vantage.Inputs.BudgetPeriodArgs
        {
            Amount = 0,
            StartAt = "string",
            EndAt = "string",
        },
    },
    WorkspaceToken = "string",
});
Copy
example, err := vantage.NewBudget(ctx, "budgetResource", &vantage.BudgetArgs{
ChildBudgetTokens: pulumi.StringArray{
pulumi.String("string"),
},
CostReportToken: pulumi.String("string"),
Name: pulumi.String("string"),
Periods: .BudgetPeriodArray{
&.BudgetPeriodArgs{
Amount: pulumi.Float64(0),
StartAt: pulumi.String("string"),
EndAt: pulumi.String("string"),
},
},
WorkspaceToken: pulumi.String("string"),
})
Copy
var budgetResource = new Budget("budgetResource", BudgetArgs.builder()
    .childBudgetTokens("string")
    .costReportToken("string")
    .name("string")
    .periods(BudgetPeriodArgs.builder()
        .amount(0)
        .startAt("string")
        .endAt("string")
        .build())
    .workspaceToken("string")
    .build());
Copy
budget_resource = vantage.Budget("budgetResource",
    child_budget_tokens=["string"],
    cost_report_token="string",
    name="string",
    periods=[{
        "amount": 0,
        "start_at": "string",
        "end_at": "string",
    }],
    workspace_token="string")
Copy
const budgetResource = new vantage.Budget("budgetResource", {
    childBudgetTokens: ["string"],
    costReportToken: "string",
    name: "string",
    periods: [{
        amount: 0,
        startAt: "string",
        endAt: "string",
    }],
    workspaceToken: "string",
});
Copy
type: vantage:Budget
properties:
    childBudgetTokens:
        - string
    costReportToken: string
    name: string
    periods:
        - amount: 0
          endAt: string
          startAt: string
    workspaceToken: string
Copy

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:

ChildBudgetTokens List<string>
The tokens of any child Budgets when creating a hierarchical Budget.
CostReportToken string
The CostReport token. Ignored for hierarchical Budgets.
Name string
The name of the Budget.
Periods List<BudgetPeriod>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
WorkspaceToken string
The token of the Workspace to add the Budget to.
ChildBudgetTokens []string
The tokens of any child Budgets when creating a hierarchical Budget.
CostReportToken string
The CostReport token. Ignored for hierarchical Budgets.
Name string
The name of the Budget.
Periods []BudgetPeriodArgs
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
WorkspaceToken string
The token of the Workspace to add the Budget to.
childBudgetTokens List<String>
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken String
The CostReport token. Ignored for hierarchical Budgets.
name String
The name of the Budget.
periods List<BudgetPeriod>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
workspaceToken String
The token of the Workspace to add the Budget to.
childBudgetTokens string[]
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken string
The CostReport token. Ignored for hierarchical Budgets.
name string
The name of the Budget.
periods BudgetPeriod[]
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
workspaceToken string
The token of the Workspace to add the Budget to.
child_budget_tokens Sequence[str]
The tokens of any child Budgets when creating a hierarchical Budget.
cost_report_token str
The CostReport token. Ignored for hierarchical Budgets.
name str
The name of the Budget.
periods Sequence[BudgetPeriodArgs]
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
workspace_token str
The token of the Workspace to add the Budget to.
childBudgetTokens List<String>
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken String
The CostReport token. Ignored for hierarchical Budgets.
name String
The name of the Budget.
periods List<Property Map>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
workspaceToken String
The token of the Workspace to add the Budget to.

Outputs

All input properties are implicitly available as output properties. Additionally, the Budget resource produces the following output properties:

BudgetAlertTokens List<string>
The tokens of the BudgetAlerts associated with the Budget.
CreatedAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
CreatedByToken string
The token of the Creator of the Budget.
Id string
The provider-assigned unique ID for this managed resource.
Performances List<BudgetPerformance>
The historical performance of the Budget.
Token string
The token of the budget
UserToken string
The token for the User who created this Budget.
BudgetAlertTokens []string
The tokens of the BudgetAlerts associated with the Budget.
CreatedAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
CreatedByToken string
The token of the Creator of the Budget.
Id string
The provider-assigned unique ID for this managed resource.
Performances []BudgetPerformance
The historical performance of the Budget.
Token string
The token of the budget
UserToken string
The token for the User who created this Budget.
budgetAlertTokens List<String>
The tokens of the BudgetAlerts associated with the Budget.
createdAt String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken String
The token of the Creator of the Budget.
id String
The provider-assigned unique ID for this managed resource.
performances List<BudgetPerformance>
The historical performance of the Budget.
token String
The token of the budget
userToken String
The token for the User who created this Budget.
budgetAlertTokens string[]
The tokens of the BudgetAlerts associated with the Budget.
createdAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken string
The token of the Creator of the Budget.
id string
The provider-assigned unique ID for this managed resource.
performances BudgetPerformance[]
The historical performance of the Budget.
token string
The token of the budget
userToken string
The token for the User who created this Budget.
budget_alert_tokens Sequence[str]
The tokens of the BudgetAlerts associated with the Budget.
created_at str
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
created_by_token str
The token of the Creator of the Budget.
id str
The provider-assigned unique ID for this managed resource.
performances Sequence[BudgetPerformance]
The historical performance of the Budget.
token str
The token of the budget
user_token str
The token for the User who created this Budget.
budgetAlertTokens List<String>
The tokens of the BudgetAlerts associated with the Budget.
createdAt String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken String
The token of the Creator of the Budget.
id String
The provider-assigned unique ID for this managed resource.
performances List<Property Map>
The historical performance of the Budget.
token String
The token of the budget
userToken String
The token for the User who created this Budget.

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,
        budget_alert_tokens: Optional[Sequence[str]] = None,
        child_budget_tokens: Optional[Sequence[str]] = None,
        cost_report_token: Optional[str] = None,
        created_at: Optional[str] = None,
        created_by_token: Optional[str] = None,
        name: Optional[str] = None,
        performances: Optional[Sequence[BudgetPerformanceArgs]] = None,
        periods: Optional[Sequence[BudgetPeriodArgs]] = None,
        token: Optional[str] = None,
        user_token: Optional[str] = None,
        workspace_token: Optional[str] = None) -> Budget
func 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: vantage:Budget    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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.
The following state arguments are supported:
BudgetAlertTokens List<string>
The tokens of the BudgetAlerts associated with the Budget.
ChildBudgetTokens List<string>
The tokens of any child Budgets when creating a hierarchical Budget.
CostReportToken string
The CostReport token. Ignored for hierarchical Budgets.
CreatedAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
CreatedByToken string
The token of the Creator of the Budget.
Name string
The name of the Budget.
Performances List<BudgetPerformance>
The historical performance of the Budget.
Periods List<BudgetPeriod>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
Token string
The token of the budget
UserToken string
The token for the User who created this Budget.
WorkspaceToken string
The token of the Workspace to add the Budget to.
BudgetAlertTokens []string
The tokens of the BudgetAlerts associated with the Budget.
ChildBudgetTokens []string
The tokens of any child Budgets when creating a hierarchical Budget.
CostReportToken string
The CostReport token. Ignored for hierarchical Budgets.
CreatedAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
CreatedByToken string
The token of the Creator of the Budget.
Name string
The name of the Budget.
Performances []BudgetPerformanceArgs
The historical performance of the Budget.
Periods []BudgetPeriodArgs
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
Token string
The token of the budget
UserToken string
The token for the User who created this Budget.
WorkspaceToken string
The token of the Workspace to add the Budget to.
budgetAlertTokens List<String>
The tokens of the BudgetAlerts associated with the Budget.
childBudgetTokens List<String>
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken String
The CostReport token. Ignored for hierarchical Budgets.
createdAt String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken String
The token of the Creator of the Budget.
name String
The name of the Budget.
performances List<BudgetPerformance>
The historical performance of the Budget.
periods List<BudgetPeriod>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
token String
The token of the budget
userToken String
The token for the User who created this Budget.
workspaceToken String
The token of the Workspace to add the Budget to.
budgetAlertTokens string[]
The tokens of the BudgetAlerts associated with the Budget.
childBudgetTokens string[]
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken string
The CostReport token. Ignored for hierarchical Budgets.
createdAt string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken string
The token of the Creator of the Budget.
name string
The name of the Budget.
performances BudgetPerformance[]
The historical performance of the Budget.
periods BudgetPeriod[]
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
token string
The token of the budget
userToken string
The token for the User who created this Budget.
workspaceToken string
The token of the Workspace to add the Budget to.
budget_alert_tokens Sequence[str]
The tokens of the BudgetAlerts associated with the Budget.
child_budget_tokens Sequence[str]
The tokens of any child Budgets when creating a hierarchical Budget.
cost_report_token str
The CostReport token. Ignored for hierarchical Budgets.
created_at str
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
created_by_token str
The token of the Creator of the Budget.
name str
The name of the Budget.
performances Sequence[BudgetPerformanceArgs]
The historical performance of the Budget.
periods Sequence[BudgetPeriodArgs]
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
token str
The token of the budget
user_token str
The token for the User who created this Budget.
workspace_token str
The token of the Workspace to add the Budget to.
budgetAlertTokens List<String>
The tokens of the BudgetAlerts associated with the Budget.
childBudgetTokens List<String>
The tokens of any child Budgets when creating a hierarchical Budget.
costReportToken String
The CostReport token. Ignored for hierarchical Budgets.
createdAt String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
createdByToken String
The token of the Creator of the Budget.
name String
The name of the Budget.
performances List<Property Map>
The historical performance of the Budget.
periods List<Property Map>
The periods for the Budget. The startat and endat must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.
token String
The token of the budget
userToken String
The token for the User who created this Budget.
workspaceToken String
The token of the Workspace to add the Budget to.

Supporting Types

BudgetPerformance
, BudgetPerformanceArgs

Actual string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
Amount string
The amount of the Budget Period as a string to ensure precision.
Date string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
Actual string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
Amount string
The amount of the Budget Period as a string to ensure precision.
Date string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
actual String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
amount String
The amount of the Budget Period as a string to ensure precision.
date String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
actual string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
amount string
The amount of the Budget Period as a string to ensure precision.
date string
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
actual str
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
amount str
The amount of the Budget Period as a string to ensure precision.
date str
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
actual String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.
amount String
The amount of the Budget Period as a string to ensure precision.
date String
The date and time, in UTC, the Budget was created. ISO 8601 Formatted.

BudgetPeriod
, BudgetPeriodArgs

Amount This property is required. double
The amount of the period.
StartAt This property is required. string
The start date of the period.
EndAt string
The end date of the period.
Amount This property is required. float64
The amount of the period.
StartAt This property is required. string
The start date of the period.
EndAt string
The end date of the period.
amount This property is required. Double
The amount of the period.
startAt This property is required. String
The start date of the period.
endAt String
The end date of the period.
amount This property is required. number
The amount of the period.
startAt This property is required. string
The start date of the period.
endAt string
The end date of the period.
amount This property is required. float
The amount of the period.
start_at This property is required. str
The start date of the period.
end_at str
The end date of the period.
amount This property is required. Number
The amount of the period.
startAt This property is required. String
The start date of the period.
endAt String
The end date of the period.

Package Details

Repository
vantage vantage-sh/terraform-provider-vantage
License
Notes
This Pulumi package is based on the vantage Terraform Provider.