Carbon Service - List Carbon Emission Reports
API for Carbon Emissions Reports
POST https://management.azure.com/providers/Microsoft.Carbon/carbonEmissionReports?api-version=2023-04-01-preview
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
api-version
|
query | True |
string |
The API version to use for this operation. |
Request Body
The request body can be one of the following:
Name | Description |
---|---|
Item |
Query Parameters for Detailed carbon emissions by pageSize |
Monthly |
Query Parameters for Monthly Carbon Emissions Summary |
Overall |
Query Parameters for Overall Carbon Emissions Summary |
Top |
Query Parameters for Top Items Carbon Emissions by Month |
Top |
Query Parameters for Top Items Carbon Emission by Category Type |
ItemDetailsQueryFilter
Query Parameters for Detailed carbon emissions by pageSize
Name | Required | Type | Description |
---|---|---|---|
carbonScopeList | True |
Carbon emission scope for carbon emissions data |
|
categoryType | True |
Item Category type |
|
dateRange | True |
The start date and end date for carbon emissions data |
|
groupCategory | True |
string |
Group category name |
orderBy | True |
string |
Order by column name |
pageSize | True |
integer |
Number of items to return |
reportType | True |
string:
Item |
Report type |
sortDirection | True |
string |
Direction for sorting |
subscriptionList | True |
string[] |
SubscriptionId list for carbon emissions data |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
|
skipToken |
string |
The number of result items to skip |
MonthlySummaryReportQueryFilter
Query Parameters for Monthly Carbon Emissions Summary
Name | Required | Type | Description |
---|---|---|---|
carbonScopeList | True |
Carbon emission scope for carbon emissions data |
|
dateRange | True |
The start date and end date for carbon emissions data |
|
reportType | True |
string:
Monthly |
Report type |
subscriptionList | True |
string[] |
SubscriptionId list for carbon emissions data |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
OverallSummaryReportQueryFilter
Query Parameters for Overall Carbon Emissions Summary
Name | Required | Type | Description |
---|---|---|---|
carbonScopeList | True |
Carbon emission scope for carbon emissions data |
|
dateRange | True |
The start date and end date for carbon emissions data |
|
reportType | True |
string:
Overall |
Report type |
subscriptionList | True |
string[] |
SubscriptionId list for carbon emissions data |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
TopItemsMonthlySummaryReportQueryFilter
Query Parameters for Top Items Carbon Emissions by Month
Name | Required | Type | Description |
---|---|---|---|
carbonScopeList | True |
Carbon emission scope for carbon emissions data |
|
categoryType | True |
Item Category type |
|
dateRange | True |
The start date and end date for carbon emissions data |
|
reportType | True |
string:
Top |
Report type |
subscriptionList | True |
string[] |
SubscriptionId list for carbon emissions data |
topItems | True |
integer |
Number of top items to return. The value should be between 5 and 100 |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
TopItemsSummaryReportQueryFilter
Query Parameters for Top Items Carbon Emission by Category Type
Name | Required | Type | Description |
---|---|---|---|
carbonScopeList | True |
Carbon emission scope for carbon emissions data |
|
categoryType | True |
Item Category type |
|
dateRange | True |
The start date and end date for carbon emissions data |
|
reportType | True |
string:
Top |
Report type |
subscriptionList | True |
string[] |
SubscriptionId list for carbon emissions data |
topItems | True |
integer |
Number of top items to return. The value should be between 5 and 100 |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
Responses
Name | Type | Description |
---|---|---|
200 OK |
The request has succeeded. |
|
Other Status Codes |
An unexpected error response. |
Security
azure_auth
Azure Active Directory OAuth2 Flow.
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
Name | Description |
---|---|
user_impersonation | impersonate your user account |
Examples
CarbonService_ListCarbonEmissionReports
Sample request
POST https://management.azure.com/providers/Microsoft.Carbon/carbonEmissionReports?api-version=2023-04-01-preview
{
"reportType": "OverallSummaryReport",
"subscriptionList": [
"00000000-0000-0000-0000-000000000000"
],
"carbonScopeList": [
"Scope1"
],
"dateRange": {
"start": "2023-06-01",
"end": "2023-06-15"
}
}
Sample response
{
"value": [
{
"dataType": "OverallSummaryData",
"totalCarbonEmission": 0,
"totalCarbonEmissionLastMonth": 0,
"changeRatioForLastMonth": 0,
"totalCarbonEmission12MonthsAgo": 0,
"changeRatioFor12Months": 0,
"changeValueMonthOverMonth": 0
}
],
"nextLink": "https://example.nextpage.com/test?token=test"
}
Definitions
Name | Description |
---|---|
Carbon |
List of carbon emission results |
Carbon |
Response for detailed carbon emissions |
Carbon |
Response for Monthly Carbon Emissions Summary |
Carbon |
Response for Overall Carbon Emissions Summary |
Carbon |
Response for Top Items Carbon Emissions by Month |
Carbon |
Response for Top Items by Category Type |
Category |
Supported category types to be used with QueryParameter |
Date |
Date range to be used with QueryParameter |
Emission |
Supported emission scopes to be used with QueryParameter |
Error |
The resource management error additional info. |
Error |
The error detail. |
Error |
Error response |
Item |
Query Parameters for Detailed carbon emissions by pageSize |
Monthly |
Query Parameters for Monthly Carbon Emissions Summary |
Overall |
Query Parameters for Overall Carbon Emissions Summary |
Resource |
Response for Resource detailed carbon emissions |
Resource |
Response for Top Items Carbon Emissions by Month for ResourceType |
Resource |
Response for Top Items For Resource |
Resource |
Response for Resource Group detailed carbon emissions |
Resource |
Response for Top Items Carbon Emissions by Month for ResourceGroupType |
Resource |
Response for Top Items For ResourceGroup |
Top |
Query Parameters for Top Items Carbon Emissions by Month |
Top |
Query Parameters for Top Items Carbon Emission by Category Type |
CarbonEmissionDataListResult
List of carbon emission results
Name | Type | Description |
---|---|---|
nextLink |
string |
The link to the next page of items |
skipToken |
string |
The number of result items to skip for next page |
value |
CarbonEmissionData[]:
|
The CarbonEmissionData items on this page |
CarbonEmissionItemDetailData
Response for detailed carbon emissions
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Item |
Query result data type name |
groupName |
string |
Item group name |
itemName |
string |
Item name |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
CarbonEmissionMonthlySummaryData
Response for Monthly Carbon Emissions Summary
Name | Type | Description |
---|---|---|
carbonIntensity |
number |
Carbon Intensity |
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Monthly |
Query result data type name |
date |
string |
Monthly date string |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
CarbonEmissionOverallSummaryData
Response for Overall Carbon Emissions Summary
Name | Type | Description |
---|---|---|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Overall |
Query result data type name |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
CarbonEmissionTopItemMonthlySummaryData
Response for Top Items Carbon Emissions by Month
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Top |
Query result data type name |
date |
string |
Month date |
itemName |
string |
Item name |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
CarbonEmissionTopItemsSummaryData
Response for Top Items by Category Type
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Top |
Query result data type name |
itemName |
string |
Item name |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
CategoryTypeEnum
Supported category types to be used with QueryParameter
Name | Type | Description |
---|---|---|
Location |
string |
Location level aggregation granularity |
Resource |
string |
Resource level aggregation granularity |
ResourceGroup |
string |
ResourceGroup level aggregation granularity |
ServiceType |
string |
ServiceType level aggregation granularity |
Subscription |
string |
Subscription level aggregation granularity |
DateRange
Date range to be used with QueryParameter
Name | Type | Description |
---|---|---|
end |
string |
End date parameter, format is yyyy-MM-dd |
start |
string |
Start date parameter, format is yyyy-MM-dd |
EmissionScopeEnum
Supported emission scopes to be used with QueryParameter
Name | Type | Description |
---|---|---|
Scope1 |
string |
Scope1 carbon emission |
Scope2 |
string |
Scope2 carbon emission |
Scope3 |
string |
Scope3 carbon emission |
ErrorAdditionalInfo
The resource management error additional info.
Name | Type | Description |
---|---|---|
info |
object |
The additional info. |
type |
string |
The additional info type. |
ErrorDetail
The error detail.
Name | Type | Description |
---|---|---|
additionalInfo |
The error additional info. |
|
code |
string |
The error code. |
details |
The error details. |
|
message |
string |
The error message. |
target |
string |
The error target. |
ErrorResponse
Error response
Name | Type | Description |
---|---|---|
error |
The error object. |
ItemDetailsQueryFilter
Query Parameters for Detailed carbon emissions by pageSize
Name | Type | Description |
---|---|---|
carbonScopeList |
Carbon emission scope for carbon emissions data |
|
categoryType |
Item Category type |
|
dateRange |
The start date and end date for carbon emissions data |
|
groupCategory |
string |
Group category name |
orderBy |
string |
Order by column name |
pageSize |
integer |
Number of items to return |
reportType |
string:
Item |
Report type |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
skipToken |
string |
The number of result items to skip |
sortDirection |
string |
Direction for sorting |
subscriptionList |
string[] |
SubscriptionId list for carbon emissions data |
MonthlySummaryReportQueryFilter
Query Parameters for Monthly Carbon Emissions Summary
Name | Type | Description |
---|---|---|
carbonScopeList |
Carbon emission scope for carbon emissions data |
|
dateRange |
The start date and end date for carbon emissions data |
|
reportType |
string:
Monthly |
Report type |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
subscriptionList |
string[] |
SubscriptionId list for carbon emissions data |
OverallSummaryReportQueryFilter
Query Parameters for Overall Carbon Emissions Summary
Name | Type | Description |
---|---|---|
carbonScopeList |
Carbon emission scope for carbon emissions data |
|
dateRange |
The start date and end date for carbon emissions data |
|
reportType |
string:
Overall |
Report type |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
subscriptionList |
string[] |
SubscriptionId list for carbon emissions data |
ResourceCarbonEmissionItemDetailData
Response for Resource detailed carbon emissions
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
groupName |
string |
Item group name |
itemName |
string |
Item name |
location |
string |
Resource Location |
resourceGroup |
string |
Resource Group |
resourceId |
string |
Resource Id Url |
resourceProvider |
string |
Resource Provider |
resourceType |
string |
Resource Type |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
ResourceCarbonEmissionTopItemMonthlySummaryData
Response for Top Items Carbon Emissions by Month for ResourceType
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
date |
string |
Month date |
itemName |
string |
Item name |
resourceGroup |
string |
Resource Group |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
ResourceCarbonEmissionTopItemsSummaryData
Response for Top Items For Resource
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
itemName |
string |
Item name |
resourceGroup |
string |
Resource Group |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
ResourceGroupCarbonEmissionItemDetailData
Response for Resource Group detailed carbon emissions
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
groupName |
string |
Item group name |
itemName |
string |
Item name |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
ResourceGroupCarbonEmissionTopItemMonthlySummaryData
Response for Top Items Carbon Emissions by Month for ResourceGroupType
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
date |
string |
Month date |
itemName |
string |
Item name |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
ResourceGroupCarbonEmissionTopItemsSummaryData
Response for Top Items For ResourceGroup
Name | Type | Description |
---|---|---|
categoryType |
Item category |
|
changeRatioFor12Months |
number |
Change ratio between totalCarbonEmission and totalCarbonEmission12MonthsAgo |
changeRatioForLastMonth |
number |
Change ratio between totalCarbonEmission and totalCarbonEmissionLastMonth |
changeValueMonthOverMonth |
number |
Change Value between totalCarbonEmission and totalCarbonEmissionLastMonth |
dataType |
string:
Resource |
Query result data type name |
itemName |
string |
Item name |
subscriptionId |
string |
Subscription Id |
totalCarbonEmission |
number |
Total carbon emissions for given query parameters |
totalCarbonEmission12MonthsAgo |
number |
Total carbon emissions for 12 months ago for given query parameters |
totalCarbonEmissionLastMonth |
number |
Total carbon emission for last month for given query parameters |
TopItemsMonthlySummaryReportQueryFilter
Query Parameters for Top Items Carbon Emissions by Month
Name | Type | Description |
---|---|---|
carbonScopeList |
Carbon emission scope for carbon emissions data |
|
categoryType |
Item Category type |
|
dateRange |
The start date and end date for carbon emissions data |
|
reportType |
string:
Top |
Report type |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
subscriptionList |
string[] |
SubscriptionId list for carbon emissions data |
topItems |
integer |
Number of top items to return. The value should be between 5 and 100 |
TopItemsSummaryReportQueryFilter
Query Parameters for Top Items Carbon Emission by Category Type
Name | Type | Description |
---|---|---|
carbonScopeList |
Carbon emission scope for carbon emissions data |
|
categoryType |
Item Category type |
|
dateRange |
The start date and end date for carbon emissions data |
|
reportType |
string:
Top |
Report type |
resourceGroupUrlList |
string[] |
resourceGroupUrl list for carbon emissions data |
subscriptionList |
string[] |
SubscriptionId list for carbon emissions data |
topItems |
integer |
Number of top items to return. The value should be between 5 and 100 |