Billing Role Assignment By Billing Account Args
The role assignment Uses Azure REST API version 2019-10-01-preview. In version 1.x of the Azure Native provider, it used API version 2019-10-01-preview. Other available API versions: 2024-04-01.
Example Usage
PutEnrollmentAdministratorRoleAssignment
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var billingRoleAssignmentByBillingAccount = new AzureNative.Billing.BillingRoleAssignmentByBillingAccount("billingRoleAssignmentByBillingAccount", new()
{
BillingAccountName = "{billingAccountName}",
BillingRoleAssignmentName = "{billingRoleAssignmentName}",
PrincipalId = "99a1a759-30dd-42c2-828c-db398826bb67",
PrincipalTenantId = "7ca289b9-c32d-4f01-8566-7ff93261d76f",
RoleDefinitionId = "/providers/Microsoft.Billing/billingAccounts/7898901/billingRoleDefinitions/9f1983cb-2574-400c-87e9-34cf8e2280db",
});
});
package main
import (
billing "github.com/pulumi/pulumi-azure-native-sdk/billing/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := billing.NewBillingRoleAssignmentByBillingAccount(ctx, "billingRoleAssignmentByBillingAccount", &billing.BillingRoleAssignmentByBillingAccountArgs{
BillingAccountName: pulumi.String("{billingAccountName}"),
BillingRoleAssignmentName: pulumi.String("{billingRoleAssignmentName}"),
PrincipalId: pulumi.String("99a1a759-30dd-42c2-828c-db398826bb67"),
PrincipalTenantId: pulumi.String("7ca289b9-c32d-4f01-8566-7ff93261d76f"),
RoleDefinitionId: pulumi.String("/providers/Microsoft.Billing/billingAccounts/7898901/billingRoleDefinitions/9f1983cb-2574-400c-87e9-34cf8e2280db"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.billing.BillingRoleAssignmentByBillingAccount;
import com.pulumi.azurenative.billing.BillingRoleAssignmentByBillingAccountArgs;
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 billingRoleAssignmentByBillingAccount = new BillingRoleAssignmentByBillingAccount("billingRoleAssignmentByBillingAccount", BillingRoleAssignmentByBillingAccountArgs.builder()
.billingAccountName("{billingAccountName}")
.billingRoleAssignmentName("{billingRoleAssignmentName}")
.principalId("99a1a759-30dd-42c2-828c-db398826bb67")
.principalTenantId("7ca289b9-c32d-4f01-8566-7ff93261d76f")
.roleDefinitionId("/providers/Microsoft.Billing/billingAccounts/7898901/billingRoleDefinitions/9f1983cb-2574-400c-87e9-34cf8e2280db")
.build());
}
}
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:billing:BillingRoleAssignmentByBillingAccount 9dfd08c2-62a3-4d47-85bd-1cdba1408402 /providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingRoleAssignments/{billingRoleAssignmentName}
Constructors
Properties
The ID that uniquely identifies a billing account.
The ID that uniquely identifies a role assignment.
The principal id of the user to whom the role was assigned.
The principal tenant id of the user to whom the role was assigned.
The ID of the role definition.
The authentication type of the user, whether Organization or MSA, of the user to whom the role was assigned. This is supported only for billing accounts with agreement type Enterprise Agreement.
The email address of the user to whom the role was assigned. This is supported only for billing accounts with agreement type Enterprise Agreement.