Module billing

This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-gcp repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-google repo.

Resources

Others

Resources

Resource AccountIamBinding

class AccountIamBinding extends CustomResource

Allows creation and management of a single binding within IAM policy for an existing Google Cloud Platform Billing Account.

Note: This resource must not be used in conjunction with gcp.billing.AccountIamMember for the same role or they will fight over what your policy should be.

Note: On create, this resource will overwrite members of any existing roles. Use import and inspect the preview output to ensure your existing members are preserved.

Example Usage

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

const binding = new gcp.billing.AccountIamBinding("binding", {
    billingAccountId: "00AA00-000AAA-00AA0A",
    members: ["user:alice@gmail.com"],
    role: "roles/billing.viewer",
});

This content is derived from https://github.com/terraform-providers/terraform-provider-google/blob/master/website/docs/r/billing_account_iam_binding.html.markdown.

constructor

new AccountIamBinding(name: string, args: AccountIamBindingArgs, opts?: pulumi.CustomResourceOptions)

Create a AccountIamBinding resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AccountIamBindingState, opts?: pulumi.CustomResourceOptions): AccountIamBinding

Get an existing AccountIamBinding resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of AccountIamBinding. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property billingAccountId

public billingAccountId: pulumi.Output<string>;

The billing account id.

property etag

public etag: pulumi.Output<string>;

(Computed) The etag of the billing account’s IAM policy.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property members

public members: pulumi.Output<string[]>;

A list of users that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

public role: pulumi.Output<string>;

The role that should be applied.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource AccountIamMember

class AccountIamMember extends CustomResource

Allows creation and management of a single member for a single binding within the IAM policy for an existing Google Cloud Platform Billing Account.

Note: This resource must not be used in conjunction with gcp.billing.AccountIamBinding for the same role or they will fight over what your policy should be.

Example Usage

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

const binding = new gcp.billing.AccountIamMember("binding", {
    billingAccountId: "00AA00-000AAA-00AA0A",
    member: "user:alice@gmail.com",
    role: "roles/billing.viewer",
});

This content is derived from https://github.com/terraform-providers/terraform-provider-google/blob/master/website/docs/r/billing_account_iam_member.html.markdown.

constructor

new AccountIamMember(name: string, args: AccountIamMemberArgs, opts?: pulumi.CustomResourceOptions)

Create a AccountIamMember resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AccountIamMemberState, opts?: pulumi.CustomResourceOptions): AccountIamMember

Get an existing AccountIamMember resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of AccountIamMember. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property billingAccountId

public billingAccountId: pulumi.Output<string>;

The billing account id.

property etag

public etag: pulumi.Output<string>;

(Computed) The etag of the billing account’s IAM policy.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property member

public member: pulumi.Output<string>;

The user that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

public role: pulumi.Output<string>;

The role that should be applied.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource AccountIamPolicy

class AccountIamPolicy extends CustomResource

Allows management of the entire IAM policy for an existing Google Cloud Platform Billing Account.

Warning: Billing accounts have a default user that can be overwritten by use of this resource. The safest alternative is to use multiple gcp.billing.AccountIamBinding resources. If you do use this resource, the best way to be sure that you are not making dangerous changes is to start by importing your existing policy, and examining the diff very closely.

Note: This resource must not be used in conjunction with gcp.billing.AccountIamMember or gcp.billing.AccountIamBinding or they will fight over what your policy should be.

Example Usage

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

const admin = gcp.organizations.getIAMPolicy({
    bindings: [{
        members: ["user:jane@example.com"],
        role: "roles/billing.viewer",
    }],
});
const policy = new gcp.billing.AccountIamPolicy("policy", {
    billingAccountId: "00AA00-000AAA-00AA0A",
    policyData: admin.policyData,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-google/blob/master/website/docs/r/billing_account_iam_policy.html.markdown.

constructor

new AccountIamPolicy(name: string, args: AccountIamPolicyArgs, opts?: pulumi.CustomResourceOptions)

Create a AccountIamPolicy resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AccountIamPolicyState, opts?: pulumi.CustomResourceOptions): AccountIamPolicy

Get an existing AccountIamPolicy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of AccountIamPolicy. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property billingAccountId

public billingAccountId: pulumi.Output<string>;

The billing account id.

property etag

public etag: pulumi.Output<string>;

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property policyData

public policyData: pulumi.Output<string>;

The gcp.organizations.getIAMPolicy data source that represents the IAM policy that will be applied to the billing account. This policy overrides any existing policy applied to the billing account.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Others

interface AccountIamBindingArgs

interface AccountIamBindingArgs

The set of arguments for constructing a AccountIamBinding resource.

property billingAccountId

billingAccountId: pulumi.Input<string>;

The billing account id.

property members

members: pulumi.Input<pulumi.Input<string>[]>;

A list of users that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

role: pulumi.Input<string>;

The role that should be applied.

interface AccountIamBindingState

interface AccountIamBindingState

Input properties used for looking up and filtering AccountIamBinding resources.

property billingAccountId

billingAccountId?: pulumi.Input<string>;

The billing account id.

property etag

etag?: pulumi.Input<string>;

(Computed) The etag of the billing account’s IAM policy.

property members

members?: pulumi.Input<pulumi.Input<string>[]>;

A list of users that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

role?: pulumi.Input<string>;

The role that should be applied.

interface AccountIamMemberArgs

interface AccountIamMemberArgs

The set of arguments for constructing a AccountIamMember resource.

property billingAccountId

billingAccountId: pulumi.Input<string>;

The billing account id.

property member

member: pulumi.Input<string>;

The user that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

role: pulumi.Input<string>;

The role that should be applied.

interface AccountIamMemberState

interface AccountIamMemberState

Input properties used for looking up and filtering AccountIamMember resources.

property billingAccountId

billingAccountId?: pulumi.Input<string>;

The billing account id.

property etag

etag?: pulumi.Input<string>;

(Computed) The etag of the billing account’s IAM policy.

property member

member?: pulumi.Input<string>;

The user that the role should apply to. For more details on format and restrictions see https://cloud.google.com/billing/reference/rest/v1/Policy#Binding

property role

role?: pulumi.Input<string>;

The role that should be applied.

interface AccountIamPolicyArgs

interface AccountIamPolicyArgs

The set of arguments for constructing a AccountIamPolicy resource.

property billingAccountId

billingAccountId: pulumi.Input<string>;

The billing account id.

property policyData

policyData: pulumi.Input<string>;

The gcp.organizations.getIAMPolicy data source that represents the IAM policy that will be applied to the billing account. This policy overrides any existing policy applied to the billing account.

interface AccountIamPolicyState

interface AccountIamPolicyState

Input properties used for looking up and filtering AccountIamPolicy resources.

property billingAccountId

billingAccountId?: pulumi.Input<string>;

The billing account id.

property etag

etag?: pulumi.Input<string>;

property policyData

policyData?: pulumi.Input<string>;

The gcp.organizations.getIAMPolicy data source that represents the IAM policy that will be applied to the billing account. This policy overrides any existing policy applied to the billing account.