Error with creating enterprise policy for subnet injection
Identical to this issue (closed with no resolution provided) , I'm trying to create a power platform enterprise policy for subnet injection with Bicep. However, the deployment fails with the following error:
"Failed to create or update the enterprise policy, request body is null. (Code: InputValidationError)"
Bicep code for this is below (taken from here )
resource enterprisePolicy 'Microsoft.PowerPlatform/enterprisePolicies@2020-10-30-preview' = {
name: 'policyName'
location: 'UK'
kind: 'NetworkInjection'
properties: {
networkInjection: {
virtualNetworks: {
value: [
{
id: vNet.id
subnet: {
name: 'PPSubnet1'
}
}
{
id: vNet.id
subnet: {
name: 'PPSubnet2'
}
}
]
}
}
}
}
HI I am looking for the bicep code whcih can run enterprise policy to integrate powerapps with azure... I need to automate this please help em if you have it
Looks like the internal contract is
virtualNetworks: [
{
id: vNet.id
subnet: {
name: 'PPSubnet1'
}
},
{
id: vNet.id
subnet: {
name: 'PPSubnet2'
}
}
]
we are looking at why the docs and contract are different
looks like this is up to date already