Azure Native

Pulumi Official
Package maintained by Pulumi
v1.64.1 published on Wednesday, May 18, 2022 by Pulumi

getCostAllocationRule

The cost allocation rule model definition API Version: 2020-03-01-preview.

Using getCostAllocationRule

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getCostAllocationRule(args: GetCostAllocationRuleArgs, opts?: InvokeOptions): Promise<GetCostAllocationRuleResult>
function getCostAllocationRuleOutput(args: GetCostAllocationRuleOutputArgs, opts?: InvokeOptions): Output<GetCostAllocationRuleResult>
def get_cost_allocation_rule(billing_account_id: Optional[str] = None,
                             rule_name: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetCostAllocationRuleResult
def get_cost_allocation_rule_output(billing_account_id: Optional[pulumi.Input[str]] = None,
                             rule_name: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetCostAllocationRuleResult]
func LookupCostAllocationRule(ctx *Context, args *LookupCostAllocationRuleArgs, opts ...InvokeOption) (*LookupCostAllocationRuleResult, error)
func LookupCostAllocationRuleOutput(ctx *Context, args *LookupCostAllocationRuleOutputArgs, opts ...InvokeOption) LookupCostAllocationRuleResultOutput

> Note: This function is named LookupCostAllocationRule in the Go SDK.

public static class GetCostAllocationRule 
{
    public static Task<GetCostAllocationRuleResult> InvokeAsync(GetCostAllocationRuleArgs args, InvokeOptions? opts = null)
    public static Output<GetCostAllocationRuleResult> Invoke(GetCostAllocationRuleInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCostAllocationRuleResult> getCostAllocationRule(GetCostAllocationRuleArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: azure-native:costmanagement:getCostAllocationRule
  Arguments:
    # Arguments dictionary

The following arguments are supported:

BillingAccountId string

BillingAccount ID

RuleName string

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

BillingAccountId string

BillingAccount ID

RuleName string

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

billingAccountId String

BillingAccount ID

ruleName String

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

billingAccountId string

BillingAccount ID

ruleName string

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

billing_account_id str

BillingAccount ID

rule_name str

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

billingAccountId String

BillingAccount ID

ruleName String

Cost allocation rule name. The name cannot include spaces or any non alphanumeric characters other than '_' and '-'. The max length is 260 characters.

getCostAllocationRule Result

The following output properties are available:

Id string

Azure Resource Manager Id for the rule. This is a read ony value.

Name string

Name of the rule. This is a read only value.

Properties Pulumi.AzureNative.CostManagement.Outputs.CostAllocationRulePropertiesResponse

Cost allocation rule properties

Type string

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

Id string

Azure Resource Manager Id for the rule. This is a read ony value.

Name string

Name of the rule. This is a read only value.

Properties CostAllocationRulePropertiesResponse

Cost allocation rule properties

Type string

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

id String

Azure Resource Manager Id for the rule. This is a read ony value.

name String

Name of the rule. This is a read only value.

properties CostAllocationRulePropertiesResponse

Cost allocation rule properties

type String

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

id string

Azure Resource Manager Id for the rule. This is a read ony value.

name string

Name of the rule. This is a read only value.

properties CostAllocationRulePropertiesResponse

Cost allocation rule properties

type string

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

id str

Azure Resource Manager Id for the rule. This is a read ony value.

name str

Name of the rule. This is a read only value.

properties CostAllocationRulePropertiesResponse

Cost allocation rule properties

type str

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

id String

Azure Resource Manager Id for the rule. This is a read ony value.

name String

Name of the rule. This is a read only value.

properties Property Map

Cost allocation rule properties

type String

Resource type of the rule. This is a read only value of Microsoft.CostManagement/CostAllocationRule.

Supporting Types

CostAllocationProportionResponse

Name string

Target resource for cost allocation

Percentage double

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

Name string

Target resource for cost allocation

Percentage float64

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

name String

Target resource for cost allocation

percentage Double

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

name string

Target resource for cost allocation

percentage number

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

name str

Target resource for cost allocation

percentage float

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

name String

Target resource for cost allocation

percentage Number

Percentage of source cost to allocate to this resource. This value can be specified to two decimal places and the total percentage of all resources in this rule must sum to 100.00.

CostAllocationRuleDetailsResponse

SourceResources List<Pulumi.AzureNative.CostManagement.Inputs.SourceCostAllocationResourceResponse>

Source resources for cost allocation. At this time, this list can contain no more than one element.

TargetResources List<Pulumi.AzureNative.CostManagement.Inputs.TargetCostAllocationResourceResponse>

Target resources for cost allocation. At this time, this list can contain no more than one element.

SourceResources []SourceCostAllocationResourceResponse

Source resources for cost allocation. At this time, this list can contain no more than one element.

TargetResources []TargetCostAllocationResourceResponse

Target resources for cost allocation. At this time, this list can contain no more than one element.

sourceResources ListCostAllocationResourceResponse>

Source resources for cost allocation. At this time, this list can contain no more than one element.

targetResources ListCostAllocationResourceResponse>

Target resources for cost allocation. At this time, this list can contain no more than one element.

sourceResources SourceCostAllocationResourceResponse[]

Source resources for cost allocation. At this time, this list can contain no more than one element.

targetResources TargetCostAllocationResourceResponse[]

Target resources for cost allocation. At this time, this list can contain no more than one element.

source_resources Sequence[SourceCostAllocationResourceResponse]

Source resources for cost allocation. At this time, this list can contain no more than one element.

target_resources Sequence[TargetCostAllocationResourceResponse]

Target resources for cost allocation. At this time, this list can contain no more than one element.

sourceResources List

Source resources for cost allocation. At this time, this list can contain no more than one element.

targetResources List

Target resources for cost allocation. At this time, this list can contain no more than one element.

CostAllocationRulePropertiesResponse

CreatedDate string

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

Details Pulumi.AzureNative.CostManagement.Inputs.CostAllocationRuleDetailsResponse

Resource information for the cost allocation rule

Status string

Status of the rule

UpdatedDate string

Time at which the rule was last updated.

Description string

Description of a cost allocation rule.

CreatedDate string

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

Details CostAllocationRuleDetailsResponse

Resource information for the cost allocation rule

Status string

Status of the rule

UpdatedDate string

Time at which the rule was last updated.

Description string

Description of a cost allocation rule.

createdDate String

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

details CostAllocationRuleDetailsResponse

Resource information for the cost allocation rule

status String

Status of the rule

updatedDate String

Time at which the rule was last updated.

description String

Description of a cost allocation rule.

createdDate string

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

details CostAllocationRuleDetailsResponse

Resource information for the cost allocation rule

status string

Status of the rule

updatedDate string

Time at which the rule was last updated.

description string

Description of a cost allocation rule.

created_date str

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

details CostAllocationRuleDetailsResponse

Resource information for the cost allocation rule

status str

Status of the rule

updated_date str

Time at which the rule was last updated.

description str

Description of a cost allocation rule.

createdDate String

Time at which the rule was created. Rules that change cost for the same resource are applied in order of creation.

details Property Map

Resource information for the cost allocation rule

status String

Status of the rule

updatedDate String

Time at which the rule was last updated.

description String

Description of a cost allocation rule.

SourceCostAllocationResourceResponse

Name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

ResourceType string

Type of resources contained in this cost allocation rule

Values List<string>

Source Resources for cost allocation. This list cannot contain more than 25 values.

Name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

ResourceType string

Type of resources contained in this cost allocation rule

Values []string

Source Resources for cost allocation. This list cannot contain more than 25 values.

name String

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

resourceType String

Type of resources contained in this cost allocation rule

values List

Source Resources for cost allocation. This list cannot contain more than 25 values.

name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

resourceType string

Type of resources contained in this cost allocation rule

values string[]

Source Resources for cost allocation. This list cannot contain more than 25 values.

name str

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

resource_type str

Type of resources contained in this cost allocation rule

values Sequence[str]

Source Resources for cost allocation. This list cannot contain more than 25 values.

name String

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

resourceType String

Type of resources contained in this cost allocation rule

values List

Source Resources for cost allocation. This list cannot contain more than 25 values.

TargetCostAllocationResourceResponse

Name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

PolicyType string

Method of cost allocation for the rule

ResourceType string

Type of resources contained in this cost allocation rule

Values List<Pulumi.AzureNative.CostManagement.Inputs.CostAllocationProportionResponse>

Target resources for cost allocation. This list cannot contain more than 25 values.

Name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

PolicyType string

Method of cost allocation for the rule

ResourceType string

Type of resources contained in this cost allocation rule

Values []CostAllocationProportionResponse

Target resources for cost allocation. This list cannot contain more than 25 values.

name String

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

policyType String

Method of cost allocation for the rule

resourceType String

Type of resources contained in this cost allocation rule

values ListAllocationProportionResponse>

Target resources for cost allocation. This list cannot contain more than 25 values.

name string

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

policyType string

Method of cost allocation for the rule

resourceType string

Type of resources contained in this cost allocation rule

values CostAllocationProportionResponse[]

Target resources for cost allocation. This list cannot contain more than 25 values.

name str

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

policy_type str

Method of cost allocation for the rule

resource_type str

Type of resources contained in this cost allocation rule

values Sequence[CostAllocationProportionResponse]

Target resources for cost allocation. This list cannot contain more than 25 values.

name String

If resource type is dimension, this must be either ResourceGroupName or SubscriptionId. If resource type is tag, this must be a valid Azure tag

policyType String

Method of cost allocation for the rule

resourceType String

Type of resources contained in this cost allocation rule

values List

Target resources for cost allocation. This list cannot contain more than 25 values.

Package Details

Repository
https://github.com/pulumi/pulumi-azure-native
License
Apache-2.0