azure-native.costmanagement.Connector
Explore with Pulumi AI
The Connector model definition Azure REST API version: 2018-08-01-preview.
Example Usage
Connector_Put
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() => 
{
    var connector = new AzureNative.CostManagement.Connector("connector", new()
    {
        ConnectorName = "AWSBillingAccount",
        CredentialsKey = "arn:aws:iam::123456789012:role/AzureCostManagementRole",
        CredentialsSecret = "external-id",
        DisplayName = "AWS-Consolidated-1",
        Location = "westus",
        ReportId = "HourlyWithResources",
        ResourceGroupName = "rg1",
        Status = AzureNative.CostManagement.ConnectorStatus.Active,
    });
});
package main
import (
	costmanagement "github.com/pulumi/pulumi-azure-native-sdk/costmanagement/v2"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := costmanagement.NewConnector(ctx, "connector", &costmanagement.ConnectorArgs{
			ConnectorName:     pulumi.String("AWSBillingAccount"),
			CredentialsKey:    pulumi.String("arn:aws:iam::123456789012:role/AzureCostManagementRole"),
			CredentialsSecret: pulumi.String("external-id"),
			DisplayName:       pulumi.String("AWS-Consolidated-1"),
			Location:          pulumi.String("westus"),
			ReportId:          pulumi.String("HourlyWithResources"),
			ResourceGroupName: pulumi.String("rg1"),
			Status:            pulumi.String(costmanagement.ConnectorStatusActive),
		})
		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.costmanagement.Connector;
import com.pulumi.azurenative.costmanagement.ConnectorArgs;
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 connector = new Connector("connector", ConnectorArgs.builder()
            .connectorName("AWSBillingAccount")
            .credentialsKey("arn:aws:iam::123456789012:role/AzureCostManagementRole")
            .credentialsSecret("external-id")
            .displayName("AWS-Consolidated-1")
            .location("westus")
            .reportId("HourlyWithResources")
            .resourceGroupName("rg1")
            .status("active")
            .build());
    }
}
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const connector = new azure_native.costmanagement.Connector("connector", {
    connectorName: "AWSBillingAccount",
    credentialsKey: "arn:aws:iam::123456789012:role/AzureCostManagementRole",
    credentialsSecret: "external-id",
    displayName: "AWS-Consolidated-1",
    location: "westus",
    reportId: "HourlyWithResources",
    resourceGroupName: "rg1",
    status: azure_native.costmanagement.ConnectorStatus.Active,
});
import pulumi
import pulumi_azure_native as azure_native
connector = azure_native.costmanagement.Connector("connector",
    connector_name="AWSBillingAccount",
    credentials_key="arn:aws:iam::123456789012:role/AzureCostManagementRole",
    credentials_secret="external-id",
    display_name="AWS-Consolidated-1",
    location="westus",
    report_id="HourlyWithResources",
    resource_group_name="rg1",
    status=azure_native.costmanagement.ConnectorStatus.ACTIVE)
resources:
  connector:
    type: azure-native:costmanagement:Connector
    properties:
      connectorName: AWSBillingAccount
      credentialsKey: arn:aws:iam::123456789012:role/AzureCostManagementRole
      credentialsSecret: external-id
      displayName: AWS-Consolidated-1
      location: westus
      reportId: HourlyWithResources
      resourceGroupName: rg1
      status: active
Create Connector Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Connector(name: string, args: ConnectorArgs, opts?: CustomResourceOptions);@overload
def Connector(resource_name: str,
              args: ConnectorArgs,
              opts: Optional[ResourceOptions] = None)
@overload
def Connector(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              resource_group_name: Optional[str] = None,
              connector_name: Optional[str] = None,
              credentials_key: Optional[str] = None,
              credentials_secret: Optional[str] = None,
              display_name: Optional[str] = None,
              kind: Optional[str] = None,
              location: Optional[str] = None,
              report_id: Optional[str] = None,
              status: Optional[Union[str, ConnectorStatus]] = None,
              tags: Optional[Mapping[str, str]] = None)func NewConnector(ctx *Context, name string, args ConnectorArgs, opts ...ResourceOption) (*Connector, error)public Connector(string name, ConnectorArgs args, CustomResourceOptions? opts = null)
public Connector(String name, ConnectorArgs args)
public Connector(String name, ConnectorArgs args, CustomResourceOptions options)
type: azure-native:costmanagement:Connector
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ConnectorArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ConnectorArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ConnectorArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ConnectorArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ConnectorArgs
- 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 azure_nativeConnectorResource = new AzureNative.CostManagement.Connector("azure-nativeConnectorResource", new()
{
    ResourceGroupName = "string",
    ConnectorName = "string",
    CredentialsKey = "string",
    CredentialsSecret = "string",
    DisplayName = "string",
    Kind = "string",
    Location = "string",
    ReportId = "string",
    Status = "string",
    Tags = 
    {
        { "string", "string" },
    },
});
example, err := costmanagement.NewConnector(ctx, "azure-nativeConnectorResource", &costmanagement.ConnectorArgs{
	ResourceGroupName: pulumi.String("string"),
	ConnectorName:     pulumi.String("string"),
	CredentialsKey:    pulumi.String("string"),
	CredentialsSecret: pulumi.String("string"),
	DisplayName:       pulumi.String("string"),
	Kind:              pulumi.String("string"),
	Location:          pulumi.String("string"),
	ReportId:          pulumi.String("string"),
	Status:            pulumi.String("string"),
	Tags: pulumi.StringMap{
		"string": pulumi.String("string"),
	},
})
var azure_nativeConnectorResource = new Connector("azure-nativeConnectorResource", ConnectorArgs.builder()
    .resourceGroupName("string")
    .connectorName("string")
    .credentialsKey("string")
    .credentialsSecret("string")
    .displayName("string")
    .kind("string")
    .location("string")
    .reportId("string")
    .status("string")
    .tags(Map.of("string", "string"))
    .build());
azure_native_connector_resource = azure_native.costmanagement.Connector("azure-nativeConnectorResource",
    resource_group_name="string",
    connector_name="string",
    credentials_key="string",
    credentials_secret="string",
    display_name="string",
    kind="string",
    location="string",
    report_id="string",
    status="string",
    tags={
        "string": "string",
    })
const azure_nativeConnectorResource = new azure_native.costmanagement.Connector("azure-nativeConnectorResource", {
    resourceGroupName: "string",
    connectorName: "string",
    credentialsKey: "string",
    credentialsSecret: "string",
    displayName: "string",
    kind: "string",
    location: "string",
    reportId: "string",
    status: "string",
    tags: {
        string: "string",
    },
});
type: azure-native:costmanagement:Connector
properties:
    connectorName: string
    credentialsKey: string
    credentialsSecret: string
    displayName: string
    kind: string
    location: string
    reportId: string
    resourceGroupName: string
    status: string
    tags:
        string: string
Connector 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 Connector resource accepts the following input properties:
- ResourceGroup stringName 
- Azure Resource Group Name.
- ConnectorName string
- Connector Name.
- CredentialsKey string
- Credentials authentication key (eg AWS ARN)
- CredentialsSecret string
- Credentials secret (eg AWS ExternalId)
- DisplayName string
- Connector DisplayName (defaults to Name)
- Kind string
- Connector kind (eg aws)
- Location string
- Connector location
- ReportId string
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- Status
string | Pulumi.Azure Native. Cost Management. Connector Status 
- Connector status
- Dictionary<string, string>
- Resource tags.
- ResourceGroup stringName 
- Azure Resource Group Name.
- ConnectorName string
- Connector Name.
- CredentialsKey string
- Credentials authentication key (eg AWS ARN)
- CredentialsSecret string
- Credentials secret (eg AWS ExternalId)
- DisplayName string
- Connector DisplayName (defaults to Name)
- Kind string
- Connector kind (eg aws)
- Location string
- Connector location
- ReportId string
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- Status
string | ConnectorStatus 
- Connector status
- map[string]string
- Resource tags.
- resourceGroup StringName 
- Azure Resource Group Name.
- connectorName String
- Connector Name.
- credentialsKey String
- Credentials authentication key (eg AWS ARN)
- credentialsSecret String
- Credentials secret (eg AWS ExternalId)
- displayName String
- Connector DisplayName (defaults to Name)
- kind String
- Connector kind (eg aws)
- location String
- Connector location
- reportId String
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- status
String | ConnectorStatus 
- Connector status
- Map<String,String>
- Resource tags.
- resourceGroup stringName 
- Azure Resource Group Name.
- connectorName string
- Connector Name.
- credentialsKey string
- Credentials authentication key (eg AWS ARN)
- credentialsSecret string
- Credentials secret (eg AWS ExternalId)
- displayName string
- Connector DisplayName (defaults to Name)
- kind string
- Connector kind (eg aws)
- location string
- Connector location
- reportId string
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- status
string | ConnectorStatus 
- Connector status
- {[key: string]: string}
- Resource tags.
- resource_group_ strname 
- Azure Resource Group Name.
- connector_name str
- Connector Name.
- credentials_key str
- Credentials authentication key (eg AWS ARN)
- credentials_secret str
- Credentials secret (eg AWS ExternalId)
- display_name str
- Connector DisplayName (defaults to Name)
- kind str
- Connector kind (eg aws)
- location str
- Connector location
- report_id str
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- status
str | ConnectorStatus 
- Connector status
- Mapping[str, str]
- Resource tags.
- resourceGroup StringName 
- Azure Resource Group Name.
- connectorName String
- Connector Name.
- credentialsKey String
- Credentials authentication key (eg AWS ARN)
- credentialsSecret String
- Credentials secret (eg AWS ExternalId)
- displayName String
- Connector DisplayName (defaults to Name)
- kind String
- Connector kind (eg aws)
- location String
- Connector location
- reportId String
- Identifying source report. (For AWS this is a CUR report name, defined with Daily and with Resources)
- status String | "active" | "error" | "suspended"
- Connector status
- Map<String>
- Resource tags.
Outputs
All input properties are implicitly available as output properties. Additionally, the Connector resource produces the following output properties:
- Collection
Pulumi.Azure Native. Cost Management. Outputs. Connector Collection Info Response 
- Collection information
- CreatedOn string
- Connector definition creation datetime
- Id string
- The provider-assigned unique ID for this managed resource.
- ModifiedOn string
- Connector last modified datetime
- Name string
- Connector name
- ProviderAccount stringId 
- Connector providerAccountId (determined from credentials)
- Type string
- Connector type
- Collection
ConnectorCollection Info Response 
- Collection information
- CreatedOn string
- Connector definition creation datetime
- Id string
- The provider-assigned unique ID for this managed resource.
- ModifiedOn string
- Connector last modified datetime
- Name string
- Connector name
- ProviderAccount stringId 
- Connector providerAccountId (determined from credentials)
- Type string
- Connector type
- collection
ConnectorCollection Info Response 
- Collection information
- createdOn String
- Connector definition creation datetime
- id String
- The provider-assigned unique ID for this managed resource.
- modifiedOn String
- Connector last modified datetime
- name String
- Connector name
- providerAccount StringId 
- Connector providerAccountId (determined from credentials)
- type String
- Connector type
- collection
ConnectorCollection Info Response 
- Collection information
- createdOn string
- Connector definition creation datetime
- id string
- The provider-assigned unique ID for this managed resource.
- modifiedOn string
- Connector last modified datetime
- name string
- Connector name
- providerAccount stringId 
- Connector providerAccountId (determined from credentials)
- type string
- Connector type
- collection
ConnectorCollection Info Response 
- Collection information
- created_on str
- Connector definition creation datetime
- id str
- The provider-assigned unique ID for this managed resource.
- modified_on str
- Connector last modified datetime
- name str
- Connector name
- provider_account_ strid 
- Connector providerAccountId (determined from credentials)
- type str
- Connector type
- collection Property Map
- Collection information
- createdOn String
- Connector definition creation datetime
- id String
- The provider-assigned unique ID for this managed resource.
- modifiedOn String
- Connector last modified datetime
- name String
- Connector name
- providerAccount StringId 
- Connector providerAccountId (determined from credentials)
- type String
- Connector type
Supporting Types
ConnectorCollectionErrorInfoResponse, ConnectorCollectionErrorInfoResponseArgs          
- ErrorCode string
- Short error message
- ErrorMessage string
- Detailed error message
- ErrorStart stringTime 
- Time the error started occurring (Last time error occurred in lastRun)
- ErrorInner stringMessage 
- External Provider error message
- ErrorCode string
- Short error message
- ErrorMessage string
- Detailed error message
- ErrorStart stringTime 
- Time the error started occurring (Last time error occurred in lastRun)
- ErrorInner stringMessage 
- External Provider error message
- errorCode String
- Short error message
- errorMessage String
- Detailed error message
- errorStart StringTime 
- Time the error started occurring (Last time error occurred in lastRun)
- errorInner StringMessage 
- External Provider error message
- errorCode string
- Short error message
- errorMessage string
- Detailed error message
- errorStart stringTime 
- Time the error started occurring (Last time error occurred in lastRun)
- errorInner stringMessage 
- External Provider error message
- error_code str
- Short error message
- error_message str
- Detailed error message
- error_start_ strtime 
- Time the error started occurring (Last time error occurred in lastRun)
- error_inner_ strmessage 
- External Provider error message
- errorCode String
- Short error message
- errorMessage String
- Detailed error message
- errorStart StringTime 
- Time the error started occurring (Last time error occurred in lastRun)
- errorInner StringMessage 
- External Provider error message
ConnectorCollectionInfoResponse, ConnectorCollectionInfoResponseArgs        
- LastRun string
- Last time the data acquisition process completed (even if no new data was found)
- LastUpdated string
- Last time the external data was updated into Azure
- SourceLast stringUpdated 
- Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
- Error
Pulumi.Azure Native. Cost Management. Inputs. Connector Collection Error Info Response 
- Error information of last collection
- LastChecked string
- Last time the data acquisition process initiated connecting to the external provider
- LastRun string
- Last time the data acquisition process completed (even if no new data was found)
- LastUpdated string
- Last time the external data was updated into Azure
- SourceLast stringUpdated 
- Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
- Error
ConnectorCollection Error Info Response 
- Error information of last collection
- LastChecked string
- Last time the data acquisition process initiated connecting to the external provider
- lastRun String
- Last time the data acquisition process completed (even if no new data was found)
- lastUpdated String
- Last time the external data was updated into Azure
- sourceLast StringUpdated 
- Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
- error
ConnectorCollection Error Info Response 
- Error information of last collection
- lastChecked String
- Last time the data acquisition process initiated connecting to the external provider
- lastRun string
- Last time the data acquisition process completed (even if no new data was found)
- lastUpdated string
- Last time the external data was updated into Azure
- sourceLast stringUpdated 
- Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
- error
ConnectorCollection Error Info Response 
- Error information of last collection
- lastChecked string
- Last time the data acquisition process initiated connecting to the external provider
- last_run str
- Last time the data acquisition process completed (even if no new data was found)
- last_updated str
- Last time the external data was updated into Azure
- source_last_ strupdated 
- Source timestamp of external data currently available in Azure (eg AWS last processed CUR file timestamp)
- error
ConnectorCollection Error Info Response 
- Error information of last collection
- last_checked str
- Last time the data acquisition process initiated connecting to the external provider
- lastRun String
- Last time the data acquisition process completed (even if no new data was found)
- lastUpdated String
- Last time the external data was updated into Azure
- sourceLast StringUpdated 
- 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
ConnectorStatus, ConnectorStatusArgs    
- Active
- active
- Error
- error
- Suspended
- suspended
- ConnectorStatus Active 
- active
- ConnectorStatus Error 
- error
- ConnectorStatus Suspended 
- suspended
- Active
- active
- Error
- error
- Suspended
- suspended
- Active
- active
- Error
- error
- Suspended
- suspended
- ACTIVE
- active
- ERROR
- error
- SUSPENDED
- suspended
- "active"
- active
- "error"
- error
- "suspended"
- suspended
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:costmanagement:Connector AWSBillingAccount /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.CostManagement/connectors/{connectorName} 
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0