Skip to content

Commit 8129f42

Browse files
author
Qian Wen
committed
updating sample code in 3 and 4
1 parent c61e7b7 commit 8129f42

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

articles/marketplace/partner-center-portal/marketplace-metering-service-authentication.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,10 +140,10 @@ For example, this is how to authenticate using a Windows VM,
140140

141141
```json
142142
# Get resourceUsageId from the Managed App
143-
$managedAppUrl = "https://management.azure.com/subscriptions/" + $metadata.compute.subscriptionId + "/resourceGroups/" + $metadata.compute.resourceGroupName + /providers/Microsoft.Solutions/applications/" + $managedappId <ManagedAppName>+ "\?api-version=2019-07-01"
144-
$ManagedApp = curl $managedAppUrl Url -H $Headers | Select-Object -Expand Content | ConvertFrom-Json
143+
$managedAppUrl = "https://management.azure.com/subscriptions/" + $metadata.compute.subscriptionId + "/resourceGroups/" + $metadata.compute.resourceGroupName + "/providers/Microsoft.Solutions/applications/" + $managedappId + "\?api-version=2019-07-01"
144+
$ManagedApp = curl $managedAppUrl -H $Headers | Select-Object -Expand Content | ConvertFrom-Json
145145
# Use this resource ID to emit usage
146-
$resourceUsageId = $ManagedApp.properties.billingDetails.resourceUsageId
146+
$resourceUsageId = $ManagedApp.properties.billingDetails.resourceUsageId
147147
```
148148

149149
1. Use the [Marketplace metering service API](https://review.docs.microsoft.com/azure/marketplace/partner-center-portal/marketplace-metering-service-apis?branch=pr-en-us-101847) to emit usage

0 commit comments

Comments
 (0)