1. Packages
  2. Azure Native
  3. API Docs
  4. azurestack
  5. CustomerSubscription
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.azurestack.CustomerSubscription

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

Customer subscription.

Uses Azure REST API version 2022-06-01. In version 2.x of the Azure Native provider, it used API version 2022-06-01.

Other available API versions: 2020-06-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native azurestack [ApiVersion]. See the version guide for details.

Example Usage

Creates a new customer subscription under a registration.

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

return await Deployment.RunAsync(() => 
{
    var customerSubscription = new AzureNative.AzureStack.CustomerSubscription("customerSubscription", new()
    {
        CustomerSubscriptionName = "E09A4E93-29A7-4EBA-A6D4-76202383F07F",
        RegistrationName = "testregistration",
        ResourceGroup = "azurestack",
        TenantId = "dbab3982-796f-4d03-9908-044c08aef8a2",
    });

});
Copy
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := azurestack.NewCustomerSubscription(ctx, "customerSubscription", &azurestack.CustomerSubscriptionArgs{
			CustomerSubscriptionName: pulumi.String("E09A4E93-29A7-4EBA-A6D4-76202383F07F"),
			RegistrationName:         pulumi.String("testregistration"),
			ResourceGroup:            pulumi.String("azurestack"),
			TenantId:                 pulumi.String("dbab3982-796f-4d03-9908-044c08aef8a2"),
		})
		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.azurestack.CustomerSubscription;
import com.pulumi.azurenative.azurestack.CustomerSubscriptionArgs;
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 customerSubscription = new CustomerSubscription("customerSubscription", CustomerSubscriptionArgs.builder()
            .customerSubscriptionName("E09A4E93-29A7-4EBA-A6D4-76202383F07F")
            .registrationName("testregistration")
            .resourceGroup("azurestack")
            .tenantId("dbab3982-796f-4d03-9908-044c08aef8a2")
            .build());

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

const customerSubscription = new azure_native.azurestack.CustomerSubscription("customerSubscription", {
    customerSubscriptionName: "E09A4E93-29A7-4EBA-A6D4-76202383F07F",
    registrationName: "testregistration",
    resourceGroup: "azurestack",
    tenantId: "dbab3982-796f-4d03-9908-044c08aef8a2",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

customer_subscription = azure_native.azurestack.CustomerSubscription("customerSubscription",
    customer_subscription_name="E09A4E93-29A7-4EBA-A6D4-76202383F07F",
    registration_name="testregistration",
    resource_group="azurestack",
    tenant_id="dbab3982-796f-4d03-9908-044c08aef8a2")
Copy
resources:
  customerSubscription:
    type: azure-native:azurestack:CustomerSubscription
    properties:
      customerSubscriptionName: E09A4E93-29A7-4EBA-A6D4-76202383F07F
      registrationName: testregistration
      resourceGroup: azurestack
      tenantId: dbab3982-796f-4d03-9908-044c08aef8a2
Copy

Create CustomerSubscription Resource

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

Constructor syntax

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

@overload
def CustomerSubscription(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         registration_name: Optional[str] = None,
                         resource_group: Optional[str] = None,
                         customer_subscription_name: Optional[str] = None,
                         tenant_id: Optional[str] = None)
func NewCustomerSubscription(ctx *Context, name string, args CustomerSubscriptionArgs, opts ...ResourceOption) (*CustomerSubscription, error)
public CustomerSubscription(string name, CustomerSubscriptionArgs args, CustomResourceOptions? opts = null)
public CustomerSubscription(String name, CustomerSubscriptionArgs args)
public CustomerSubscription(String name, CustomerSubscriptionArgs args, CustomResourceOptions options)
type: azure-native:azurestack:CustomerSubscription
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. CustomerSubscriptionArgs
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. CustomerSubscriptionArgs
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. CustomerSubscriptionArgs
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. CustomerSubscriptionArgs
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. CustomerSubscriptionArgs
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 customerSubscriptionResource = new AzureNative.AzureStack.CustomerSubscription("customerSubscriptionResource", new()
{
    RegistrationName = "string",
    ResourceGroup = "string",
    CustomerSubscriptionName = "string",
    TenantId = "string",
});
Copy
example, err := azurestack.NewCustomerSubscription(ctx, "customerSubscriptionResource", &azurestack.CustomerSubscriptionArgs{
	RegistrationName:         pulumi.String("string"),
	ResourceGroup:            pulumi.String("string"),
	CustomerSubscriptionName: pulumi.String("string"),
	TenantId:                 pulumi.String("string"),
})
Copy
var customerSubscriptionResource = new CustomerSubscription("customerSubscriptionResource", CustomerSubscriptionArgs.builder()
    .registrationName("string")
    .resourceGroup("string")
    .customerSubscriptionName("string")
    .tenantId("string")
    .build());
Copy
customer_subscription_resource = azure_native.azurestack.CustomerSubscription("customerSubscriptionResource",
    registration_name="string",
    resource_group="string",
    customer_subscription_name="string",
    tenant_id="string")
Copy
const customerSubscriptionResource = new azure_native.azurestack.CustomerSubscription("customerSubscriptionResource", {
    registrationName: "string",
    resourceGroup: "string",
    customerSubscriptionName: "string",
    tenantId: "string",
});
Copy
type: azure-native:azurestack:CustomerSubscription
properties:
    customerSubscriptionName: string
    registrationName: string
    resourceGroup: string
    tenantId: string
Copy

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

RegistrationName
This property is required.
Changes to this property will trigger replacement.
string
Name of the Azure Stack registration.
ResourceGroup
This property is required.
Changes to this property will trigger replacement.
string
Name of the resource group.
CustomerSubscriptionName Changes to this property will trigger replacement. string
Name of the product.
TenantId string
Tenant Id.
RegistrationName
This property is required.
Changes to this property will trigger replacement.
string
Name of the Azure Stack registration.
ResourceGroup
This property is required.
Changes to this property will trigger replacement.
string
Name of the resource group.
CustomerSubscriptionName Changes to this property will trigger replacement. string
Name of the product.
TenantId string
Tenant Id.
registrationName
This property is required.
Changes to this property will trigger replacement.
String
Name of the Azure Stack registration.
resourceGroup
This property is required.
Changes to this property will trigger replacement.
String
Name of the resource group.
customerSubscriptionName Changes to this property will trigger replacement. String
Name of the product.
tenantId String
Tenant Id.
registrationName
This property is required.
Changes to this property will trigger replacement.
string
Name of the Azure Stack registration.
resourceGroup
This property is required.
Changes to this property will trigger replacement.
string
Name of the resource group.
customerSubscriptionName Changes to this property will trigger replacement. string
Name of the product.
tenantId string
Tenant Id.
registration_name
This property is required.
Changes to this property will trigger replacement.
str
Name of the Azure Stack registration.
resource_group
This property is required.
Changes to this property will trigger replacement.
str
Name of the resource group.
customer_subscription_name Changes to this property will trigger replacement. str
Name of the product.
tenant_id str
Tenant Id.
registrationName
This property is required.
Changes to this property will trigger replacement.
String
Name of the Azure Stack registration.
resourceGroup
This property is required.
Changes to this property will trigger replacement.
String
Name of the resource group.
customerSubscriptionName Changes to this property will trigger replacement. String
Name of the product.
tenantId String
Tenant Id.

Outputs

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

AzureApiVersion string
The Azure API version of the resource.
Id string
The provider-assigned unique ID for this managed resource.
Name string
Name of the resource.
Type string
Type of Resource.
Etag string
The entity tag used for optimistic concurrency when modifying the resource.
AzureApiVersion string
The Azure API version of the resource.
Id string
The provider-assigned unique ID for this managed resource.
Name string
Name of the resource.
Type string
Type of Resource.
Etag string
The entity tag used for optimistic concurrency when modifying the resource.
azureApiVersion String
The Azure API version of the resource.
id String
The provider-assigned unique ID for this managed resource.
name String
Name of the resource.
type String
Type of Resource.
etag String
The entity tag used for optimistic concurrency when modifying the resource.
azureApiVersion string
The Azure API version of the resource.
id string
The provider-assigned unique ID for this managed resource.
name string
Name of the resource.
type string
Type of Resource.
etag string
The entity tag used for optimistic concurrency when modifying the resource.
azure_api_version str
The Azure API version of the resource.
id str
The provider-assigned unique ID for this managed resource.
name str
Name of the resource.
type str
Type of Resource.
etag str
The entity tag used for optimistic concurrency when modifying the resource.
azureApiVersion String
The Azure API version of the resource.
id String
The provider-assigned unique ID for this managed resource.
name String
Name of the resource.
type String
Type of Resource.
etag String
The entity tag used for optimistic concurrency when modifying the resource.

Import

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

$ pulumi import azure-native:azurestack:CustomerSubscription myresource1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.AzureStack/registrations/{registrationName}/customerSubscriptions/{customerSubscriptionName} 
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