1. Packages
  2. Azure Native
  3. API Docs
  4. costmanagement
  5. CloudConnector
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.1.0 published on Tuesday, Apr 8, 2025 by Pulumi

azure-native.costmanagement.CloudConnector

Explore with Pulumi AI

This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.1.0 published on Tuesday, Apr 8, 2025 by Pulumi

The Connector model definition

Uses Azure REST API version 2019-03-01-preview. In version 2.x of the Azure Native provider, it used API version 2019-03-01-preview.

Example Usage

CloudConnector_Put

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;

return await Deployment.RunAsync(() => 
{
    var cloudConnector = new AzureNative.CostManagement.CloudConnector("cloudConnector", new()
    {
        ConnectorName = "aws-123456789012",
        CredentialsKey = "arn:aws:iam::123456789012:role/AzureCostManagementRole",
        CredentialsSecret = "external-id",
        DisplayName = "AWS-Consolidated-1",
        ReportId = "HourlyWithResources",
    });

});
Copy
package main

import (
	costmanagement "github.com/pulumi/pulumi-azure-native-sdk/costmanagement/v3"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := costmanagement.NewCloudConnector(ctx, "cloudConnector", &costmanagement.CloudConnectorArgs{
			ConnectorName:     pulumi.String("aws-123456789012"),
			CredentialsKey:    pulumi.String("arn:aws:iam::123456789012:role/AzureCostManagementRole"),
			CredentialsSecret: pulumi.String("external-id"),
			DisplayName:       pulumi.String("AWS-Consolidated-1"),
			ReportId:          pulumi.String("HourlyWithResources"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.costmanagement.CloudConnector;
import com.pulumi.azurenative.costmanagement.CloudConnectorArgs;
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 cloudConnector = new CloudConnector("cloudConnector", CloudConnectorArgs.builder()
            .connectorName("aws-123456789012")
            .credentialsKey("arn:aws:iam::123456789012:role/AzureCostManagementRole")
            .credentialsSecret("external-id")
            .displayName("AWS-Consolidated-1")
            .reportId("HourlyWithResources")
            .build());

    }
}
Copy
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const cloudConnector = new azure_native.costmanagement.CloudConnector("cloudConnector", {
    connectorName: "aws-123456789012",
    credentialsKey: "arn:aws:iam::123456789012:role/AzureCostManagementRole",
    credentialsSecret: "external-id",
    displayName: "AWS-Consolidated-1",
    reportId: "HourlyWithResources",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

cloud_connector = azure_native.costmanagement.CloudConnector("cloudConnector",
    connector_name="aws-123456789012",
    credentials_key="arn:aws:iam::123456789012:role/AzureCostManagementRole",
    credentials_secret="external-id",
    display_name="AWS-Consolidated-1",
    report_id="HourlyWithResources")
Copy
resources:
  cloudConnector:
    type: azure-native:costmanagement:CloudConnector
    properties:
      connectorName: aws-123456789012
      credentialsKey: arn:aws:iam::123456789012:role/AzureCostManagementRole
      credentialsSecret: external-id
      displayName: AWS-Consolidated-1
      reportId: HourlyWithResources
Copy

Create CloudConnector Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new CloudConnector(name: string, args?: CloudConnectorArgs, opts?: CustomResourceOptions);
@overload
def CloudConnector(resource_name: str,
                   args: Optional[CloudConnectorArgs] = None,
                   opts: Optional[ResourceOptions] = None)

@overload
def CloudConnector(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   billing_model: Optional[Union[str, ConnectorBillingModel]] = None,
                   connector_name: Optional[str] = None,
                   credentials_key: Optional[str] = None,
                   credentials_secret: Optional[str] = None,
                   default_management_group_id: Optional[str] = None,
                   display_name: Optional[str] = None,
                   kind: Optional[str] = None,
                   report_id: Optional[str] = None,
                   subscription_id: Optional[str] = None)
func NewCloudConnector(ctx *Context, name string, args *CloudConnectorArgs, opts ...ResourceOption) (*CloudConnector, error)
public CloudConnector(string name, CloudConnectorArgs? args = null, CustomResourceOptions? opts = null)
public CloudConnector(String name, CloudConnectorArgs args)
public CloudConnector(String name, CloudConnectorArgs args, CustomResourceOptions options)
type: azure-native:costmanagement:CloudConnector
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 CloudConnectorArgs
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 CloudConnectorArgs
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 CloudConnectorArgs
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 CloudConnectorArgs
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. CloudConnectorArgs
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 cloudConnectorResource = new AzureNative.CostManagement.CloudConnector("cloudConnectorResource", new()
{
    BillingModel = "string",
    ConnectorName = "string",
    CredentialsKey = "string",
    CredentialsSecret = "string",
    DefaultManagementGroupId = "string",
    DisplayName = "string",
    Kind = "string",
    ReportId = "string",
    SubscriptionId = "string",
});
Copy
example, err := costmanagement.NewCloudConnector(ctx, "cloudConnectorResource", &costmanagement.CloudConnectorArgs{
	BillingModel:             pulumi.String("string"),
	ConnectorName:            pulumi.String("string"),
	CredentialsKey:           pulumi.String("string"),
	CredentialsSecret:        pulumi.String("string"),
	DefaultManagementGroupId: pulumi.String("string"),
	DisplayName:              pulumi.String("string"),
	Kind:                     pulumi.String("string"),
	ReportId:                 pulumi.String("string"),
	SubscriptionId:           pulumi.String("string"),
})
Copy
var cloudConnectorResource = new CloudConnector("cloudConnectorResource", CloudConnectorArgs.builder()
    .billingModel("string")
    .connectorName("string")
    .credentialsKey("string")
    .credentialsSecret("string")
    .defaultManagementGroupId("string")
    .displayName("string")
    .kind("string")
    .reportId("string")
    .subscriptionId("string")
    .build());
Copy
cloud_connector_resource = azure_native.costmanagement.CloudConnector("cloudConnectorResource",
    billing_model="string",
    connector_name="string",
    credentials_key="string",
    credentials_secret="string",
    default_management_group_id="string",
    display_name="string",
    kind="string",
    report_id="string",
    subscription_id="string")
Copy
const cloudConnectorResource = new azure_native.costmanagement.CloudConnector("cloudConnectorResource", {
    billingModel: "string",
    connectorName: "string",
    credentialsKey: "string",
    credentialsSecret: "string",
    defaultManagementGroupId: "string",
    displayName: "string",
    kind: "string",
    reportId: "string",
    subscriptionId: "string",
});
Copy
type: azure-native:costmanagement:CloudConnector
properties:
    billingModel: string
    connectorName: string
    credentialsKey: string
    credentialsSecret: string
    defaultManagementGroupId: string
    displayName: string
    kind: string
    reportId: string
    subscriptionId: string
Copy

CloudConnector 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 CloudConnector resource accepts the following input properties:

BillingModel string | Pulumi.AzureNative.CostManagement.ConnectorBillingModel
Connector billing model
ConnectorName Changes to this property will trigger replacement. string
Connector Name.
CredentialsKey string
Credentials authentication key (eg AWS ARN)
CredentialsSecret string
Credentials secret (eg AWS ExternalId)
DefaultManagementGroupId string
Default ManagementGroupId
DisplayName string
Connector DisplayName
Kind string
Connector kind (eg aws)
ReportId string
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
SubscriptionId string
Billing SubscriptionId
BillingModel string | ConnectorBillingModel
Connector billing model
ConnectorName Changes to this property will trigger replacement. string
Connector Name.
CredentialsKey string
Credentials authentication key (eg AWS ARN)
CredentialsSecret string
Credentials secret (eg AWS ExternalId)
DefaultManagementGroupId string
Default ManagementGroupId
DisplayName string
Connector DisplayName
Kind string
Connector kind (eg aws)
ReportId string
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
SubscriptionId string
Billing SubscriptionId
billingModel String | ConnectorBillingModel
Connector billing model
connectorName Changes to this property will trigger replacement. String
Connector Name.
credentialsKey String
Credentials authentication key (eg AWS ARN)
credentialsSecret String
Credentials secret (eg AWS ExternalId)
defaultManagementGroupId String
Default ManagementGroupId
displayName String
Connector DisplayName
kind String
Connector kind (eg aws)
reportId String
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
subscriptionId String
Billing SubscriptionId
billingModel string | ConnectorBillingModel
Connector billing model
connectorName Changes to this property will trigger replacement. string
Connector Name.
credentialsKey string
Credentials authentication key (eg AWS ARN)
credentialsSecret string
Credentials secret (eg AWS ExternalId)
defaultManagementGroupId string
Default ManagementGroupId
displayName string
Connector DisplayName
kind string
Connector kind (eg aws)
reportId string
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
subscriptionId string
Billing SubscriptionId
billing_model str | ConnectorBillingModel
Connector billing model
connector_name Changes to this property will trigger replacement. str
Connector Name.
credentials_key str
Credentials authentication key (eg AWS ARN)
credentials_secret str
Credentials secret (eg AWS ExternalId)
default_management_group_id str
Default ManagementGroupId
display_name str
Connector DisplayName
kind str
Connector kind (eg aws)
report_id str
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
subscription_id str
Billing SubscriptionId
billingModel String | "trial" | "autoUpgrade" | "premium" | "expired"
Connector billing model
connectorName Changes to this property will trigger replacement. String
Connector Name.
credentialsKey String
Credentials authentication key (eg AWS ARN)
credentialsSecret String
Credentials secret (eg AWS ExternalId)
defaultManagementGroupId String
Default ManagementGroupId
displayName String
Connector DisplayName
kind String
Connector kind (eg aws)
reportId String
Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
subscriptionId String
Billing SubscriptionId

Outputs

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

AzureApiVersion string
The Azure API version of the resource.
CollectionInfo Pulumi.AzureNative.CostManagement.Outputs.ConnectorCollectionInfoResponse
Collection information
CreatedOn string
Connector definition creation datetime
DaysTrialRemaining int
Number of days remaining of trial
ExternalBillingAccountId string
Associated ExternalBillingAccountId
Id string
The provider-assigned unique ID for this managed resource.
ModifiedOn string
Connector last modified datetime
Name string
Connector name
ProviderBillingAccountDisplayName string
The display name of the providerBillingAccountId as defined on the external provider
ProviderBillingAccountId string
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
Status string
Connector status
Type string
Connector type
AzureApiVersion string
The Azure API version of the resource.
CollectionInfo ConnectorCollectionInfoResponse
Collection information
CreatedOn string
Connector definition creation datetime
DaysTrialRemaining int
Number of days remaining of trial
ExternalBillingAccountId string
Associated ExternalBillingAccountId
Id string
The provider-assigned unique ID for this managed resource.
ModifiedOn string
Connector last modified datetime
Name string
Connector name
ProviderBillingAccountDisplayName string
The display name of the providerBillingAccountId as defined on the external provider
ProviderBillingAccountId string
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
Status string
Connector status
Type string
Connector type
azureApiVersion String
The Azure API version of the resource.
collectionInfo ConnectorCollectionInfoResponse
Collection information
createdOn String
Connector definition creation datetime
daysTrialRemaining Integer
Number of days remaining of trial
externalBillingAccountId String
Associated ExternalBillingAccountId
id String
The provider-assigned unique ID for this managed resource.
modifiedOn String
Connector last modified datetime
name String
Connector name
providerBillingAccountDisplayName String
The display name of the providerBillingAccountId as defined on the external provider
providerBillingAccountId String
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
status String
Connector status
type String
Connector type
azureApiVersion string
The Azure API version of the resource.
collectionInfo ConnectorCollectionInfoResponse
Collection information
createdOn string
Connector definition creation datetime
daysTrialRemaining number
Number of days remaining of trial
externalBillingAccountId string
Associated ExternalBillingAccountId
id string
The provider-assigned unique ID for this managed resource.
modifiedOn string
Connector last modified datetime
name string
Connector name
providerBillingAccountDisplayName string
The display name of the providerBillingAccountId as defined on the external provider
providerBillingAccountId string
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
status string
Connector status
type string
Connector type
azure_api_version str
The Azure API version of the resource.
collection_info ConnectorCollectionInfoResponse
Collection information
created_on str
Connector definition creation datetime
days_trial_remaining int
Number of days remaining of trial
external_billing_account_id str
Associated ExternalBillingAccountId
id str
The provider-assigned unique ID for this managed resource.
modified_on str
Connector last modified datetime
name str
Connector name
provider_billing_account_display_name str
The display name of the providerBillingAccountId as defined on the external provider
provider_billing_account_id str
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
status str
Connector status
type str
Connector type
azureApiVersion String
The Azure API version of the resource.
collectionInfo Property Map
Collection information
createdOn String
Connector definition creation datetime
daysTrialRemaining Number
Number of days remaining of trial
externalBillingAccountId String
Associated ExternalBillingAccountId
id String
The provider-assigned unique ID for this managed resource.
modifiedOn String
Connector last modified datetime
name String
Connector name
providerBillingAccountDisplayName String
The display name of the providerBillingAccountId as defined on the external provider
providerBillingAccountId String
Connector providerBillingAccountId, determined from credentials (eg AWS Consolidated account number)
status String
Connector status
type String
Connector type

Supporting Types

ConnectorBillingModel
, ConnectorBillingModelArgs

Trial
trial
AutoUpgrade
autoUpgrade
Premium
premium
Expired
expired
ConnectorBillingModelTrial
trial
ConnectorBillingModelAutoUpgrade
autoUpgrade
ConnectorBillingModelPremium
premium
ConnectorBillingModelExpired
expired
Trial
trial
AutoUpgrade
autoUpgrade
Premium
premium
Expired
expired
Trial
trial
AutoUpgrade
autoUpgrade
Premium
premium
Expired
expired
TRIAL
trial
AUTO_UPGRADE
autoUpgrade
PREMIUM
premium
EXPIRED
expired
"trial"
trial
"autoUpgrade"
autoUpgrade
"premium"
premium
"expired"
expired

ConnectorCollectionErrorInfoResponse
, ConnectorCollectionErrorInfoResponseArgs

ErrorCode This property is required. string
Short error message
ErrorMessage This property is required. string
Detailed error message
ErrorStartTime This property is required. string
Time the error started occurring (Last time error occurred in lastRun)
ErrorInnerMessage string
External Provider error message
ErrorCode This property is required. string
Short error message
ErrorMessage This property is required. string
Detailed error message
ErrorStartTime This property is required. string
Time the error started occurring (Last time error occurred in lastRun)
ErrorInnerMessage string
External Provider error message
errorCode This property is required. String
Short error message
errorMessage This property is required. String
Detailed error message
errorStartTime This property is required. String
Time the error started occurring (Last time error occurred in lastRun)
errorInnerMessage String
External Provider error message
errorCode This property is required. string
Short error message
errorMessage This property is required. string
Detailed error message
errorStartTime This property is required. string
Time the error started occurring (Last time error occurred in lastRun)
errorInnerMessage string
External Provider error message
error_code This property is required. str
Short error message
error_message This property is required. str
Detailed error message
error_start_time This property is required. str
Time the error started occurring (Last time error occurred in lastRun)
error_inner_message str
External Provider error message
errorCode This property is required. String
Short error message
errorMessage This property is required. String
Detailed error message
errorStartTime This property is required. String
Time the error started occurring (Last time error occurred in lastRun)
errorInnerMessage String
External Provider error message

ConnectorCollectionInfoResponse
, ConnectorCollectionInfoResponseArgs

LastRun This property is required. string
Last time the data acquisition process completed (even if no new data was found)
LastUpdated This property is required. string
Last time the external data was updated into Azure
SourceLastUpdated This property is required. string
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
Error Pulumi.AzureNative.CostManagement.Inputs.ConnectorCollectionErrorInfoResponse
Error information of last collection
LastChecked string
Last time the data acquisition process initiated connecting to the external provider
LastRun This property is required. string
Last time the data acquisition process completed (even if no new data was found)
LastUpdated This property is required. string
Last time the external data was updated into Azure
SourceLastUpdated This property is required. string
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
Error ConnectorCollectionErrorInfoResponse
Error information of last collection
LastChecked string
Last time the data acquisition process initiated connecting to the external provider
lastRun This property is required. String
Last time the data acquisition process completed (even if no new data was found)
lastUpdated This property is required. String
Last time the external data was updated into Azure
sourceLastUpdated This property is required. String
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
error ConnectorCollectionErrorInfoResponse
Error information of last collection
lastChecked String
Last time the data acquisition process initiated connecting to the external provider
lastRun This property is required. string
Last time the data acquisition process completed (even if no new data was found)
lastUpdated This property is required. string
Last time the external data was updated into Azure
sourceLastUpdated This property is required. string
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
error ConnectorCollectionErrorInfoResponse
Error information of last collection
lastChecked string
Last time the data acquisition process initiated connecting to the external provider
last_run This property is required. str
Last time the data acquisition process completed (even if no new data was found)
last_updated This property is required. str
Last time the external data was updated into Azure
source_last_updated This property is required. str
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
error ConnectorCollectionErrorInfoResponse
Error information of last collection
last_checked str
Last time the data acquisition process initiated connecting to the external provider
lastRun This property is required. String
Last time the data acquisition process completed (even if no new data was found)
lastUpdated This property is required. String
Last time the external data was updated into Azure
sourceLastUpdated This property is required. String
Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
error Property Map
Error information of last collection
lastChecked String
Last time the data acquisition process initiated connecting to the external provider

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:costmanagement:CloudConnector aws-123456789012 /providers/Microsoft.CostManagement/cloudConnectors/{connectorName} 
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Azure Native pulumi/pulumi-azure-native
License
Apache-2.0
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.1.0 published on Tuesday, Apr 8, 2025 by Pulumi