-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathapi-management-policy.bicep
37 lines (33 loc) · 1.16 KB
/
api-management-policy.bicep
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
@description('Name of the API Management associated with the Policy.')
param apiManagementName string
@description('Name of the API to associate with the Policy.')
param apiName string
@description('Format of the Policy associated with the API Management resource.')
@allowed([
'rawxml'
'rawxml-link'
'xml'
'xml-link'
])
param format string
@description('Value of the Policy associated with the API Management resource.')
param value string
resource apiManagement 'Microsoft.ApiManagement/service@2023-09-01-preview' existing = {
name: apiManagementName
resource api 'apis@2023-09-01-preview' existing = {
name: apiName
resource policy 'policies@2023-09-01-preview' = {
name: 'policy'
properties: {
format: format
value: value
}
}
}
}
@description('The deployed API Management Policy resource.')
output resource resource = apiManagement::api::policy
@description('ID for the deployed API Management Policy resource.')
output id string = apiManagement::api::policy.id
@description('Name for the deployed API Management Policy resource.')
output name string = apiManagement::api::policy.name