All Products
Search
Document Center

Energy Expert:GetElecConstitute

Last Updated:Dec 05, 2025

Retrieves electricity composition analysis data.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

energy:GetElecConstitute

none

*All Resource

*

None None

Request syntax

POST /api/v1/carbon/emission/analysis/elec/constitute HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

body

object

No

The request body.

code

string

Yes

The enterprise code.

C-20240202-01

year

integer

Yes

The year.

2024

Response elements

Element

Type

Description

Example

object

Schema of Response

data

object

The returned data.

water

object

Hydropower.

carbonEmissionData

number

The carbon emission equivalent.

2.1

rawData

number

The electricity consumption.

1.2

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.4

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

水电

nameKey

string

The identifier for the name.

carbonInventory.check.water_electricity

light

object

Photovoltaic power.

carbonEmissionData

number

The carbon emission equivalent.

1.2

rawData

number

The electricity consumption.

1.2

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.2

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

光电

nameKey

string

The code for the electricity type.

carbonInventory.check.light_electricity

urban

object

Grid power.

carbonEmissionData

number

The carbon emission equivalent.

1.2

rawData

number

The electricity consumption.

1.2

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.4

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

市电

nameKey

string

The code for the electricity type.

carbonInventory.check.urban_electricity

wind

object

Wind power.

carbonEmissionData

number

The carbon emission equivalent.

1.2

rawData

number

The electricity consumption.

1.1

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.3

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

风电

nameKey

string

The code for the electricity type.

carbonInventory.check.wind_electricity

nuclear

object

Nuclear power.

carbonEmissionData

number

The carbon emission equivalent.

2.3

rawData

number

The electricity consumption.

2

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.6

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

核电

nameKey

string

The code for the electricity type.

carbonInventory.check.nuclear_electricity

renewing

object

Renewable energy power.

carbonEmissionData

number

The carbon emission equivalent.

2.3

rawData

number

The electricity consumption.

4.3

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.44

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

可再生能源电力

nameKey

string

The code for the electricity type.

carbonInventory.carbonEmissionAnalysis.components.CarbonDetail.keZaiShengZiYuan

zero

object

Zero-carbon electricity.

carbonEmissionData

number

The carbon emission equivalent.

1.2

rawData

number

The electricity consumption.

444.3

ratio

number

The percentage of the total monthly electricity consumption. For example, a value of 0.5 indicates 50%.

0.33

dataUnit

string

The unit of measurement.

kWh

name

string

The name of the electricity type.

零电

nameKey

string

The code for the electricity type.

carbonInventory.carbonEmissionAnalysis.components.CarbonDetail.lingTanDianLi

requestId

string

The request ID. A unique value is generated for each request. You can use this ID to troubleshoot issues.

83A5A7DD-8974-5769-952E-590A97BEA34E

Examples

Success response

JSON format

{
  "data": {
    "water": {
      "carbonEmissionData": 2.1,
      "rawData": 1.2,
      "ratio": 0.4,
      "dataUnit": "kWh",
      "name": "水电",
      "nameKey": "carbonInventory.check.water_electricity"
    },
    "light": {
      "carbonEmissionData": 1.2,
      "rawData": 1.2,
      "ratio": 0.2,
      "dataUnit": "kWh",
      "name": "光电",
      "nameKey": "carbonInventory.check.light_electricity"
    },
    "urban": {
      "carbonEmissionData": 1.2,
      "rawData": 1.2,
      "ratio": 0.4,
      "dataUnit": "kWh",
      "name": "市电",
      "nameKey": "carbonInventory.check.urban_electricity"
    },
    "wind": {
      "carbonEmissionData": 1.2,
      "rawData": 1.1,
      "ratio": 0.3,
      "dataUnit": "kWh",
      "name": "风电",
      "nameKey": "carbonInventory.check.wind_electricity"
    },
    "nuclear": {
      "carbonEmissionData": 2.3,
      "rawData": 2,
      "ratio": 0.6,
      "dataUnit": "kWh",
      "name": "核电",
      "nameKey": "carbonInventory.check.nuclear_electricity"
    },
    "renewing": {
      "carbonEmissionData": 2.3,
      "rawData": 4.3,
      "ratio": 0.44,
      "dataUnit": "kWh",
      "name": "可再生能源电力\n\n",
      "nameKey": "carbonInventory.carbonEmissionAnalysis.components.CarbonDetail.keZaiShengZiYuan"
    },
    "zero": {
      "carbonEmissionData": 1.2,
      "rawData": 444.3,
      "ratio": 0.33,
      "dataUnit": "kWh",
      "name": "零电",
      "nameKey": "carbonInventory.carbonEmissionAnalysis.components.CarbonDetail.lingTanDianLi"
    }
  },
  "requestId": "83A5A7DD-8974-5769-952E-590A97BEA34E"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.