1. Packages
  2. Azure Native v2
  3. API Docs
  4. automation
  5. Connection
These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi

azure-native-v2.automation.Connection

Explore with Pulumi AI

These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi

Definition of the connection. Azure REST API version: 2022-08-08. Prior API version in Azure Native 1.x: 2019-06-01.

Other available API versions: 2023-05-15-preview, 2023-11-01, 2024-10-23.

Example Usage

Create or update connection

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

return await Deployment.RunAsync(() => 
{
    var connection = new AzureNative.Automation.Connection("connection", new()
    {
        AutomationAccountName = "myAutomationAccount28",
        ConnectionName = "mysConnection",
        ConnectionType = new AzureNative.Automation.Inputs.ConnectionTypeAssociationPropertyArgs
        {
            Name = "Azure",
        },
        Description = "my description goes here",
        FieldDefinitionValues = 
        {
            { "AutomationCertificateName", "mysCertificateName" },
            { "SubscriptionID", "subid" },
        },
        Name = "mysConnection",
        ResourceGroupName = "rg",
    });

});
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := automation.NewConnection(ctx, "connection", &automation.ConnectionArgs{
			AutomationAccountName: pulumi.String("myAutomationAccount28"),
			ConnectionName:        pulumi.String("mysConnection"),
			ConnectionType: &automation.ConnectionTypeAssociationPropertyArgs{
				Name: pulumi.String("Azure"),
			},
			Description: pulumi.String("my description goes here"),
			FieldDefinitionValues: pulumi.StringMap{
				"AutomationCertificateName": pulumi.String("mysCertificateName"),
				"SubscriptionID":            pulumi.String("subid"),
			},
			Name:              pulumi.String("mysConnection"),
			ResourceGroupName: pulumi.String("rg"),
		})
		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.automation.Connection;
import com.pulumi.azurenative.automation.ConnectionArgs;
import com.pulumi.azurenative.automation.inputs.ConnectionTypeAssociationPropertyArgs;
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 connection = new Connection("connection", ConnectionArgs.builder()
            .automationAccountName("myAutomationAccount28")
            .connectionName("mysConnection")
            .connectionType(ConnectionTypeAssociationPropertyArgs.builder()
                .name("Azure")
                .build())
            .description("my description goes here")
            .fieldDefinitionValues(Map.ofEntries(
                Map.entry("AutomationCertificateName", "mysCertificateName"),
                Map.entry("SubscriptionID", "subid")
            ))
            .name("mysConnection")
            .resourceGroupName("rg")
            .build());

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

const connection = new azure_native.automation.Connection("connection", {
    automationAccountName: "myAutomationAccount28",
    connectionName: "mysConnection",
    connectionType: {
        name: "Azure",
    },
    description: "my description goes here",
    fieldDefinitionValues: {
        AutomationCertificateName: "mysCertificateName",
        SubscriptionID: "subid",
    },
    name: "mysConnection",
    resourceGroupName: "rg",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

connection = azure_native.automation.Connection("connection",
    automation_account_name="myAutomationAccount28",
    connection_name="mysConnection",
    connection_type={
        "name": "Azure",
    },
    description="my description goes here",
    field_definition_values={
        "AutomationCertificateName": "mysCertificateName",
        "SubscriptionID": "subid",
    },
    name="mysConnection",
    resource_group_name="rg")
Copy
resources:
  connection:
    type: azure-native:automation:Connection
    properties:
      automationAccountName: myAutomationAccount28
      connectionName: mysConnection
      connectionType:
        name: Azure
      description: my description goes here
      fieldDefinitionValues:
        AutomationCertificateName: mysCertificateName
        SubscriptionID: subid
      name: mysConnection
      resourceGroupName: rg
Copy

Create Connection Resource

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

Constructor syntax

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

@overload
def Connection(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               automation_account_name: Optional[str] = None,
               connection_type: Optional[ConnectionTypeAssociationPropertyArgs] = None,
               name: Optional[str] = None,
               resource_group_name: Optional[str] = None,
               connection_name: Optional[str] = None,
               description: Optional[str] = None,
               field_definition_values: Optional[Mapping[str, str]] = None)
func NewConnection(ctx *Context, name string, args ConnectionArgs, opts ...ResourceOption) (*Connection, error)
public Connection(string name, ConnectionArgs args, CustomResourceOptions? opts = null)
public Connection(String name, ConnectionArgs args)
public Connection(String name, ConnectionArgs args, CustomResourceOptions options)
type: azure-native:automation:Connection
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 This property is required. ConnectionArgs
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 This property is required. ConnectionArgs
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 This property is required. ConnectionArgs
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 This property is required. ConnectionArgs
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. ConnectionArgs
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 connectionResource = new AzureNative.Automation.Connection("connectionResource", new()
{
    AutomationAccountName = "string",
    ConnectionType = 
    {
        { "name", "string" },
    },
    Name = "string",
    ResourceGroupName = "string",
    ConnectionName = "string",
    Description = "string",
    FieldDefinitionValues = 
    {
        { "string", "string" },
    },
});
Copy
example, err := automation.NewConnection(ctx, "connectionResource", &automation.ConnectionArgs{
	AutomationAccountName: "string",
	ConnectionType: map[string]interface{}{
		"name": "string",
	},
	Name:              "string",
	ResourceGroupName: "string",
	ConnectionName:    "string",
	Description:       "string",
	FieldDefinitionValues: map[string]interface{}{
		"string": "string",
	},
})
Copy
var connectionResource = new Connection("connectionResource", ConnectionArgs.builder()
    .automationAccountName("string")
    .connectionType(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
    .name("string")
    .resourceGroupName("string")
    .connectionName("string")
    .description("string")
    .fieldDefinitionValues(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
    .build());
Copy
connection_resource = azure_native.automation.Connection("connectionResource",
    automation_account_name=string,
    connection_type={
        name: string,
    },
    name=string,
    resource_group_name=string,
    connection_name=string,
    description=string,
    field_definition_values={
        string: string,
    })
Copy
const connectionResource = new azure_native.automation.Connection("connectionResource", {
    automationAccountName: "string",
    connectionType: {
        name: "string",
    },
    name: "string",
    resourceGroupName: "string",
    connectionName: "string",
    description: "string",
    fieldDefinitionValues: {
        string: "string",
    },
});
Copy
type: azure-native:automation:Connection
properties:
    automationAccountName: string
    connectionName: string
    connectionType:
        name: string
    description: string
    fieldDefinitionValues:
        string: string
    name: string
    resourceGroupName: string
Copy

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

AutomationAccountName
This property is required.
Changes to this property will trigger replacement.
string
The name of the automation account.
ConnectionType This property is required. Pulumi.AzureNative.Automation.Inputs.ConnectionTypeAssociationProperty
Gets or sets the connectionType of the connection.
Name This property is required. string
Gets or sets the name of the connection.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
Name of an Azure Resource group.
ConnectionName Changes to this property will trigger replacement. string
The parameters supplied to the create or update connection operation.
Description string
Gets or sets the description of the connection.
FieldDefinitionValues Dictionary<string, string>
Gets or sets the field definition properties of the connection.
AutomationAccountName
This property is required.
Changes to this property will trigger replacement.
string
The name of the automation account.
ConnectionType This property is required. ConnectionTypeAssociationPropertyArgs
Gets or sets the connectionType of the connection.
Name This property is required. string
Gets or sets the name of the connection.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
Name of an Azure Resource group.
ConnectionName Changes to this property will trigger replacement. string
The parameters supplied to the create or update connection operation.
Description string
Gets or sets the description of the connection.
FieldDefinitionValues map[string]string
Gets or sets the field definition properties of the connection.
automationAccountName
This property is required.
Changes to this property will trigger replacement.
String
The name of the automation account.
connectionType This property is required. ConnectionTypeAssociationProperty
Gets or sets the connectionType of the connection.
name This property is required. String
Gets or sets the name of the connection.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
Name of an Azure Resource group.
connectionName Changes to this property will trigger replacement. String
The parameters supplied to the create or update connection operation.
description String
Gets or sets the description of the connection.
fieldDefinitionValues Map<String,String>
Gets or sets the field definition properties of the connection.
automationAccountName
This property is required.
Changes to this property will trigger replacement.
string
The name of the automation account.
connectionType This property is required. ConnectionTypeAssociationProperty
Gets or sets the connectionType of the connection.
name This property is required. string
Gets or sets the name of the connection.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
Name of an Azure Resource group.
connectionName Changes to this property will trigger replacement. string
The parameters supplied to the create or update connection operation.
description string
Gets or sets the description of the connection.
fieldDefinitionValues {[key: string]: string}
Gets or sets the field definition properties of the connection.
automation_account_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the automation account.
connection_type This property is required. ConnectionTypeAssociationPropertyArgs
Gets or sets the connectionType of the connection.
name This property is required. str
Gets or sets the name of the connection.
resource_group_name
This property is required.
Changes to this property will trigger replacement.
str
Name of an Azure Resource group.
connection_name Changes to this property will trigger replacement. str
The parameters supplied to the create or update connection operation.
description str
Gets or sets the description of the connection.
field_definition_values Mapping[str, str]
Gets or sets the field definition properties of the connection.
automationAccountName
This property is required.
Changes to this property will trigger replacement.
String
The name of the automation account.
connectionType This property is required. Property Map
Gets or sets the connectionType of the connection.
name This property is required. String
Gets or sets the name of the connection.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
Name of an Azure Resource group.
connectionName Changes to this property will trigger replacement. String
The parameters supplied to the create or update connection operation.
description String
Gets or sets the description of the connection.
fieldDefinitionValues Map<String>
Gets or sets the field definition properties of the connection.

Outputs

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

CreationTime string
Gets the creation time.
Id string
The provider-assigned unique ID for this managed resource.
LastModifiedTime string
Gets the last modified time.
Type string
The type of the resource.
CreationTime string
Gets the creation time.
Id string
The provider-assigned unique ID for this managed resource.
LastModifiedTime string
Gets the last modified time.
Type string
The type of the resource.
creationTime String
Gets the creation time.
id String
The provider-assigned unique ID for this managed resource.
lastModifiedTime String
Gets the last modified time.
type String
The type of the resource.
creationTime string
Gets the creation time.
id string
The provider-assigned unique ID for this managed resource.
lastModifiedTime string
Gets the last modified time.
type string
The type of the resource.
creation_time str
Gets the creation time.
id str
The provider-assigned unique ID for this managed resource.
last_modified_time str
Gets the last modified time.
type str
The type of the resource.
creationTime String
Gets the creation time.
id String
The provider-assigned unique ID for this managed resource.
lastModifiedTime String
Gets the last modified time.
type String
The type of the resource.

Supporting Types

ConnectionTypeAssociationProperty
, ConnectionTypeAssociationPropertyArgs

Name string
Gets or sets the name of the connection type.
Name string
Gets or sets the name of the connection type.
name String
Gets or sets the name of the connection type.
name string
Gets or sets the name of the connection type.
name str
Gets or sets the name of the connection type.
name String
Gets or sets the name of the connection type.

ConnectionTypeAssociationPropertyResponse
, ConnectionTypeAssociationPropertyResponseArgs

Name string
Gets or sets the name of the connection type.
Name string
Gets or sets the name of the connection type.
name String
Gets or sets the name of the connection type.
name string
Gets or sets the name of the connection type.
name str
Gets or sets the name of the connection type.
name String
Gets or sets the name of the connection type.

Import

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

$ pulumi import azure-native:automation:Connection mysConnection /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/connections/{connectionName} 
Copy

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

Package Details

Repository
azure-native-v2 pulumi/pulumi-azure-native
License
Apache-2.0
These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi