@azure-tools/typespec-azure-resource-manager 0.43.0-dev.0 → 0.43.0-dev.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -35
- package/dist/src/common-types.d.ts +14 -3
- package/dist/src/common-types.d.ts.map +1 -1
- package/dist/src/common-types.js +133 -3
- package/dist/src/common-types.js.map +1 -1
- package/dist/src/commontypes.private.decorators.d.ts +44 -0
- package/dist/src/commontypes.private.decorators.d.ts.map +1 -0
- package/dist/src/commontypes.private.decorators.js +77 -0
- package/dist/src/commontypes.private.decorators.js.map +1 -0
- package/dist/src/index.d.ts +2 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +5 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/lib.d.ts +17 -2
- package/dist/src/lib.d.ts.map +1 -1
- package/dist/src/lib.js +6 -0
- package/dist/src/lib.js.map +1 -1
- package/dist/src/namespace.d.ts.map +1 -1
- package/dist/src/namespace.js +35 -0
- package/dist/src/namespace.js.map +1 -1
- package/dist/src/private.decorators.d.ts +1 -22
- package/dist/src/private.decorators.d.ts.map +1 -1
- package/dist/src/private.decorators.js +0 -149
- package/dist/src/private.decorators.js.map +1 -1
- package/dist/src/rules/arm-common-types-version.d.ts.map +1 -1
- package/dist/src/rules/arm-common-types-version.js +2 -3
- package/dist/src/rules/arm-common-types-version.js.map +1 -1
- package/dist/src/rules/arm-post-response-codes.d.ts.map +1 -1
- package/dist/src/rules/arm-post-response-codes.js.map +1 -1
- package/dist/src/rules/arm-resource-operation-response.d.ts.map +1 -1
- package/dist/src/rules/arm-resource-operation-response.js +3 -3
- package/dist/src/rules/arm-resource-operation-response.js.map +1 -1
- package/dist/src/rules/arm-resource-patch.d.ts.map +1 -1
- package/dist/src/rules/arm-resource-patch.js +2 -2
- package/dist/src/rules/arm-resource-patch.js.map +1 -1
- package/dist/src/rules/core-operations.js +1 -1
- package/dist/src/rules/core-operations.js.map +1 -1
- package/dist/src/rules/missing-x-ms-identifiers.js +1 -1
- package/dist/src/rules/missing-x-ms-identifiers.js.map +1 -1
- package/dist/src/rules/unsupported-type.d.ts.map +1 -1
- package/dist/src/rules/unsupported-type.js +4 -2
- package/dist/src/rules/unsupported-type.js.map +1 -1
- package/lib/arm.tsp +2 -9
- package/lib/backcompat.tsp +27 -0
- package/lib/common-types/common-types.tsp +11 -1
- package/lib/common-types/commontypes.private.decorators.tsp +43 -0
- package/lib/common-types/customer-managed-keys-ref.tsp +27 -0
- package/lib/common-types/customer-managed-keys.tsp +37 -46
- package/lib/common-types/extended-location-ref.tsp +1 -0
- package/lib/common-types/extended-location.tsp +15 -16
- package/lib/common-types/internal.tsp +24 -0
- package/lib/common-types/managed-identity-ref.tsp +79 -0
- package/lib/common-types/managed-identity.tsp +50 -72
- package/lib/common-types/private-links-ref.tsp +159 -0
- package/lib/common-types/private-links.tsp +55 -117
- package/lib/common-types/types-ref.tsp +414 -0
- package/lib/common-types/types.tsp +324 -202
- package/lib/decorators.tsp +1 -1
- package/lib/{arm.foundations.tsp → foundations/arm.foundations.tsp} +23 -21
- package/lib/foundations/backcompat.tsp +39 -0
- package/lib/{common-types/backcompat.tsp → foundations/deprecation.tsp} +11 -0
- package/lib/interfaces.tsp +0 -1
- package/lib/models.tsp +25 -2
- package/lib/operations.tsp +5 -32
- package/lib/parameters.tsp +14 -67
- package/lib/private.decorators.tsp +0 -38
- package/lib/responses.tsp +8 -17
- package/package.json +5 -7
package/lib/arm.tsp
CHANGED
|
@@ -3,17 +3,11 @@ import "@typespec/openapi";
|
|
|
3
3
|
import "@typespec/http";
|
|
4
4
|
import "@typespec/rest";
|
|
5
5
|
import "@typespec/versioning";
|
|
6
|
-
import "@azure-tools/typespec-autorest";
|
|
7
6
|
import "@azure-tools/typespec-azure-core";
|
|
8
7
|
|
|
9
|
-
import "./arm.foundations.tsp";
|
|
8
|
+
import "./foundations/arm.foundations.tsp";
|
|
10
9
|
import "./common-types/common-types.tsp";
|
|
11
|
-
import "./
|
|
12
|
-
import "./common-types/types.tsp";
|
|
13
|
-
import "./common-types/managed-identity.tsp";
|
|
14
|
-
import "./common-types/private-links.tsp";
|
|
15
|
-
import "./common-types/customer-managed-keys.tsp";
|
|
16
|
-
import "./common-types/extended-location.tsp";
|
|
10
|
+
import "./backcompat.tsp";
|
|
17
11
|
import "./private.decorators.tsp";
|
|
18
12
|
import "./models.tsp";
|
|
19
13
|
import "./operations.tsp";
|
|
@@ -26,7 +20,6 @@ using TypeSpec.Http;
|
|
|
26
20
|
using TypeSpec.Rest;
|
|
27
21
|
using TypeSpec.Versioning;
|
|
28
22
|
using TypeSpec.OpenAPI;
|
|
29
|
-
using Autorest;
|
|
30
23
|
using Azure.ResourceManager.Foundations;
|
|
31
24
|
|
|
32
25
|
@versioned(Azure.ResourceManager.Versions)
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
using Azure.ResourceManager.CommonTypes;
|
|
2
|
+
|
|
3
|
+
namespace Azure.ResourceManager;
|
|
4
|
+
|
|
5
|
+
// customer-managed-keys
|
|
6
|
+
alias InfrastructureEncryption = CommonTypes.InfrastructureEncryption;
|
|
7
|
+
alias KeyEncryptionIdentity = CommonTypes.KeyEncryptionKeyIdentity;
|
|
8
|
+
alias KeyEncryptionKeyIdentity = CommonTypes.KeyEncryptionKeyIdentity;
|
|
9
|
+
alias CustomerManagedKeyEncryption = CommonTypes.CustomerManagedKeyEncryption;
|
|
10
|
+
alias EncryptionConfiguration = CommonTypes.Encryption;
|
|
11
|
+
|
|
12
|
+
// private-links
|
|
13
|
+
alias PrivateEndpoint = CommonTypes.PrivateEndpoint;
|
|
14
|
+
alias PrivateEndpointConnection = CommonTypes.PrivateEndpointConnection;
|
|
15
|
+
alias PrivateEndpointConnectionProperties = CommonTypes.PrivateEndpointConnectionProperties;
|
|
16
|
+
alias PrivateLinkServiceConnectionState = CommonTypes.PrivateLinkServiceConnectionState;
|
|
17
|
+
alias PrivateEndpointConnectionProvisioningState = CommonTypes.PrivateEndpointConnectionProvisioningState;
|
|
18
|
+
alias PrivateEndpointServiceConnectionStatus = CommonTypes.PrivateEndpointServiceConnectionStatus;
|
|
19
|
+
alias PrivateEndpointConnectionParameter = CommonTypes.PrivateEndpointConnectionParameter;
|
|
20
|
+
alias PrivateLinkResource = CommonTypes.PrivateLinkResource;
|
|
21
|
+
alias PrivateLinkResourceProperties = CommonTypes.PrivateLinkResourceProperties;
|
|
22
|
+
alias PrivateLinkResourceParameter = CommonTypes.PrivateLinkResourceParameter;
|
|
23
|
+
alias PrivateEndpointConnectionResourceListResult = CommonTypes.PrivateEndpointConnectionListResult;
|
|
24
|
+
alias PrivateLinkResourceListResult = CommonTypes.PrivateLinkResourceListResult;
|
|
25
|
+
|
|
26
|
+
// types
|
|
27
|
+
alias ErrorResponse = CommonTypes.ErrorResponse;
|
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
import "@typespec/versioning";
|
|
2
|
+
import "@azure-tools/typespec-azure-core";
|
|
3
|
+
import "./common-types.tsp";
|
|
4
|
+
import "./types-ref.tsp";
|
|
5
|
+
import "./managed-identity-ref.tsp";
|
|
6
|
+
import "./private-links-ref.tsp";
|
|
7
|
+
import "./customer-managed-keys-ref.tsp";
|
|
8
|
+
import "./extended-location-ref.tsp";
|
|
9
|
+
import "./internal.tsp";
|
|
10
|
+
import "./commontypes.private.decorators.tsp";
|
|
2
11
|
|
|
3
12
|
using TypeSpec.Versioning;
|
|
4
13
|
|
|
14
|
+
@versioned(Versions)
|
|
5
15
|
namespace Azure.ResourceManager.CommonTypes;
|
|
6
16
|
|
|
7
|
-
@Private.armCommonTypesVersions
|
|
17
|
+
@CommonTypes.Private.armCommonTypesVersions
|
|
8
18
|
@doc("The Azure Resource Manager common-types versions.")
|
|
9
19
|
enum Versions {
|
|
10
20
|
@doc("The Azure Resource Manager v3 common types.")
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import "../../dist/src/commontypes.private.decorators.js";
|
|
2
|
+
|
|
3
|
+
namespace Azure.ResourceManager.CommonTypes.Private;
|
|
4
|
+
|
|
5
|
+
using TypeSpec.Reflection;
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Describes the shape of model literals accepted by the `version` parameter of
|
|
9
|
+
* the `armCommonDefinition` and `armCommonParameter` decorators.
|
|
10
|
+
*/
|
|
11
|
+
alias ArmCommonTypeVersionSpec = {
|
|
12
|
+
version: string | EnumMember;
|
|
13
|
+
isDefault: boolean;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* @param definitionName Definition name
|
|
18
|
+
* @param version Azure Resource Manager Version
|
|
19
|
+
* @param referenceFile Reference file
|
|
20
|
+
*/
|
|
21
|
+
extern dec armCommonDefinition(
|
|
22
|
+
target: Model,
|
|
23
|
+
definitionName?: valueof string,
|
|
24
|
+
version?: valueof EnumMember | ArmCommonTypeVersionSpec | string,
|
|
25
|
+
referenceFile?: valueof string
|
|
26
|
+
);
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* @param definitionName Definition name
|
|
30
|
+
* @param version Azure Resource Manager Version
|
|
31
|
+
* @param referenceFile Reference file
|
|
32
|
+
*/
|
|
33
|
+
extern dec armCommonParameter(
|
|
34
|
+
target: ModelProperty,
|
|
35
|
+
definitionName?: valueof string,
|
|
36
|
+
version?: valueof EnumMember | ArmCommonTypeVersionSpec | string,
|
|
37
|
+
referenceFile?: valueof string
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Marks an enum as representing the valid `common-types` versions.
|
|
42
|
+
*/
|
|
43
|
+
extern dec armCommonTypesVersions(target: Enum);
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import "./customer-managed-keys.tsp";
|
|
2
|
+
|
|
3
|
+
using Azure.ResourceManager.CommonTypes.Private;
|
|
4
|
+
|
|
5
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
6
|
+
|
|
7
|
+
@@armCommonDefinition(Encryption,
|
|
8
|
+
"encryption",
|
|
9
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v4, isDefault: true },
|
|
10
|
+
"customermanagedkeys.json"
|
|
11
|
+
);
|
|
12
|
+
@@armCommonDefinition(Encryption,
|
|
13
|
+
"encryption",
|
|
14
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
15
|
+
"customermanagedkeys.json"
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
@@armCommonDefinition(CustomerManagedKeyEncryption,
|
|
19
|
+
"customerManagedKeyEncryption",
|
|
20
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v4, isDefault: true },
|
|
21
|
+
"customermanagedkeys.json"
|
|
22
|
+
);
|
|
23
|
+
@@armCommonDefinition(CustomerManagedKeyEncryption,
|
|
24
|
+
"customerManagedKeyEncryption",
|
|
25
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
26
|
+
"customermanagedkeys.json"
|
|
27
|
+
);
|
|
@@ -1,84 +1,75 @@
|
|
|
1
1
|
using Azure.Core;
|
|
2
|
-
using
|
|
2
|
+
using TypeSpec.Versioning;
|
|
3
3
|
|
|
4
|
-
namespace Azure.ResourceManager;
|
|
4
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
/** (Optional) Discouraged to include in resource definition. Only needed where it is possible to disable platform (AKA infrastructure) encryption. Azure SQL TDE is an example of this. Values are enabled and disabled. */
|
|
7
|
+
@added(Versions.v4)
|
|
7
8
|
union InfrastructureEncryption {
|
|
8
|
-
|
|
9
|
+
/** Encryption is enabled */
|
|
9
10
|
Enabled: "enabled",
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
/** Encryption is disabled */
|
|
12
13
|
Disabled: "disabled",
|
|
13
14
|
|
|
14
15
|
string,
|
|
15
16
|
}
|
|
16
17
|
|
|
17
|
-
/**
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
union KeyEncryptionKeyIdentity {
|
|
22
|
-
@doc("System assigned identity")
|
|
18
|
+
/** The type of identity to use. */
|
|
19
|
+
@added(Versions.v4)
|
|
20
|
+
union KeyEncryptionKeyIdentityType {
|
|
21
|
+
/** System assigned identity */
|
|
23
22
|
SystemAssignedIdentity: "systemAssignedIdentity",
|
|
24
23
|
|
|
25
|
-
|
|
24
|
+
/** User assigned identity */
|
|
26
25
|
UserAssignedIdentity: "userAssignedIdentity",
|
|
27
26
|
|
|
28
|
-
|
|
27
|
+
/** Delegated identity */
|
|
29
28
|
DelegatedResourceIdentity: "delegatedResourceIdentity",
|
|
30
29
|
|
|
31
30
|
string,
|
|
32
31
|
}
|
|
33
32
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
33
|
+
/** All identity configuration for Customer-managed key settings defining which identity should be used to auth to Key Vault. */
|
|
34
|
+
@added(Versions.v4)
|
|
35
|
+
model KeyEncryptionKeyIdentity {
|
|
36
|
+
/** The type of identity to use. Values can be systemAssignedIdentity, userAssignedIdentity, or delegatedResourceIdentity. */
|
|
37
|
+
identityType?: KeyEncryptionKeyIdentityType;
|
|
38
38
|
|
|
39
|
-
|
|
39
|
+
/** User assigned identity to use for accessing key encryption key Url. Ex: /subscriptions/fa5fc227-a624-475e-b696-cdd604c735bc/resourceGroups/<resource group>/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myId. Mutually exclusive with identityType systemAssignedIdentity. */
|
|
40
40
|
userAssignedIdentityResourceId?: Azure.Core.armResourceIdentifier<[
|
|
41
41
|
{
|
|
42
42
|
type: "Microsoft.ManagedIdentity/userAssignedIdentities";
|
|
43
43
|
}
|
|
44
44
|
]>;
|
|
45
45
|
|
|
46
|
-
|
|
46
|
+
/** application client identity to use for accessing key encryption key Url in a different tenant. Ex: f83c6b1b-4d34-47e4-bb34-9d83df58b540 */
|
|
47
|
+
@added(Versions.v5)
|
|
47
48
|
federatedClientId?: uuid;
|
|
48
49
|
|
|
49
|
-
|
|
50
|
+
/** delegated identity to use for accessing key encryption key Url. Ex: /subscriptions/fa5fc227-a624-475e-b696-cdd604c735bc/resourceGroups/<resource group>/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myId. Mutually exclusive with identityType systemAssignedIdentity and userAssignedIdentity - internal use only. */
|
|
50
51
|
delegatedIdentityClientId?: uuid;
|
|
51
52
|
}
|
|
52
53
|
|
|
53
|
-
|
|
54
|
-
@
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
)
|
|
59
|
-
model EncryptionConfiguration {
|
|
60
|
-
@doc("Indicates if infrastructure encryption is enabled or disabled.")
|
|
61
|
-
infrastructureEncryption?: InfrastructureEncryption;
|
|
62
|
-
|
|
63
|
-
@doc("All customer-managed key encryption properties for the resource.")
|
|
64
|
-
customerManagedKeyEncryption?: CustomerManagedKeyEncryption;
|
|
54
|
+
/** Customer-managed key encryption properties for the resource. */
|
|
55
|
+
@added(Versions.v4)
|
|
56
|
+
model CustomerManagedKeyEncryption {
|
|
57
|
+
/** All identity configuration for Customer-managed key settings defining which identity should be used to auth to Key Vault. */
|
|
58
|
+
keyEncryptionKeyIdentity?: KeyEncryptionKeyIdentity;
|
|
65
59
|
|
|
66
|
-
|
|
60
|
+
/** key encryption key Url, versioned or non-versioned. Ex: https://contosovault.vault.azure.net/keys/contosokek/562a4bb76b524a1493a6afe8e536ee78 or https://contosovault.vault.azure.net/keys/contosokek. */
|
|
67
61
|
keyEncryptionKeyUrl?: string;
|
|
68
62
|
}
|
|
69
63
|
|
|
70
|
-
/**
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
*
|
|
74
|
-
* ```typespec
|
|
75
|
-
* model Foo is TrackedResource<FooProperties> {
|
|
76
|
-
* ...Encryption;
|
|
77
|
-
* }
|
|
78
|
-
* ```
|
|
79
|
-
*/
|
|
80
|
-
@doc("All encryption configuration for a resource.")
|
|
64
|
+
/** (Optional) Discouraged to include in resource definition. Only needed where it is possible to disable platform (AKA infrastructure) encryption. Azure SQL TDE is an example of this. Values are enabled and disabled. */
|
|
65
|
+
@added(Versions.v4)
|
|
66
|
+
@encodedName("application/json", "encryption")
|
|
81
67
|
model Encryption {
|
|
82
|
-
|
|
83
|
-
|
|
68
|
+
/** Values are enabled and disabled. */
|
|
69
|
+
infrastructureEncryption?: InfrastructureEncryption;
|
|
70
|
+
|
|
71
|
+
/** All Customer-managed key encryption properties for the resource. */
|
|
72
|
+
@added(Versions.v4)
|
|
73
|
+
@removed(Versions.v5)
|
|
74
|
+
customerManagedKeyEncryption?: CustomerManagedKeyEncryption;
|
|
84
75
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "./extended-location.tsp";
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
namespace Azure.ResourceManager.
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
2
|
+
/** The complex type of the extended location. */
|
|
3
|
+
model ExtendedLocation {
|
|
4
|
+
/** The name of the extended location. */
|
|
5
|
+
name: string;
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
/** The type of the extended location. */
|
|
8
|
+
type: ExtendedLocationType;
|
|
9
|
+
}
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
/** The supported ExtendedLocation types. */
|
|
12
|
+
union ExtendedLocationType {
|
|
13
|
+
/** Azure Edge Zones location type */
|
|
14
|
+
EdgeZone: "EdgeZone",
|
|
15
15
|
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
/** Azure Custom Locations type */
|
|
17
|
+
CustomLocation: "CustomLocation",
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
}
|
|
19
|
+
string,
|
|
21
20
|
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* An internal enum to indicate the resource support for various path types
|
|
5
|
+
*/
|
|
6
|
+
enum ResourceHome {
|
|
7
|
+
@doc("The resource is bound to a tenant")
|
|
8
|
+
Tenant,
|
|
9
|
+
|
|
10
|
+
@doc("The resource is bound to a subscription")
|
|
11
|
+
Subscription,
|
|
12
|
+
|
|
13
|
+
@doc("The resource is bound to a location")
|
|
14
|
+
Location,
|
|
15
|
+
|
|
16
|
+
@doc("The resource is bound to a resource group")
|
|
17
|
+
ResourceGroup,
|
|
18
|
+
|
|
19
|
+
@doc("The resource is bound to an extension")
|
|
20
|
+
Extension,
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** Alias of keyEncryptionKeyIdentity for back compatibility. Please change to keyEncryptionKeyIdentity. */
|
|
24
|
+
alias KeyEncryptionIdentity = KeyEncryptionKeyIdentity;
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import "./managed-identity.tsp";
|
|
2
|
+
|
|
3
|
+
using Azure.ResourceManager.CommonTypes.Private;
|
|
4
|
+
|
|
5
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* The properties of the managed service identities assigned to this resource.
|
|
9
|
+
*/
|
|
10
|
+
@@armCommonDefinition(ManagedServiceIdentity,
|
|
11
|
+
"ManagedServiceIdentity",
|
|
12
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v3, isDefault: true },
|
|
13
|
+
"managedidentity.json"
|
|
14
|
+
);
|
|
15
|
+
@@armCommonDefinition(ManagedServiceIdentity,
|
|
16
|
+
"ManagedServiceIdentity",
|
|
17
|
+
Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
18
|
+
"managedidentity.json"
|
|
19
|
+
);
|
|
20
|
+
@@armCommonDefinition(ManagedServiceIdentity,
|
|
21
|
+
"ManagedServiceIdentity",
|
|
22
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
23
|
+
"managedidentity.json"
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
/** The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests.", */
|
|
27
|
+
@@armCommonDefinition(UserAssignedIdentities,
|
|
28
|
+
"UserAssignedIdentities",
|
|
29
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v3, isDefault: true },
|
|
30
|
+
"managedidentity.json"
|
|
31
|
+
);
|
|
32
|
+
@@armCommonDefinition(UserAssignedIdentities,
|
|
33
|
+
"UserAssignedIdentities",
|
|
34
|
+
Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
35
|
+
"managedidentity.json"
|
|
36
|
+
);
|
|
37
|
+
@@armCommonDefinition(UserAssignedIdentities,
|
|
38
|
+
"UserAssignedIdentities",
|
|
39
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
40
|
+
"managedidentity.json"
|
|
41
|
+
);
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* The properties of the service-assigned identity associated with this resource.
|
|
45
|
+
*/
|
|
46
|
+
@@armCommonDefinition(SystemAssignedServiceIdentity,
|
|
47
|
+
"SystemAssignedServiceIdentity",
|
|
48
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v3, isDefault: true },
|
|
49
|
+
"managedidentity.json"
|
|
50
|
+
);
|
|
51
|
+
@@armCommonDefinition(SystemAssignedServiceIdentity,
|
|
52
|
+
"SystemAssignedServiceIdentity",
|
|
53
|
+
Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
54
|
+
"managedidentity.json"
|
|
55
|
+
);
|
|
56
|
+
@@armCommonDefinition(SystemAssignedServiceIdentity,
|
|
57
|
+
"SystemAssignedServiceIdentity",
|
|
58
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
59
|
+
"managedidentity.json"
|
|
60
|
+
);
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* A managed identity assigned by the user.
|
|
64
|
+
*/
|
|
65
|
+
@@armCommonDefinition(UserAssignedIdentity,
|
|
66
|
+
"UserAssignedIdentity",
|
|
67
|
+
#{ version: Azure.ResourceManager.CommonTypes.Versions.v3, isDefault: true },
|
|
68
|
+
"managedidentity.json"
|
|
69
|
+
);
|
|
70
|
+
@@armCommonDefinition(UserAssignedIdentity,
|
|
71
|
+
"UserAssignedIdentity",
|
|
72
|
+
Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
73
|
+
"managedidentity.json"
|
|
74
|
+
);
|
|
75
|
+
@@armCommonDefinition(UserAssignedIdentity,
|
|
76
|
+
"UserAssignedIdentity",
|
|
77
|
+
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
78
|
+
"managedidentity.json"
|
|
79
|
+
);
|
|
@@ -1,122 +1,100 @@
|
|
|
1
|
-
using Azure.
|
|
1
|
+
using Azure.Core;
|
|
2
|
+
using TypeSpec.Versioning;
|
|
2
3
|
|
|
3
|
-
namespace Azure.ResourceManager.
|
|
4
|
+
namespace Azure.ResourceManager.CommonTypes;
|
|
5
|
+
|
|
6
|
+
/** The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests. */
|
|
7
|
+
#deprecated "Do not use this model. Instead, use Record<UserAssignedIdentity> directly. Using this model will result in a different client SDK when generated from TypeSpec compared to the Swagger."
|
|
8
|
+
model UserAssignedIdentities is Record<UserAssignedIdentity>;
|
|
4
9
|
|
|
5
|
-
#deprecated "Please change ManagedIdentityProperties to ManagedServiceIdentity."
|
|
6
|
-
alias ManagedIdentityProperties = ManagedServiceIdentity;
|
|
7
10
|
/**
|
|
8
|
-
*
|
|
11
|
+
* Managed service identity (system assigned and/or user assigned identities)
|
|
9
12
|
*/
|
|
10
|
-
@armCommonDefinition(
|
|
11
|
-
"ManagedServiceIdentity",
|
|
12
|
-
{
|
|
13
|
-
version: Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
14
|
-
isDefault: true,
|
|
15
|
-
},
|
|
16
|
-
"managedidentity.json"
|
|
17
|
-
)
|
|
18
|
-
@armCommonDefinition(
|
|
19
|
-
"ManagedServiceIdentity",
|
|
20
|
-
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
21
|
-
"managedidentity.json"
|
|
22
|
-
)
|
|
23
13
|
model ManagedServiceIdentity {
|
|
24
|
-
|
|
14
|
+
/** The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity. */
|
|
25
15
|
@visibility("read")
|
|
26
|
-
|
|
16
|
+
principalId?: uuid;
|
|
27
17
|
|
|
28
|
-
|
|
18
|
+
/** The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. */
|
|
29
19
|
@visibility("read")
|
|
30
|
-
|
|
20
|
+
tenantId?: uuid;
|
|
31
21
|
|
|
32
|
-
|
|
22
|
+
/** The type of managed identity assigned to this resource. */
|
|
33
23
|
type: ManagedServiceIdentityType;
|
|
34
24
|
|
|
35
|
-
|
|
36
|
-
|
|
25
|
+
/** The identities assigned to this resource by the user. */
|
|
26
|
+
@typeChangedFrom(Versions.v5, Record<UserAssignedIdentity>)
|
|
27
|
+
userAssignedIdentities?: Record<UserAssignedIdentity> | null;
|
|
37
28
|
}
|
|
38
29
|
|
|
39
|
-
/** The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests.", */
|
|
40
|
-
model UserAssignedIdentities is Record<UserAssignedIdentity>;
|
|
41
|
-
|
|
42
|
-
#deprecated "Please change ManagedSystemIdentityProperties to SystemAssignedServiceIdentity."
|
|
43
|
-
alias ManagedSystemIdentityProperties = SystemAssignedServiceIdentity;
|
|
44
30
|
/**
|
|
45
|
-
*
|
|
31
|
+
* Managed service identity (either system assigned, or none)
|
|
46
32
|
*/
|
|
47
|
-
@armCommonDefinition(
|
|
48
|
-
"SystemAssignedServiceIdentity",
|
|
49
|
-
{
|
|
50
|
-
version: Azure.ResourceManager.CommonTypes.Versions.v4,
|
|
51
|
-
isDefault: true,
|
|
52
|
-
},
|
|
53
|
-
"managedidentity.json"
|
|
54
|
-
)
|
|
55
|
-
@armCommonDefinition(
|
|
56
|
-
"SystemAssignedServiceIdentity",
|
|
57
|
-
Azure.ResourceManager.CommonTypes.Versions.v5,
|
|
58
|
-
"managedidentity.json"
|
|
59
|
-
)
|
|
60
33
|
model SystemAssignedServiceIdentity {
|
|
61
|
-
|
|
34
|
+
/** The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity. */
|
|
62
35
|
@visibility("read")
|
|
63
|
-
|
|
36
|
+
principalId?: uuid;
|
|
64
37
|
|
|
65
|
-
|
|
38
|
+
/** The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. */
|
|
66
39
|
@visibility("read")
|
|
67
|
-
|
|
40
|
+
tenantId?: uuid;
|
|
68
41
|
|
|
69
|
-
|
|
42
|
+
/** The type of managed identity assigned to this resource. */
|
|
70
43
|
type: SystemAssignedServiceIdentityType;
|
|
71
44
|
}
|
|
72
45
|
|
|
73
|
-
/** Alias of ManagedServiceIdentityType for back compatability. Please change to ManagedServiceIdentityType. */
|
|
74
|
-
#deprecated "Please change to ManagedServiceIdentityType."
|
|
75
|
-
alias ManagedIdentityType = ManagedServiceIdentityType;
|
|
76
46
|
/**
|
|
77
|
-
*
|
|
47
|
+
* User assigned identity properties
|
|
78
48
|
*/
|
|
79
|
-
@doc("A managed identity assigned by the user.")
|
|
80
49
|
model UserAssignedIdentity {
|
|
81
|
-
|
|
82
|
-
|
|
50
|
+
/** The principal ID of the assigned identity. */
|
|
51
|
+
@visibility("read")
|
|
52
|
+
principalId?: uuid;
|
|
83
53
|
|
|
84
|
-
|
|
85
|
-
|
|
54
|
+
/** The client ID of the assigned identity. */
|
|
55
|
+
@visibility("read")
|
|
56
|
+
clientId?: uuid;
|
|
86
57
|
}
|
|
87
58
|
|
|
88
59
|
/**
|
|
89
|
-
*
|
|
60
|
+
* Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).
|
|
90
61
|
*/
|
|
91
|
-
@doc("The kind of managed identity assigned to this resource.")
|
|
92
62
|
union ManagedServiceIdentityType {
|
|
93
|
-
|
|
63
|
+
/** No managed identity. */
|
|
94
64
|
None: "None",
|
|
95
65
|
|
|
96
|
-
|
|
66
|
+
/** System assigned managed identity. */
|
|
97
67
|
SystemAssigned: "SystemAssigned",
|
|
98
68
|
|
|
99
|
-
|
|
69
|
+
/** User assigned managed identity. */
|
|
100
70
|
UserAssigned: "UserAssigned",
|
|
101
71
|
|
|
102
|
-
|
|
103
|
-
|
|
72
|
+
/** System and user assigned managed identity. */
|
|
73
|
+
@renamedFrom(Versions.v3, "SystemAndUserAssigned")
|
|
74
|
+
@removed(Versions.v4)
|
|
75
|
+
SystemAndUserAssignedV3: "SystemAssigned,UserAssigned",
|
|
76
|
+
|
|
77
|
+
/** System and user assigned managed identity. */
|
|
78
|
+
@added(Versions.v4)
|
|
79
|
+
@renamedFrom(Versions.v4, "SystemAndUserAssigned")
|
|
80
|
+
@removed(Versions.v5)
|
|
81
|
+
SystemAndUserAssignedV4: "SystemAssigned, UserAssigned",
|
|
82
|
+
|
|
83
|
+
/** System and user assigned managed identity. */
|
|
84
|
+
@added(Versions.v5)
|
|
85
|
+
SystemAndUserAssigned: "SystemAssigned,UserAssigned",
|
|
104
86
|
|
|
105
87
|
string,
|
|
106
88
|
}
|
|
107
89
|
|
|
108
|
-
/** Alias of SystemAssignedServiceIdentityType for back compatability. Please change to SystemAssignedServiceIdentityType. */
|
|
109
|
-
alias ManagedSystemIdentityType = SystemAssignedServiceIdentityType;
|
|
110
|
-
|
|
111
90
|
/**
|
|
112
|
-
*
|
|
91
|
+
* Type of managed service identity (either system assigned, or none).
|
|
113
92
|
*/
|
|
114
|
-
@doc("The kind of managemed identity assigned to this resource.")
|
|
115
93
|
union SystemAssignedServiceIdentityType {
|
|
116
|
-
|
|
94
|
+
/** No managed system identity. */
|
|
117
95
|
None: "None",
|
|
118
96
|
|
|
119
|
-
|
|
97
|
+
/** System assigned managed system identity. */
|
|
120
98
|
SystemAssigned: "SystemAssigned",
|
|
121
99
|
|
|
122
100
|
string,
|