Module cosmosdb

@pulumi/azure > cosmosdb

Index

cosmosdb/account.ts cosmosdb/getAccount.ts

class Account

Manages a CosmosDB (formally DocumentDB) Account.

constructor

new Account(name: string, args: AccountArgs, opts?: pulumi.CustomResourceOptions)

Create a Account resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AccountState): Account

Get an existing Account resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

static isInstance(obj: any): boolean

Returns true if the given object is an instance of CustomResource. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property capabilities

public capabilities: pulumi.Output<{ ... }[] | undefined>;

Enable capabilities for this Cosmos DB account. Possible values are EnableTable and EnableGremlin.

property connectionStrings

public connectionStrings: pulumi.Output<string[]>;

A list of connection strings available for this CosmosDB account. If the kind is GlobalDocumentDB, this will be empty.

property consistencyPolicy

public consistencyPolicy: pulumi.Output<{ ... }>;

Specifies a consistency_policy resource, used to define the consistency policy for this CosmosDB account.

property enableAutomaticFailover

public enableAutomaticFailover: pulumi.Output<boolean | undefined>;

Enable automatic fail over for this Cosmos DB account.

property enableMultipleWriteLocations

public enableMultipleWriteLocations: pulumi.Output<boolean | undefined>;

Enable multi-master support for this Cosmos DB account.

property endpoint

public endpoint: pulumi.Output<string>;

The endpoint used to connect to the CosmosDB account.

property failoverPolicies

public failoverPolicies: pulumi.Output<{ ... }[] | undefined>;

property geoLocations

public geoLocations: pulumi.Output<{ ... }[]>;

Specifies a geo_location resource, used to define where data should be replicated with the failover_priority 0 specifying the primary location.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property ipRangeFilter

public ipRangeFilter: pulumi.Output<string | undefined>;

CosmosDB Firewall Support: This value specifies the set of IP addresses or IP address ranges in CIDR form to be included as the allowed list of client IP’s for a given database account. IP addresses/ranges must be comma separated and must not contain any spaces.

property isVirtualNetworkFilterEnabled

public isVirtualNetworkFilterEnabled: pulumi.Output<boolean | undefined>;

Enables virtual network filtering for this Cosmos DB account.

property kind

public kind: pulumi.Output<string | undefined>;

Specifies the Kind of CosmosDB to create - possible values are GlobalDocumentDB and MongoDB. Defaults to GlobalDocumentDB. Changing this forces a new resource to be created.

property location

public location: pulumi.Output<string>;

The name of the Azure region to host replicated data.

property name

public name: pulumi.Output<string>;

Specifies the name of the CosmosDB Account. Changing this forces a new resource to be created.

property offerType

public offerType: pulumi.Output<string>;

Specifies the Offer Type to use for this CosmosDB Account - currently this can only be set to Standard.

property primaryMasterKey

public primaryMasterKey: pulumi.Output<string>;

The Primary master key for the CosmosDB Account.

property primaryReadonlyMasterKey

public primaryReadonlyMasterKey: pulumi.Output<string>;

The Primary read-only master Key for the CosmosDB Account.

property readEndpoints

public readEndpoints: pulumi.Output<string[]>;

A list of read endpoints available for this CosmosDB account.

property resourceGroupName

public resourceGroupName: pulumi.Output<string>;

The name of the resource group in which the CosmosDB Account is created. Changing this forces a new resource to be created.

property secondaryMasterKey

public secondaryMasterKey: pulumi.Output<string>;

The Secondary master key for the CosmosDB Account.

property secondaryReadonlyMasterKey

public secondaryReadonlyMasterKey: pulumi.Output<string>;

The Secondary read-only master key for the CosmosDB Account.

property tags

public tags: pulumi.Output<{ ... }>;

A mapping of tags to assign to the resource.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property virtualNetworkRules

public virtualNetworkRules: pulumi.Output<{ ... }[] | undefined>;

Specifies a virtual_network_rules resource, used to define which subnets are allowed to access this CosmosDB account.

property writeEndpoints

public writeEndpoints: pulumi.Output<string[]>;

A list of write endpoints available for this CosmosDB account.

function getAccount

getAccount(args: GetAccountArgs, opts?: pulumi.InvokeOptions): Promise<GetAccountResult>

Use this data source to access information about an existing CosmosDB (formally DocumentDB) Account.

interface AccountArgs

The set of arguments for constructing a Account resource.

property capabilities

capabilities?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Enable capabilities for this Cosmos DB account. Possible values are EnableTable and EnableGremlin.

property consistencyPolicy

consistencyPolicy: pulumi.Input<{ ... }>;

Specifies a consistency_policy resource, used to define the consistency policy for this CosmosDB account.

property enableAutomaticFailover

enableAutomaticFailover?: pulumi.Input<boolean>;

Enable automatic fail over for this Cosmos DB account.

property enableMultipleWriteLocations

enableMultipleWriteLocations?: pulumi.Input<boolean>;

Enable multi-master support for this Cosmos DB account.

property failoverPolicies

failoverPolicies?: pulumi.Input<pulumi.Input<{ ... }>[]>;

property geoLocations

geoLocations?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Specifies a geo_location resource, used to define where data should be replicated with the failover_priority 0 specifying the primary location.

property ipRangeFilter

ipRangeFilter?: pulumi.Input<string>;

CosmosDB Firewall Support: This value specifies the set of IP addresses or IP address ranges in CIDR form to be included as the allowed list of client IP’s for a given database account. IP addresses/ranges must be comma separated and must not contain any spaces.

property isVirtualNetworkFilterEnabled

isVirtualNetworkFilterEnabled?: pulumi.Input<boolean>;

Enables virtual network filtering for this Cosmos DB account.

property kind

kind?: pulumi.Input<string>;

Specifies the Kind of CosmosDB to create - possible values are GlobalDocumentDB and MongoDB. Defaults to GlobalDocumentDB. Changing this forces a new resource to be created.

property location

location: pulumi.Input<string>;

The name of the Azure region to host replicated data.

property name

name?: pulumi.Input<string>;

Specifies the name of the CosmosDB Account. Changing this forces a new resource to be created.

property offerType

offerType: pulumi.Input<string>;

Specifies the Offer Type to use for this CosmosDB Account - currently this can only be set to Standard.

property resourceGroupName

resourceGroupName: pulumi.Input<string>;

The name of the resource group in which the CosmosDB Account is created. Changing this forces a new resource to be created.

property tags

tags?: pulumi.Input<{ ... }>;

A mapping of tags to assign to the resource.

property virtualNetworkRules

virtualNetworkRules?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Specifies a virtual_network_rules resource, used to define which subnets are allowed to access this CosmosDB account.

interface AccountState

Input properties used for looking up and filtering Account resources.

property capabilities

capabilities?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Enable capabilities for this Cosmos DB account. Possible values are EnableTable and EnableGremlin.

property connectionStrings

connectionStrings?: pulumi.Input<pulumi.Input<string>[]>;

A list of connection strings available for this CosmosDB account. If the kind is GlobalDocumentDB, this will be empty.

property consistencyPolicy

consistencyPolicy?: pulumi.Input<{ ... }>;

Specifies a consistency_policy resource, used to define the consistency policy for this CosmosDB account.

property enableAutomaticFailover

enableAutomaticFailover?: pulumi.Input<boolean>;

Enable automatic fail over for this Cosmos DB account.

property enableMultipleWriteLocations

enableMultipleWriteLocations?: pulumi.Input<boolean>;

Enable multi-master support for this Cosmos DB account.

property endpoint

endpoint?: pulumi.Input<string>;

The endpoint used to connect to the CosmosDB account.

property failoverPolicies

failoverPolicies?: pulumi.Input<pulumi.Input<{ ... }>[]>;

property geoLocations

geoLocations?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Specifies a geo_location resource, used to define where data should be replicated with the failover_priority 0 specifying the primary location.

property ipRangeFilter

ipRangeFilter?: pulumi.Input<string>;

CosmosDB Firewall Support: This value specifies the set of IP addresses or IP address ranges in CIDR form to be included as the allowed list of client IP’s for a given database account. IP addresses/ranges must be comma separated and must not contain any spaces.

property isVirtualNetworkFilterEnabled

isVirtualNetworkFilterEnabled?: pulumi.Input<boolean>;

Enables virtual network filtering for this Cosmos DB account.

property kind

kind?: pulumi.Input<string>;

Specifies the Kind of CosmosDB to create - possible values are GlobalDocumentDB and MongoDB. Defaults to GlobalDocumentDB. Changing this forces a new resource to be created.

property location

location?: pulumi.Input<string>;

The name of the Azure region to host replicated data.

property name

name?: pulumi.Input<string>;

Specifies the name of the CosmosDB Account. Changing this forces a new resource to be created.

property offerType

offerType?: pulumi.Input<string>;

Specifies the Offer Type to use for this CosmosDB Account - currently this can only be set to Standard.

property primaryMasterKey

primaryMasterKey?: pulumi.Input<string>;

The Primary master key for the CosmosDB Account.

property primaryReadonlyMasterKey

primaryReadonlyMasterKey?: pulumi.Input<string>;

The Primary read-only master Key for the CosmosDB Account.

property readEndpoints

readEndpoints?: pulumi.Input<pulumi.Input<string>[]>;

A list of read endpoints available for this CosmosDB account.

property resourceGroupName

resourceGroupName?: pulumi.Input<string>;

The name of the resource group in which the CosmosDB Account is created. Changing this forces a new resource to be created.

property secondaryMasterKey

secondaryMasterKey?: pulumi.Input<string>;

The Secondary master key for the CosmosDB Account.

property secondaryReadonlyMasterKey

secondaryReadonlyMasterKey?: pulumi.Input<string>;

The Secondary read-only master key for the CosmosDB Account.

property tags

tags?: pulumi.Input<{ ... }>;

A mapping of tags to assign to the resource.

property virtualNetworkRules

virtualNetworkRules?: pulumi.Input<pulumi.Input<{ ... }>[]>;

Specifies a virtual_network_rules resource, used to define which subnets are allowed to access this CosmosDB account.

property writeEndpoints

writeEndpoints?: pulumi.Input<pulumi.Input<string>[]>;

A list of write endpoints available for this CosmosDB account.

interface GetAccountArgs

A collection of arguments for invoking getAccount.

property name

name: string;

Specifies the name of the CosmosDB Account.

property resourceGroupName

resourceGroupName: string;

Specifies the name of the resource group in which the CosmosDB Account resides.

interface GetAccountResult

A collection of values returned by getAccount.

property capabilities

capabilities: { ... }[];

Capabilities enabled on this Cosmos DB account.

property consistencyPolicies

consistencyPolicies: { ... }[];

property enableAutomaticFailover

enableAutomaticFailover: boolean;

If automatic failover is enabled for this CosmosDB Account.

property enableMultipleWriteLocations

enableMultipleWriteLocations: boolean;

If multi-master is enabled for this Cosmos DB account.

property endpoint

endpoint: string;

The endpoint used to connect to the CosmosDB account.

property geoLocations

geoLocations: { ... }[];

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property ipRangeFilter

ipRangeFilter: string;

The current IP Filter for this CosmosDB account

property isVirtualNetworkFilterEnabled

isVirtualNetworkFilterEnabled: boolean;

If virtual network filtering is enabled for this Cosmos DB account.

property kind

kind: string;

The Kind of the CosmosDB account.

property location

location: string;

The name of the Azure region hosting replicated data.

property offerType

offerType: string;

The Offer Type to used by this CosmosDB Account.

property primaryMasterKey

primaryMasterKey: string;

The Primary master key for the CosmosDB Account.

property primaryReadonlyMasterKey

primaryReadonlyMasterKey: string;

The Primary read-only master Key for the CosmosDB Account.

property readEndpoints

readEndpoints: string[];

A list of read endpoints available for this CosmosDB account.

property secondaryMasterKey

secondaryMasterKey: string;

The Secondary master key for the CosmosDB Account.

property secondaryReadonlyMasterKey

secondaryReadonlyMasterKey: string;

The Secondary read-only master key for the CosmosDB Account.

property tags

tags: { ... };

A mapping of tags assigned to the resource.

property virtualNetworkRules

virtualNetworkRules: { ... }[];

Subnets that are allowed to access this CosmosDB account.

property writeEndpoints

writeEndpoints: string[];

A list of write endpoints available for this CosmosDB account.