Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.azure.consumption.kotlin.BudgetSubscriptionArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.consumption.kotlin
import com.pulumi.azure.consumption.BudgetSubscriptionArgs.builder
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionFilterArgs
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionFilterArgsBuilder
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionNotificationArgs
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionNotificationArgsBuilder
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionTimePeriodArgs
import com.pulumi.azure.consumption.kotlin.inputs.BudgetSubscriptionTimePeriodArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Double
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* Manages a Subscription Consumption Budget.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azure from "@pulumi/azure";
* const current = azure.core.getSubscription({});
* const example = new azure.core.ResourceGroup("example", {
* name: "example",
* location: "eastus",
* });
* const exampleActionGroup = new azure.monitoring.ActionGroup("example", {
* name: "example",
* resourceGroupName: example.name,
* shortName: "example",
* });
* const exampleBudgetSubscription = new azure.consumption.BudgetSubscription("example", {
* name: "example",
* subscriptionId: current.then(current => current.id),
* amount: 1000,
* timeGrain: "Monthly",
* timePeriod: {
* startDate: "2022-06-01T00:00:00Z",
* endDate: "2022-07-01T00:00:00Z",
* },
* filter: {
* dimensions: [{
* name: "ResourceGroupName",
* values: [example.name],
* }],
* tags: [{
* name: "foo",
* values: [
* "bar",
* "baz",
* ],
* }],
* },
* notifications: [
* {
* enabled: true,
* threshold: 90,
* operator: "EqualTo",
* contactEmails: [
* "[email protected] ",
* "[email protected] ",
* ],
* contactGroups: [exampleActionGroup.id],
* contactRoles: ["Owner"],
* },
* {
* enabled: false,
* threshold: 100,
* operator: "GreaterThan",
* thresholdType: "Forecasted",
* contactEmails: [
* "[email protected] ",
* "[email protected] ",
* ],
* },
* ],
* });
* ```
* ```python
* import pulumi
* import pulumi_azure as azure
* current = azure.core.get_subscription()
* example = azure.core.ResourceGroup("example",
* name="example",
* location="eastus")
* example_action_group = azure.monitoring.ActionGroup("example",
* name="example",
* resource_group_name=example.name,
* short_name="example")
* example_budget_subscription = azure.consumption.BudgetSubscription("example",
* name="example",
* subscription_id=current.id,
* amount=1000,
* time_grain="Monthly",
* time_period={
* "start_date": "2022-06-01T00:00:00Z",
* "end_date": "2022-07-01T00:00:00Z",
* },
* filter={
* "dimensions": [{
* "name": "ResourceGroupName",
* "values": [example.name],
* }],
* "tags": [{
* "name": "foo",
* "values": [
* "bar",
* "baz",
* ],
* }],
* },
* notifications=[
* {
* "enabled": True,
* "threshold": 90,
* "operator": "EqualTo",
* "contact_emails": [
* "[email protected] ",
* "[email protected] ",
* ],
* "contact_groups": [example_action_group.id],
* "contact_roles": ["Owner"],
* },
* {
* "enabled": False,
* "threshold": 100,
* "operator": "GreaterThan",
* "threshold_type": "Forecasted",
* "contact_emails": [
* "[email protected] ",
* "[email protected] ",
* ],
* },
* ])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Azure = Pulumi.Azure;
* return await Deployment.RunAsync(() =>
* {
* var current = Azure.Core.GetSubscription.Invoke();
* var example = new Azure.Core.ResourceGroup("example", new()
* {
* Name = "example",
* Location = "eastus",
* });
* var exampleActionGroup = new Azure.Monitoring.ActionGroup("example", new()
* {
* Name = "example",
* ResourceGroupName = example.Name,
* ShortName = "example",
* });
* var exampleBudgetSubscription = new Azure.Consumption.BudgetSubscription("example", new()
* {
* Name = "example",
* SubscriptionId = current.Apply(getSubscriptionResult => getSubscriptionResult.Id),
* Amount = 1000,
* TimeGrain = "Monthly",
* TimePeriod = new Azure.Consumption.Inputs.BudgetSubscriptionTimePeriodArgs
* {
* StartDate = "2022-06-01T00:00:00Z",
* EndDate = "2022-07-01T00:00:00Z",
* },
* Filter = new Azure.Consumption.Inputs.BudgetSubscriptionFilterArgs
* {
* Dimensions = new[]
* {
* new Azure.Consumption.Inputs.BudgetSubscriptionFilterDimensionArgs
* {
* Name = "ResourceGroupName",
* Values = new[]
* {
* example.Name,
* },
* },
* },
* Tags = new[]
* {
* new Azure.Consumption.Inputs.BudgetSubscriptionFilterTagArgs
* {
* Name = "foo",
* Values = new[]
* {
* "bar",
* "baz",
* },
* },
* },
* },
* Notifications = new[]
* {
* new Azure.Consumption.Inputs.BudgetSubscriptionNotificationArgs
* {
* Enabled = true,
* Threshold = 90,
* Operator = "EqualTo",
* ContactEmails = new[]
* {
* "[email protected] ",
* "[email protected] ",
* },
* ContactGroups = new[]
* {
* exampleActionGroup.Id,
* },
* ContactRoles = new[]
* {
* "Owner",
* },
* },
* new Azure.Consumption.Inputs.BudgetSubscriptionNotificationArgs
* {
* Enabled = false,
* Threshold = 100,
* Operator = "GreaterThan",
* ThresholdType = "Forecasted",
* ContactEmails = new[]
* {
* "[email protected] ",
* "[email protected] ",
* },
* },
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/consumption"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/monitoring"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* current, err := core.LookupSubscription(ctx, nil, nil)
* if err != nil {
* return err
* }
* example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
* Name: pulumi.String("example"),
* Location: pulumi.String("eastus"),
* })
* if err != nil {
* return err
* }
* exampleActionGroup, err := monitoring.NewActionGroup(ctx, "example", &monitoring.ActionGroupArgs{
* Name: pulumi.String("example"),
* ResourceGroupName: example.Name,
* ShortName: pulumi.String("example"),
* })
* if err != nil {
* return err
* }
* _, err = consumption.NewBudgetSubscription(ctx, "example", &consumption.BudgetSubscriptionArgs{
* Name: pulumi.String("example"),
* SubscriptionId: pulumi.String(current.Id),
* Amount: pulumi.Float64(1000),
* TimeGrain: pulumi.String("Monthly"),
* TimePeriod: &consumption.BudgetSubscriptionTimePeriodArgs{
* StartDate: pulumi.String("2022-06-01T00:00:00Z"),
* EndDate: pulumi.String("2022-07-01T00:00:00Z"),
* },
* Filter: &consumption.BudgetSubscriptionFilterArgs{
* Dimensions: consumption.BudgetSubscriptionFilterDimensionArray{
* &consumption.BudgetSubscriptionFilterDimensionArgs{
* Name: pulumi.String("ResourceGroupName"),
* Values: pulumi.StringArray{
* example.Name,
* },
* },
* },
* Tags: consumption.BudgetSubscriptionFilterTagArray{
* &consumption.BudgetSubscriptionFilterTagArgs{
* Name: pulumi.String("foo"),
* Values: pulumi.StringArray{
* pulumi.String("bar"),
* pulumi.String("baz"),
* },
* },
* },
* },
* Notifications: consumption.BudgetSubscriptionNotificationArray{
* &consumption.BudgetSubscriptionNotificationArgs{
* Enabled: pulumi.Bool(true),
* Threshold: pulumi.Int(90),
* Operator: pulumi.String("EqualTo"),
* ContactEmails: pulumi.StringArray{
* pulumi.String("[email protected] "),
* pulumi.String("[email protected] "),
* },
* ContactGroups: pulumi.StringArray{
* exampleActionGroup.ID(),
* },
* ContactRoles: pulumi.StringArray{
* pulumi.String("Owner"),
* },
* },
* &consumption.BudgetSubscriptionNotificationArgs{
* Enabled: pulumi.Bool(false),
* Threshold: pulumi.Int(100),
* Operator: pulumi.String("GreaterThan"),
* ThresholdType: pulumi.String("Forecasted"),
* ContactEmails: pulumi.StringArray{
* pulumi.String("[email protected] "),
* pulumi.String("[email protected] "),
* },
* },
* },
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azure.core.CoreFunctions;
* import com.pulumi.azure.core.inputs.GetSubscriptionArgs;
* import com.pulumi.azure.core.ResourceGroup;
* import com.pulumi.azure.core.ResourceGroupArgs;
* import com.pulumi.azure.monitoring.ActionGroup;
* import com.pulumi.azure.monitoring.ActionGroupArgs;
* import com.pulumi.azure.consumption.BudgetSubscription;
* import com.pulumi.azure.consumption.BudgetSubscriptionArgs;
* import com.pulumi.azure.consumption.inputs.BudgetSubscriptionTimePeriodArgs;
* import com.pulumi.azure.consumption.inputs.BudgetSubscriptionFilterArgs;
* import com.pulumi.azure.consumption.inputs.BudgetSubscriptionNotificationArgs;
* 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) {
* final var current = CoreFunctions.getSubscription();
* var example = new ResourceGroup("example", ResourceGroupArgs.builder()
* .name("example")
* .location("eastus")
* .build());
* var exampleActionGroup = new ActionGroup("exampleActionGroup", ActionGroupArgs.builder()
* .name("example")
* .resourceGroupName(example.name())
* .shortName("example")
* .build());
* var exampleBudgetSubscription = new BudgetSubscription("exampleBudgetSubscription", BudgetSubscriptionArgs.builder()
* .name("example")
* .subscriptionId(current.applyValue(getSubscriptionResult -> getSubscriptionResult.id()))
* .amount(1000)
* .timeGrain("Monthly")
* .timePeriod(BudgetSubscriptionTimePeriodArgs.builder()
* .startDate("2022-06-01T00:00:00Z")
* .endDate("2022-07-01T00:00:00Z")
* .build())
* .filter(BudgetSubscriptionFilterArgs.builder()
* .dimensions(BudgetSubscriptionFilterDimensionArgs.builder()
* .name("ResourceGroupName")
* .values(example.name())
* .build())
* .tags(BudgetSubscriptionFilterTagArgs.builder()
* .name("foo")
* .values(
* "bar",
* "baz")
* .build())
* .build())
* .notifications(
* BudgetSubscriptionNotificationArgs.builder()
* .enabled(true)
* .threshold(90)
* .operator("EqualTo")
* .contactEmails(
* "[email protected] ",
* "[email protected] ")
* .contactGroups(exampleActionGroup.id())
* .contactRoles("Owner")
* .build(),
* BudgetSubscriptionNotificationArgs.builder()
* .enabled(false)
* .threshold(100)
* .operator("GreaterThan")
* .thresholdType("Forecasted")
* .contactEmails(
* "[email protected] ",
* "[email protected] ")
* .build())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: azure:core:ResourceGroup
* properties:
* name: example
* location: eastus
* exampleActionGroup:
* type: azure:monitoring:ActionGroup
* name: example
* properties:
* name: example
* resourceGroupName: ${example.name}
* shortName: example
* exampleBudgetSubscription:
* type: azure:consumption:BudgetSubscription
* name: example
* properties:
* name: example
* subscriptionId: ${current.id}
* amount: 1000
* timeGrain: Monthly
* timePeriod:
* startDate: 2022-06-01T00:00:00Z
* endDate: 2022-07-01T00:00:00Z
* filter:
* dimensions:
* - name: ResourceGroupName
* values:
* - ${example.name}
* tags:
* - name: foo
* values:
* - bar
* - baz
* notifications:
* - enabled: true
* threshold: 90
* operator: EqualTo
* contactEmails:
* - [email protected]
* - [email protected]
* contactGroups:
* - ${exampleActionGroup.id}
* contactRoles:
* - Owner
* - enabled: false
* threshold: 100
* operator: GreaterThan
* thresholdType: Forecasted
* contactEmails:
* - [email protected]
* - [email protected]
* variables:
* current:
* fn::invoke:
* Function: azure:core:getSubscription
* Arguments: {}
* ```
*
* ## Import
* Subscription Consumption Budgets can be imported using the `resource id`, e.g.
* ```sh
* $ pulumi import azure:consumption/budgetSubscription:BudgetSubscription example /subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Consumption/budgets/subscription1
* ```
* @property amount The total amount of cost to track with the budget.
* @property etag (Optional) The ETag of the Subscription Consumption Budget.
* @property filter A `filter` block as defined below.
* @property name The name which should be used for this Subscription Consumption Budget. Changing this forces a new resource to be created.
* @property notifications One or more `notification` blocks as defined below.
* @property subscriptionId The ID of the Subscription for which to create a Consumption Budget. Changing this forces a new resource to be created.
* > **NOTE:** The `subscription_id` property can accept a subscription ID e.g. `00000000-0000-0000-0000-000000000000` or the subscription resource ID e.g. `/subscriptions/00000000-0000-0000-0000-000000000000`. In version 3.0 this property will only accept the subscription resource ID.
* @property timeGrain The time covered by a budget. Tracking of the amount will be reset based on the time grain. Must be one of `BillingAnnual`, `BillingMonth`, `BillingQuarter`, `Annually`, `Monthly` and `Quarterly`. Defaults to `Monthly`. Changing this forces a new resource to be created.
* @property timePeriod A `time_period` block as defined below.
*/
public data class BudgetSubscriptionArgs(
public val amount: Output? = null,
public val etag: Output? = null,
public val filter: Output? = null,
public val name: Output? = null,
public val notifications: Output>? = null,
public val subscriptionId: Output? = null,
public val timeGrain: Output? = null,
public val timePeriod: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azure.consumption.BudgetSubscriptionArgs =
com.pulumi.azure.consumption.BudgetSubscriptionArgs.builder()
.amount(amount?.applyValue({ args0 -> args0 }))
.etag(etag?.applyValue({ args0 -> args0 }))
.filter(filter?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.name(name?.applyValue({ args0 -> args0 }))
.notifications(
notifications?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
)
.subscriptionId(subscriptionId?.applyValue({ args0 -> args0 }))
.timeGrain(timeGrain?.applyValue({ args0 -> args0 }))
.timePeriod(timePeriod?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}
/**
* Builder for [BudgetSubscriptionArgs].
*/
@PulumiTagMarker
public class BudgetSubscriptionArgsBuilder internal constructor() {
private var amount: Output? = null
private var etag: Output? = null
private var filter: Output? = null
private var name: Output? = null
private var notifications: Output>? = null
private var subscriptionId: Output? = null
private var timeGrain: Output? = null
private var timePeriod: Output? = null
/**
* @param value The total amount of cost to track with the budget.
*/
@JvmName("mjippsbfgcwyekso")
public suspend fun amount(`value`: Output) {
this.amount = value
}
/**
* @param value (Optional) The ETag of the Subscription Consumption Budget.
*/
@JvmName("wonbwubbchkckcxq")
public suspend fun etag(`value`: Output) {
this.etag = value
}
/**
* @param value A `filter` block as defined below.
*/
@JvmName("eiqcxeqkhrawjfwj")
public suspend fun filter(`value`: Output) {
this.filter = value
}
/**
* @param value The name which should be used for this Subscription Consumption Budget. Changing this forces a new resource to be created.
*/
@JvmName("qrhmoldovnxhmgqg")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value One or more `notification` blocks as defined below.
*/
@JvmName("cveyfcdofxjkmqta")
public suspend fun notifications(`value`: Output>) {
this.notifications = value
}
@JvmName("gnmkimtscuklmlpw")
public suspend fun notifications(vararg values: Output) {
this.notifications = Output.all(values.asList())
}
/**
* @param values One or more `notification` blocks as defined below.
*/
@JvmName("jbhjvwqbgywpvwyo")
public suspend fun notifications(values: List>) {
this.notifications = Output.all(values)
}
/**
* @param value The ID of the Subscription for which to create a Consumption Budget. Changing this forces a new resource to be created.
* > **NOTE:** The `subscription_id` property can accept a subscription ID e.g. `00000000-0000-0000-0000-000000000000` or the subscription resource ID e.g. `/subscriptions/00000000-0000-0000-0000-000000000000`. In version 3.0 this property will only accept the subscription resource ID.
*/
@JvmName("vsqxjjgxtwtwiiiv")
public suspend fun subscriptionId(`value`: Output) {
this.subscriptionId = value
}
/**
* @param value The time covered by a budget. Tracking of the amount will be reset based on the time grain. Must be one of `BillingAnnual`, `BillingMonth`, `BillingQuarter`, `Annually`, `Monthly` and `Quarterly`. Defaults to `Monthly`. Changing this forces a new resource to be created.
*/
@JvmName("ivaajvopeqergjcn")
public suspend fun timeGrain(`value`: Output) {
this.timeGrain = value
}
/**
* @param value A `time_period` block as defined below.
*/
@JvmName("akkbmnfhatixtkof")
public suspend fun timePeriod(`value`: Output) {
this.timePeriod = value
}
/**
* @param value The total amount of cost to track with the budget.
*/
@JvmName("cibwywapjakklvyb")
public suspend fun amount(`value`: Double?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.amount = mapped
}
/**
* @param value (Optional) The ETag of the Subscription Consumption Budget.
*/
@JvmName("qjtjfemfpekiaewp")
public suspend fun etag(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.etag = mapped
}
/**
* @param value A `filter` block as defined below.
*/
@JvmName("pqrwngrrbpypsouk")
public suspend fun filter(`value`: BudgetSubscriptionFilterArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.filter = mapped
}
/**
* @param argument A `filter` block as defined below.
*/
@JvmName("nbaudandgrepiwmo")
public suspend fun filter(argument: suspend BudgetSubscriptionFilterArgsBuilder.() -> Unit) {
val toBeMapped = BudgetSubscriptionFilterArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.filter = mapped
}
/**
* @param value The name which should be used for this Subscription Consumption Budget. Changing this forces a new resource to be created.
*/
@JvmName("ctabdxexgtjvfrgr")
public suspend fun name(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.name = mapped
}
/**
* @param value One or more `notification` blocks as defined below.
*/
@JvmName("lekvmuxjtrhhcsph")
public suspend fun notifications(`value`: List?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.notifications = mapped
}
/**
* @param argument One or more `notification` blocks as defined below.
*/
@JvmName("rtjmqrohhoqckmeg")
public suspend fun notifications(argument: List Unit>) {
val toBeMapped = argument.toList().map {
BudgetSubscriptionNotificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.notifications = mapped
}
/**
* @param argument One or more `notification` blocks as defined below.
*/
@JvmName("nyxilrixslqtwlgp")
public suspend fun notifications(vararg argument: suspend BudgetSubscriptionNotificationArgsBuilder.() -> Unit) {
val toBeMapped = argument.toList().map {
BudgetSubscriptionNotificationArgsBuilder().applySuspend { it() }.build()
}
val mapped = of(toBeMapped)
this.notifications = mapped
}
/**
* @param argument One or more `notification` blocks as defined below.
*/
@JvmName("drvvbfspdddhjdxw")
public suspend fun notifications(argument: suspend BudgetSubscriptionNotificationArgsBuilder.() -> Unit) {
val toBeMapped = listOf(
BudgetSubscriptionNotificationArgsBuilder().applySuspend {
argument()
}.build(),
)
val mapped = of(toBeMapped)
this.notifications = mapped
}
/**
* @param values One or more `notification` blocks as defined below.
*/
@JvmName("dnwrhaoqomevxdpg")
public suspend fun notifications(vararg values: BudgetSubscriptionNotificationArgs) {
val toBeMapped = values.toList()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.notifications = mapped
}
/**
* @param value The ID of the Subscription for which to create a Consumption Budget. Changing this forces a new resource to be created.
* > **NOTE:** The `subscription_id` property can accept a subscription ID e.g. `00000000-0000-0000-0000-000000000000` or the subscription resource ID e.g. `/subscriptions/00000000-0000-0000-0000-000000000000`. In version 3.0 this property will only accept the subscription resource ID.
*/
@JvmName("hmnmtppicwsaeskd")
public suspend fun subscriptionId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.subscriptionId = mapped
}
/**
* @param value The time covered by a budget. Tracking of the amount will be reset based on the time grain. Must be one of `BillingAnnual`, `BillingMonth`, `BillingQuarter`, `Annually`, `Monthly` and `Quarterly`. Defaults to `Monthly`. Changing this forces a new resource to be created.
*/
@JvmName("gleahdjkyecpgntv")
public suspend fun timeGrain(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.timeGrain = mapped
}
/**
* @param value A `time_period` block as defined below.
*/
@JvmName("gcvuhktabdyhoccm")
public suspend fun timePeriod(`value`: BudgetSubscriptionTimePeriodArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.timePeriod = mapped
}
/**
* @param argument A `time_period` block as defined below.
*/
@JvmName("twumsvnxuioegcga")
public suspend fun timePeriod(argument: suspend BudgetSubscriptionTimePeriodArgsBuilder.() -> Unit) {
val toBeMapped = BudgetSubscriptionTimePeriodArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.timePeriod = mapped
}
internal fun build(): BudgetSubscriptionArgs = BudgetSubscriptionArgs(
amount = amount,
etag = etag,
filter = filter,
name = name,
notifications = notifications,
subscriptionId = subscriptionId,
timeGrain = timeGrain,
timePeriod = timePeriod,
)
}