SmartPVMS V300R006C00 Interface Reference

Download as pdf or txt
Download as pdf or txt
You are on page 1of 88

SmartPVMS

V300R006C00

Interface Reference

Issue 01
Date 2018-09-30

HUAWEI TECHNOLOGIES CO., LTD.


Copyright © Huawei Technologies Co., Ltd. 2018. All rights reserved.
No part of this document may be reproduced or transmitted in any form or by any means without prior written
consent of Huawei Technologies Co., Ltd.

Trademarks and Permissions

and other Huawei trademarks are trademarks of Huawei Technologies Co., Ltd.
All other trademarks and trade names mentioned in this document are the property of their respective
holders.

Notice
The purchased products, services and features are stipulated by the contract made between Huawei and the
customer. All or part of the products, services and features described in this document may not be within the
purchase scope or the usage scope. Unless otherwise specified in the contract, all statements, information,
and recommendations in this document are provided "AS IS" without warranties, guarantees or
representations of any kind, either express or implied.

The information in this document is subject to change without notice. Every effort has been made in the
preparation of this document to ensure accuracy of the contents, but all statements, information, and
recommendations in this document do not constitute a warranty of any kind, express or implied.

Huawei Technologies Co., Ltd.


Address: Huawei Industrial Base
Bantian, Longgang
Shenzhen 518129
People's Republic of China

Website: http://www.huawei.com
Email: [email protected]

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. i


SmartPVMS
Interface Reference Contents

Contents

1 Interface Overview........................................................................................................................ 1
1.1 Interface Access Instructions..........................................................................................................................................1
1.2 Communication Process between Third Party-System and Northbound Interface........................................................ 2

2 Format Definition for Northbound Interface.......................................................................... 3


2.1 Login Interface............................................................................................................................................................... 4
2.2 Interface of Plant List..................................................................................................................................................... 6
2.3 Interface of Power Station for Real-time Data............................................................................................................. 10
2.4 Interface of Power Station for Hour Data.....................................................................................................................13
2.5 Interface of Power Station for Day Data...................................................................................................................... 18
2.6 Interface of Power Station for Month Data.................................................................................................................. 22
2.7 Interface of Power Station for Year Data......................................................................................................................26
2.8 Interface of Equipment for List.................................................................................................................................... 30
2.9 Interface of Equipment for Real-time Data.................................................................................................................. 36
2.10 Interface of Equipment for 5 Min Data...................................................................................................................... 42
2.11 Interface of Equipment for Hour Data........................................................................................................................49
2.12 Interface of Equipment for Day Data......................................................................................................................... 54
2.13 Interface of Equipment for Month Data..................................................................................................................... 58
2.14 Interface of Equipment for Year Data.........................................................................................................................62
2.15 Interface of Equipment for CB................................................................................................................................... 66
2.16 Interface of Equipment for Upgrade...........................................................................................................................70
2.17 Recording Interface of Equipment for Upgrade......................................................................................................... 75
2.18 Error Code List........................................................................................................................................................... 79

3 Format Definition for Open API Interface............................................................................. 81


3.1 Interface of Installer for Registration........................................................................................................................... 81
3.2 Interface of Inverter for Registration............................................................................................................................83
3.3 Information Interface for Query of Management System Version............................................................................... 84

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. ii


SmartPVMS
Interface Reference 1 Interface Overview

1 Interface Overview

1.1 Interface Access Instructions


1.2 Communication Process between Third Party-System and Northbound Interface

1.1 Interface Access Instructions


Access format and path
Access format: https:// management system domain name/specific API interface name +
access request parameter
Access path: https:// manage system domain name/

Access privilege
The access privilege to the northbound interface API is independent of third-party user
accounts, and users must apply for it separately.

Access limit
Third-party applications will be limited by one-minute access frequency when accessing the
same northbound interface API.
If a third-party application reaches the limit of access frequency during use, the interface will
return an access frequency error message.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 1


SmartPVMS
Interface Reference 1 Interface Overview

1.2 Communication Process between Third Party-System


and Northbound Interface
Figure 1-1 The communication process

1. Please refer to the Chapter "Northbound Management" in the product document for the
relevant operation procedures of configuring the third-party system information.
2. After configuring the third-party system information, obtain the system number and log
in with the system number.
3. After successful login, initiate a request to obtain data.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 2


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2 Format Definition for Northbound


Interface

2.1 Login Interface


2.2 Interface of Plant List
2.3 Interface of Power Station for Real-time Data
2.4 Interface of Power Station for Hour Data
2.5 Interface of Power Station for Day Data
2.6 Interface of Power Station for Month Data
2.7 Interface of Power Station for Year Data
2.8 Interface of Equipment for List
2.9 Interface of Equipment for Real-time Data
2.10 Interface of Equipment for 5 Min Data
2.11 Interface of Equipment for Hour Data
2.12 Interface of Equipment for Day Data
2.13 Interface of Equipment for Month Data
2.14 Interface of Equipment for Year Data
2.15 Interface of Equipment for CB
2.16 Interface of Equipment for Upgrade
2.17 Recording Interface of Equipment for Upgrade
2.18 Error Code List

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 3


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.1 Login Interface


Interface description
For the northbound management login, you must log in before obtaining data.

Request address
https://XXXXX/thirdData/login

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

systemCode Password String M

userName User name String M

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

message Optional message String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 4


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a


list of real-time data
information for each
power station

Sample
▲ Sample of request URL:

{
"userName": "Renhan",
"systemCode": "Admin@123456"
}

▲ Sample of return:

{
"success": true,
"data": null,
"failCode": 0,
"params": null,
"message": null
}

After the login interface is successfully logged in, the tokenId is returned. This parameter
needs to be reserved. In subsequent data interface requests, the parameter must be put into the
cookie and passed to the management system.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 5


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.2 Interface of Plant List


Interface description
It obtains basic information of the power station and this interface must be configured before
opening the remaining interfaces.

Request address
https://XXXXX/thirdData/getStationList

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

- - - -

NOTE

l The list of power station is obtained without any parameter. The power station resources possessed
by the user is obtained from the background according to the three-party login user.
l The precondition for obtaining the list is that the user must be in login status.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates that
the tab is normal. See
the error code
description for other
error codes

params Request parameter

currentTime Current time Long

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 6


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

message Optional message


returned

data Data returned No any data will be


returned in current
login, only whether
login is successful.

Data contains a list


of power station
information. The
power station
information is as
follows:

stationCode Station number, String


unique identification

stationName Name of power station String

stationAddr Detailed address of String


power station

capacity Installed capacity Double


[unit: MW ]

buildState Power station status String


0: unbuilt, 1: under
construction, 2: grid
connection

combineType Grid connection type String


1: ground type, 2:
distributed, 3:
household power
station

aidType Identification for Integer


poverty relief power
station
0: poverty relief power
station, 1: non-poverty
relief power station

stationLinkman Contact person for String


power station

linkmanPho Contact phone String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 7


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Sample
▲ Sample of request URL:

Null

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": 20007,
"failCode": 0,
"params": {
"userId": 127,
"currentTime": 1503046597854
},
"message": null
}
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 8


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 2:
{
"success": true,
"data": [
{
"stationCode": "BA4372D08E014822AB065017416F254C",
"stationName": "NM Distributed Power Station 1",
"stationAddr": null,
"capacity": 146.5,
"buildState": "3",
"combineType": "2",
"aidType": 0,
"stationLinkman": "",
"linkmanPho": ""
},
{
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"stationName": " Intelligent Operation and Maintenance Power Station",
"stationAddr": null,
"capacity": 123.3,
"buildState": "3",
"combineType": "1",
"aidType": 0,
"stationLinkman": "",
"linkmanPho": ""
}
],
"failCode": 0,
"params": {
"userId": 14,
"currentTime": 1503046597854
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 9


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.3 Interface of Power Station for Real-time Data


Interface description
It obtains real-time statistical indexes of the power station; it conducts a collection query
through the power station number and supports 1000 stations for one query.

Request address
https://XXXXX/thirdData/getStationRealKpi

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or
failed failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates that
the tab is normal. See
the error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 10


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

data Data returned No any data


will be returned
in current login,
only whether
login is
successful.

The data contains a list


of real-time data
information for each
power station

stationCode Power station number String

dataItemMap The content of each


data item is returned in
the form of key-value
Map<String,Object>

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5"
}

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"currentTime": 1503046597854
},
"message": null
} "message": null

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 11


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 2:
{
"success": true,
"data": [
{
"dataItemMap": {
"real_health_state": "3",
"day_power": "10000",
"total_power": "900.000",
"day_income": "0.000",
"month_power": "900.000",
"total_income": "2088.000"
},
"stationCode": "BA4372D08E014822AB065017416F254C"
},
{
"dataItemMap": {
"real_health_state": "1",
"day_power": "16770.000",
"total_power": "35100.000",
"day_income": "26832.000",
"month_power": "35100.000",
"total_income": "61152.000"
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5"
}
],
"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"currentTime": 1503046597854
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 12


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.4 Interface of Power Station for Hour Data


Interface description
It obtains statistical indexes of the power station for hour dimension; it conducts the collection
and time quantum queries through the power station number and supports 100 stations and
one-day hour data for one query.

Request address
https://XXXXX/thirdData/getKpiStationHour

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

collectTime Milliseconds in time Long M


It hourly queries the
hour KPI data for
one day ( the
background
processes
milliseconds based
on the time zone
where the power
station is located )

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 13


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map


data item is returned
in the form of key-
value
Map<
String,Object>

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 14


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2:
{
"success": true,
"data": [
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0,
"inverter_power": 0,
"theory_power": 0,
"ongrid_power": 0,
"power_profit": 0,
"performance_ratio": null
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
},
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0,
"inverter_power": 0,
"theory_power": 0,
"ongrid_power": 0,
"power_profit": 0,
"performance_ratio": null

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 15


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501866000000
},
{
"dataItemMap": {
"use_power": null,
"radiation_intensity": 0,
"inverter_power": 0,
"theory_power": 0,
"ongrid_power": null,
"power_profit": 0,
"performance_ratio": null
},
"stationCode": "BA4372D08E014822AB065017416F254C",
"collectTime": 1501873200000
},
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0,
"inverter_power": 0,
"theory_power": 0,
"ongrid_power": 0,
"power_profit": 0,
"performance_ratio": null
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501876800000
},
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0,
"inverter_power": 62.4,
"theory_power": 0,
"ongrid_power": 2340,
"power_profit": 3744,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 16


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"performance_ratio": null
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501880400000
},
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0.065,
"inverter_power": 620.1,
"theory_power": 1638,
"ongrid_power": 4680,
"power_profit": 7488,
"performance_ratio": 89
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501884000000
},
{
"dataItemMap": {
"use_power": 0,
"radiation_intensity": 0.2474,
"inverter_power": 1924.7,
"theory_power": 6234.48,
"ongrid_power": 4680,
"power_profit": 7488,
"performance_ratio": 75.066
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501887600000
},
{
"dataItemMap": {
"use_power": null,
"radiation_intensity": 0.2474,
"inverter_power": 0,
"theory_power": 115.546,
"ongrid_power": null,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 17


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"power_profit": 0,
"performance_ratio": 0
},
"stationCode": "BA4372D08E014822AB065017416F254C",
"collectTime": 1501887600000
}
],
"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}

2.5 Interface of Power Station for Day Data


Interface description
It obtains statistical indexes of the power station for day dimension; it conducts the collection
and time quantum queries through the power station number and supports 100 stations and
one-month hour data for one query.

Request address
https://XXXXX/thirdData/getKpiStationDay

Request mode
HTTP method: POST

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 18


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

collectTime Milliseconds in time Long M


It daily queries the
day KPI data for one
month ( the
background
processes
milliseconds based
on the time zone
where the power
station is located )

NOTE

Before acquisition of data, relevant index data items must be configured.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 19


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map


data item is returned
in the form of key-
value
Map<String,
Object>

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 20


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"use_power": 288760,
"radiation_intensity": 0.6968,
"reduction_total_co2": 18.275,
"reduction_total_coal": 7.332,
"theory_power": 17559.36,
"ongrid_power": 18330,
"power_profit": 34320,
"installed_capacity": 25200,
"perpower_ratio": 0.727,
"inverter_power": 18330,
"reduction_total_tree": 999,
"performance_ratio": 89
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501776000000
},
{
"dataItemMap": {
"use_power": null,
"radiation_intensity": 1.4123,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 21


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"reduction_total_co2": 0.897,
"reduction_total_coal": 0.36,
"theory_power": 659.6,
"ongrid_power": null,
"power_profit": 2088,
"installed_capacity": 467.04,
"perpower_ratio": 1.927,
"inverter_power": 18330,
"reduction_total_tree": 49,
"performance_ratio": 89
},
"stationCode": "BA4372D08E014822AB065017416F254C",
"collectTime": 1501776000000
}
],
"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}

2.6 Interface of Power Station for Month Data


Interface description
It obtains statistical indexes of the power station for month dimension; it conducts the
collection and time quantum queries through the power station number and supports 100
stations and one-year month data for one query.

Request address
https://XXXXX/thirdData/getKpiStationMonth

Request mode
HTTP method: POST

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 22


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

collectTime Milliseconds in time Long M


It hourly queries the
month KPI data for
one year ( the
background
processes
milliseconds based
on the time zone
where the power
station is located )

NOTE

Before acquisition of data, relevant index data items must be configured.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 23


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map


data item is returned
in the form of key-
value
Map< String,
Object>

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 24


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"use_power": 288760,
"radiation_intensity": 0.6968,
"reduction_total_co2": 18.275,
"reduction_total_coal": 7.332,
"inverter_power": null,
"theory_power": 17559.36,
"ongrid_power": 18330,
"power_profit": 34320,
"installed_capacity": 25200,
"perpower_ratio": 0.727,
"reduction_total_tree": 999,
"performance_ratio": 89
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501516800000
},
{
"dataItemMap": {
"use_power": null,
"radiation_intensity": 1.4123,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 25


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"reduction_total_co2": 0.897,
"reduction_total_coal": 0.36,
"inverter_power": null,
"theory_power": 659.6,
"ongrid_power": null,
"power_profit": 2088,
"installed_capacity": 467.04,
"perpower_ratio": 1.927,
"reduction_total_tree": 49,
"performance_ratio": 89
},
"stationCode": "BA4372D08E014822AB065017416F254C",
"collectTime": 1501516800000
}
],
"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
},
"message": null
}

2.7 Interface of Power Station for Year Data


Interface description
It obtains statistical indexes of the power station for year dimension; it conducts the collection
and time quantum queries through the power station number and supports 100 stations and
25-year data for one query.

Request address
https://XXXXX/thirdData/getKpiStationYear

Request mode
HTTP method: POST

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 26


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

collectTime Milliseconds in time Long M


It hourly queries the
KPI data for 25
years ( the
background
processes
milliseconds based
on the time zone
where the power
station is located )

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 27


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map


data item is returned
in the form of key-
value
Map< String,
Object>

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 28


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"use_power": 288760,
"radiation_intensity": 0.6968,
"reduction_total_co2": 18.275,
"reduction_total_coal": 7.332,
"inverter_power": null,
"theory_power": 17559.36,
"ongrid_power": 18330,
"power_profit": 34320,
"installed_capacity": 25200,
"perpower_ratio": 0.727,
"reduction_total_tree": 999,
"performance_ratio": 89
},
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1483200000000
},
{
"dataItemMap": {
"use_power": null,
"radiation_intensity": 1.4123,
"reduction_total_co2": 0.897,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 29


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"reduction_total_coal": 0.36,
"inverter_power": null,
"theory_power": 659.6,
"ongrid_power": null,
"power_profit": 2088,
"installed_capacity": 467.04,
"perpower_ratio": 1.927,
"reduction_total_tree": 49,
"performance_ratio": 89
},
"stationCode": "BA4372D08E014822AB065017416F254C",
"collectTime": 1483200000000
}
],
"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}

2.8 Interface of Equipment for List


Interface description
It obtains the basic information of equipment and this interface needs to be configured before
opening the data interface of equipment; it conducts the collection query through the power
station number and supports 100 stations for one query.

Request address
https://XXXXX/thirdData/getDevList

Request mode
HTTP method: POST

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 30


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request parameter
Parameter Name Description Data Type Required/
Optional

stationCodes For the list of power String M


station numbers,
multiple stations are
separated by comma
symbols

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains an List of related data


object list of related object for equipment
data for each
equipment.

id Equipment ID
(equipment number)

devName Equipment name

stationCode Name of power


station

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 31


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

esnCode Equipment SN
number

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 32


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

devTypeId Equipment type ID


1 String inverter
2 DAQ
3 String
6 Bay
7 Bus
8 Box-type
substation
9 Electric meter of
box-type substation
10 Environmental
monitor
11 AC combiner box
12 Northbound
13 Data processing
unit
14 Centralized
inverter
15 DC combiner box
16 General
equipment
17 Gateway meter
18 Electric meter for
line at collection
station
19 Electric meter in
production area for
factory power
20 Photovoltaic
power prediction
system
21 Electric meter in
non-production area
for factory power
22 PID
23 Virtual
Equipment of Power
Plant Supervisory
System
24 Power quality
device
25 Step-up
substation

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 33


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

26 Photovoltaic
grid-connected
cabinet
27 Photovoltaic
grid-connected
screen
37 Pinnet DAQ
38 Household
inverter
39 Energy storage
40 Household
electric meter

softwareVersion Software version


number

invType Type (inverter only) String

longitude Longitude Double

latitude Latitude Double

Sample
▲ Sample of request URL:

{
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 34


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"id": -214543629611879,
"devName": "5fbfk4",
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"esnCode": "5fbfk4",
"devTypeId": 1,
"softwareVersion": "V100R001PC666",
"invType": "SUN2000-17KTL",
"longitude": null,
"latitude": null
},
{
"id": -214091680973855,
"devName": "6fbfk11",
"stationCode": "5D02E8B40AD342159AC8D8A2BCD4FAB5",
"esnCode": "6fbfk11",
"devTypeId": 1,
"softwareVersion": "V100R001PC666",
"invType": "SUN2000-17KTL",
"longitude": null,
"latitude": null
}
],

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 35


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"failCode": 0,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5"
},
"message": null
}

2.9 Interface of Equipment for Real-time Data


Interface description
It obtains real-time data of equipment and the data point of different equipment type is
different; it conduct a collection query through equipment type and number and supports one
equipment type and 1000 equipment.

Request address
https://XXXXX/thirdData/getDevRealKpi

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
1000 equipment are
supported for one
query)

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 36


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Required/


Optional

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type and 1000
equipment are
supported for one
query)
For the reatime data
of equipment, it
supports the
following
equipment:
String inverter
(1)\eentralized
inverter
(14)\household
inverter (38)\DC
combiner box
(15)\environmental
monitor (10)\electric
meter (gateway
meter [17],
Household electric
meter [40])\energy
storage (39)\box-
type substation (8),
subsequent support
of optimizer

NOTE

Before acquisition of data, relevant index data items must be configured.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 37


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned

The data contains a The data contains a


list of real-time KPI list of real-time KPI
data for each data for each
equipment. equipment.
(after the relevant
KPI data items must
be configured, the
data for
corresponding item
can be seen)

devId Equipment number Long

dataItemMap The content of each Map Return the real-time


data item is returned data of equipment
in the form of key-
value
Map<
String,Object>

Sample
▲ Sample of request URL:

{
"devIds": "214060404588862,213472461631079",
"devTypeId":"1"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 38


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20006,
"params": {
"devIds": "214233501711677,214060404588862",
"devTypeId": "1",
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"pv7_u": 0,
"pv1_u": 0,
"b_u": 0,
"c_u": 0,
"pv6_u": 0,
"temperature": 0,
"open_time": 0,
"b_i": 0,
"bc_u": 0,
"pv9_u": 0,
"pv8_u": 0,
"c_i": 0,
"mppt_total_cap": 0,
"pv9_i": 0,
"mppt_3_cap": 0,
"run_state": 0,
"mppt_2_cap": 0,
"inverter_state": 0,
"pv8_i": 0,
"mppt_1_cap": 0,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 39


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"pv6_i": 0,
"mppt_power": 0,
"pv1_i": 0,
"total_cap": 0,
"ab_u": 0,
"pv7_i": 0,
"pv13_u": 0,
"reactive_power": 0,
"pv10_u": 0,
"pv12_i": 0,
"pv11_i": 0,
"pv3_i": 0,
"pv11_u": 0,
"pv2_i": 0,
"pv13_i": 0,
"power_factor": 0,
"pv12_u": 0,
"pv5_i": 0,
"active_power": 0,
"elec_freq": 0,
"pv10_i": 0,
"pv4_i": 0,
"mppt_4_cap": 0,
"pv4_u": 0,
"close_time": 0,
"day_cap": 0,
"ca_u": 0,
"a_i": 0,
"pv5_u": 0,
"a_u": 0,
"pv3_u": 0,
"pv14_u": 0,
"pv14_i": 0,
"efficiency": 0,
"pv2_u": 0
},
"devId": 213472461631079
},

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 40


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

{
"dataItemMap": {
"pv7_u": 0,
"pv1_u": 0,
"b_u": 0,
"c_u": 0,
"pv6_u": 0,
"temperature": 0,
"open_time": 0,
"b_i": 0,
"bc_u": 0,
"pv9_u": 0,
"pv8_u": 0,
"c_i": 0,
"mppt_total_cap": 0,
"pv9_i": 0,
"mppt_3_cap": 0,
"run_state": 0,
"mppt_2_cap": 0,
"inverter_state": 0,
"pv8_i": 0,
"mppt_1_cap": 0,
"pv6_i": 0,
"mppt_power": 0,
"pv1_i": 0,
"total_cap": 0,
"ab_u": 0,
"pv7_i": 0,
"pv13_u": 0,
"reactive_power": 0,
"pv10_u": 0,
"pv12_i": 0,
"pv11_i": 0,
"pv3_i": 0,
"pv11_u": 0,
"pv2_i": 0,
"pv13_i": 0,
"power_factor": 0,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 41


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"pv12_u": 0,
"pv5_i": 0,
"active_power": 0,
"elec_freq": 0,
"pv10_i": 0,
"pv4_i": 0,
"mppt_4_cap": 0,
"pv4_u": 0,
"close_time": 0,
"day_cap": 0,
"ca_u": 0,
"a_i": 0,
"pv5_u": 0,
"a_u": 0,
"pv3_u": 0,
"pv14_u": 0,
"pv14_i": 0,
"efficiency": 0,
"pv2_u": 0
},
"devId": 214060404588862
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1",
"currentTime": 1503046597854
},
"message": null
}

2.10 Interface of Equipment for 5 Min Data


Interface description
It obtains 5 min dimension data of equipment and the data point of different equipment type is
different; it conduct the collection and time quantum queries through equipment type and
number and supports one equipment type, 100 equipment and one-day data.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 42


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request address
https://XXXXX/thirdData/getDevFiveMinutes

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and one-day data are
supported for one
query)
It supports the
following
equipment:
String inverter
(1)\eentralized
inverter
(14)\household
inverter (38)\DC
combiner box
(15)\environmental
monitor (10)\electric
meter (gateway
meter [17],
Household electric
meter [40])\energy
storage (39)\box-
type substation (8),
subsequent support
of optimizer

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 43


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Required/


Optional

collectTime Milliseconds in time Long

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 44


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

collectTime Time (milliseconds) Long Return one-day data


dataItemMap The content of each Map of equipment
data item is returned
in the form of key-
value
Map<
String,Object>
For different
equipment, the
content of data item
is different

Sample
▲ Sample of request URL:

{
"devIds": "214060404588862,213472461631079",
"devTypeId":"1",
"collectTime":"1501862400000"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 45


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"pv7_u": null,
"pv1_u": 575.3,
"b_u": 286.1,
"c_u": 286.9,
"pv6_u": 576.1,
"temperature": 44.6,
"open_time": null,
"b_i": 24.9,
"bc_u": 495.6,
"pv9_u": null,
"pv8_u": null,
"c_i": 25,
"mppt_total_cap": null,
"pv9_i": null,
"mppt_3_cap": null,
"mppt_2_cap": null,
"inverter_state": 512,
"pv8_i": null,
"mppt_1_cap": null,
"pv6_i": 7.1,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 46


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"mppt_power": 21.962,
"pv1_i": 7.1,
"total_cap": 655.37,
"ab_u": 495.4,
"pv7_i": null,
"pv13_u": null,
"reactive_power": 20.95,
"pv10_u": null,
"pv12_i": null,
"pv11_i": null,
"pv3_i": 7.1,
"pv11_u": null,
"pv2_i": 7.1,
"pv13_i": null,
"power_factor": 0,
"pv12_u": null,
"pv5_i": 7.2,
"active_power": 21.05,
"elec_freq": 50.05,
"pv10_i": null,
"pv4_i": 7,
"mppt_4_cap": null,
"pv4_u": 577.8,
"open_time": null,
"day_cap": 159.26,
"ca_u": 496.9,
"a_i": 24.9,
"pv5_u": 576.1,
"a_u": 286,
"pv3_u": 577.8,
"pv14_u": null,
"pv14_i": null,
"efficiency": null,
"pv2_u": 575.3
},
"devId": 213472461631079,
"collectTime": 1501862400000
},

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 47


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

{
"dataItemMap": {
"pv7_u": null,
"pv1_u": 575.3,
"b_u": 286.1,
"c_u": 286.9,
"pv6_u": 576.1,
"temperature": 44.6,
"open_time": null,
"b_i": 24.9,
"bc_u": 495.6,
"pv9_u": null,
"pv8_u": null,
"c_i": 25,
"mppt_total_cap": null,
"pv9_i": null,
"mppt_3_cap": null,
"mppt_2_cap": null,
"inverter_state": 512,
"pv8_i": null,
"mppt_1_cap": null,
"pv6_i": 7.1,
"mppt_power": 21.962,
"pv1_i": 7.1,
"total_cap": 655.37,
"ab_u": 495.4,
"pv7_i": null,
"pv13_u": null,
"reactive_power": 20.95,
"pv10_u": null,
"pv12_i": null,
"pv11_i": null,
"pv3_i": 7.1,
"pv11_u": null,
"pv2_i": 7.1,
"pv13_i": null,
"power_factor": 0,
"pv12_u": null,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 48


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"pv5_i": 7.2,
"active_power": 21.05,
"elec_freq": 50.05,
"pv10_i": null,
"pv4_i": 7,
"mppt_4_cap": null,
"pv4_u": 577.8,
"open_time": null,
"day_cap": 159.26,
"ca_u": 496.9,
"a_i": 24.9,
"pv5_u": 576.1,
"a_u": 286,
"pv3_u": 577.8,
"pv14_u": null,
"pv14_i": null,
"efficiency": null,
"pv2_u": 575.3
},
"devId": 213472461631079,
"collectTime": 1501862700000
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1",
"collectTime":"1501862400000"
},
"message": null
}

2.11 Interface of Equipment for Hour Data


Interface description
It obtains hour dimension data of equipment and the data point of different equipment type is
different; it conduct the collection and time quantum queries through equipment type and
number and supports one equipment type, 100 equipment and one-day data.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 49


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request address
https://XXXXX/thirdData/getDevKpiHour

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and one-day data are
supported for one
query)
It supports the
following
equipment:
Energy storage (39)

collectTime Milliseconds in time Long

NOTE

Before acquisition of data, relevant index data items must be configured.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 50


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map Return one-day data


data item is returned of equipment
in the form of key-
value
Map< String,
Object>
For different
equipment, the
content of data item
is different

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 51


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Sample
▲ Sample of request URL:

{
"devIds": "-97080227842871",
"devTypeId":"39",
"collectTime":"1501862400000"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 52


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"charge_time": 0.5,
"discharge_time": 0.6,
"discharge_cap": 200,
"charge_cap": 100
},
"devId": -97080227842871,
"collectTime": 1501862400100
}
],
"failCode": 0,
"params": {
"devIds": "-97080227842871",
"devTypeId": "39",
"collectTime":"1501862400000"
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 53


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.12 Interface of Equipment for Day Data


Interface description
It obtains day dimension data of equipment and the data point of different equipment type is
different; it conduct the collection and time quantum queries through equipment type and
number and supports one equipment type, 100 equipment and one-month data.

Request address
https://XXXXX/thirdData/getDevKpiDay

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and one-month data
are supported for
one query)
It supports the
following
equipment:
Energy storage (39)
String inverter (1)

collectTime Milliseconds in time Long

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 54


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

NOTE

Before acquisition of data, relevant index data items must be configured.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 55


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

dataItemMap The content of each Map Return one-month


data item is returned data of equipment
in the form of key-
value
Map< String,
Object>
For different
equipment, the
content of data item
is different

Sample
▲ Sample of request URL:

{
"devIds": "214060404588862,213472461631079",
"devTypeId":"1",
"collectTime":"1501862400000"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 56


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"aoc_ratio": 39.931,
"yield_deviation": 0,
"installed_capacity": 30.24,
"perpower_ratio": 9.921,
"product_power": 300,
"total_aop": 5
},
"devId": 213472461631079,
"collectTime": 1501776000000
},
{
"dataItemMap": {
"aoc_ratio": 35.069,
"yield_deviation": 0,
"installed_capacity": 30.24,
"perpower_ratio": 0.543,
"product_power": 16.43,
"total_aop": 88.889
},
"devId": 214060404588862,

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 57


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"collectTime": 1501776000000
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1",
"collectTime":"1501862400000"
},
"message": null
}

2.13 Interface of Equipment for Month Data


Interface description
It obtains month dimension data of equipment and the data point of different equipment type
is different; it conduct the collection and time quantum queries through equipment type and
number and supports one equipment type, 100 equipment and one-year data.

Request address
https://XXXXX/thirdData/getDevKpiMonth

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 58


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Required/


Optional

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and one-year data
are supported for
one query)
It supports the
following
equipment:
Energy storage (39)
String inverter (1)

collectTime Milliseconds in time Long

NOTE

Before acquisition of data, relevant index data items must be configured.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 59


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map Return one-year data


data item is returned of equipment
in the form of key-
value
Map<
String,Object>
For different
equipment, the
content of data item
is different

Sample
▲ Sample of request URL:

{
"devIds": "214060404588862,213472461631079",
"devTypeId":"1",
"collectTime":"1501862400000"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 60


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"installed_capacity": 30.24,
"perpower_ratio": null,
"product_power": 300
},
"devId": 213472461631079,
"collectTime": 1501516800000
},
{
"dataItemMap": {
"installed_capacity": 30.24,
"perpower_ratio": null,
"product_power": 16.43
},
"devId": 214060404588862,
"collectTime": 1501516800000
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 61


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"devTypeId": "1",
"collectTime":"1501862400000"
},
"message": null
}

2.14 Interface of Equipment for Year Data


Interface description
It obtains year dimension data of equipment and the data point of different equipment type is
different; it conduct the collection and time quantum queries through equipment type and
number and supports one equipment type, 100 equipment and 25-year data.

Request address
https://XXXXX/thirdData/getDevKpiYear

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 62


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Required/


Optional

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and 25-year data are
supported for one
query)
It supports the
following
equipment:
Energy storage (39)
String inverter (1)

collectTime Milliseconds in time Long

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 63


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

The data contains a KPI index data list


list of hour data for each hour of
object information power station
for each power
station.

stationCode Power station String


number

collectTime Time (milliseconds) Long

dataItemMap The content of each Map Return data for 25


data item is returned years of equipment
in the form of key-
value
Map<
String,Object>
For different
equipment, the
content of data item
is different

Sample
▲ Sample of request URL:

{
"devIds": "214060404588862,213472461631079",
"devTypeId":"1",
"collectTime":"1501862400000"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 64


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"dataItemMap": {
"installed_capacity": 30.24,
"perpower_ratio": null,
"product_power": 300
},
"devId": 213472461631079,
"collectTime": 1501516800000
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1",
"collectTime":"1501862400000"
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 65


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.15 Interface of Equipment for CB


Interface description
It is used to operate the equipment power-on/off; the power-on/off is conducted through
equipment collection and it supports one equipment type and 10 equipment for one power-on/
off.

Request address
https://XXXXX/thirdData/devOnOff

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only 1 equipment
type, 100 equipment
and one-day data are
supported for one
query)
It supports the
following
equipment:
String inverter
(1)\household
inverter (38)

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 66


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Required/


Optional

controlType Control type Integer M


1: power-on, 2:
power-off

NOTE

The precondition of obtaining the data is that the CB interface must be on.

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains The data contains


the results about the results about
commands issued by commands issued by
each equipment. each equipment.

devId Equipment ID

controlResult Control result Control result


(results returned by (results returned by
issuing the CB issuing the CB
commands) commands)

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 67


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Sample
▲ Sample of request URL:

{
"devIds":
"213472461631079,214060404588862,207125245743225,203233345311053,1979135969
44096,195345909983611,192244809755604,190647485584332,185319461689122,184248
291398941",
"devTypeId":"1",
"controlType":1
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 68


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"devIds": "213472461631079",
"devTypeId":"1",
"controlType":1,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"devId": 214060404588862,
"controlResult": false
},
{
"devId": 213472461631079,
"controlResult": false
},
{
"devId": 184248291398941,
"controlResult": false
},
{
"devId": 192244809755604,
"controlResult": false
},
{
"devId": 185319461689122,
"controlResult": false
},
{

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 69


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"devId": 195345909983611,
"controlResult": false
},
{
"devId": 197913596944096,
"controlResult": false
},
{
"devId": 203233345311053,
"controlResult": false
},
{
"devId": 190647485584332,
"controlResult": false
},
{
"devId": 207125245743225,
"controlResult": false
}
],
"failCode": 0,
"params": {
"devIds":
"213472461631079,214060404588862,207125245743225,203233345311053,1979135969
44096,195345909983611,192244809755604,190647485584332,185319461689122,184248
291398941",
"devTypeId": "1",
"controlType": 1
},
"message": null
}

2.16 Interface of Equipment for Upgrade


Interface description
It is used to upgrade the equipment; the upgrade is conducted through equipment collection
and it supports one equipment type and 10 equipment for one upgrade.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 70


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Request address
https://XXXXX/thirdData/devUpgrade

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only the upgrade of
1 equipment type
and 10 equipment is
supported once)
It supports the
following
equipment:
String inverter
(1)\household
inverter (38)

NOTE

Before acquisition of data, relevant index data items must be configured.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 71


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains The data contains


the results about the results about
upgrade for each upgrade for each
equipment. equipment.

devId Equipment ID Long

result Issue the result boolean true


about the upgrade
command
true: equipment
upgrade command
issued successfully
false: equipment
upgrade command
issued
unsuccessfully

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 72


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Parameter Name Description Data Type Remarks

failCode For the error codes


in failure, o
indicates no error
and the error code
description is
referred to for other
error codes.

Sample
▲ Sample of request URL:

{
"devIds": "213472461631079,214060404588862",
"devTypeId":"1"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 73


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20009,
"params": {
"stationCodes": "BA4372D08E014822AB065017416F254C,
5D02E8B40AD342159AC8D8A2BCD4FAB5",
"collectTime": 1501862400000,
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"devId": 213472461631079,
"result": false,
"failCode": 20020
},
{
"devId": 214060404588862,
"result": true,
"failCode": 0
}
],
"failCode": 0,
"params": {
"devIds": "213472461631079,214060404588862",
"devTypeId": "1",
"collectTime": "1501862400000",
"currentTime": 1503046597854
},
"message": null
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 74


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

2.17 Recording Interface of Equipment for Upgrade


Interface description
It is used to query the upgrade records of the equipment by the system and the query of one
equipment type and 10 equipment is supported once.

Request address
https://XXXXX/thirdData/getDevUpgradeInfo

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Data Type Required/
Optional

devIds List of equipment String M


numbers with
multiple equipment
separated by comma
symbols (only 1
equipment type and
100 equipment are
supported for one
query)

devTypeId For equipment type, Integer M


type ID of each
equipment, see the
data of equipment
list
(only the upgrade of
1 equipment type
and 10 equipment is
supported once)
It supports the
following
equipment:
String inverter
(1)\household
inverter (38)

NOTE

Before acquisition of data, relevant index data items must be configured.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 75


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Message returned
Parameter Name Description Data Type Remarks

success Identification for boolean Tab for request


request succeeded or succeeded or failed
failed
true: request
succeeded
false: request failed

failCode Error code int


The "o" indicates
that the tab is
normal. See the
error code
description for other
error codes

params Request parameter

currentTime Current time Long

message Optional message String

data Data returned No any data will be


returned in current
login, only whether
login is successful.

The data contains The data contains


the recording lists the recording lists
about upgrade of about upgrade of
each equipment by each equipment by
each system. each system.

devId Equipment ID Long

lastUpgradeTime Final upgrade time Long Milliseconds

sourceVersion Version before String


targetVersion upgrade String
process Target upgrade Double
version
upgradeResult Integer
Progress of upgrade
For upgrade result,
0: upgrade not
started, 1: success,
2: failure, 3:
abandon, 4: upgrade
in progress, 5:
expiration timeout

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 76


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

Sample
▲ Sample of request URL:

{
"devIds": "213472461631079,214060404588862",
"devTypeId":"1"
}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 77


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

Sample 1: error code returned


{
"success": false,
"data": null,
"failCode": 20022,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1",
"currentTime": 1503046597854
},
"message": null
}
Sample 2: normal data returned
{
"success": true,
"data": [
{
"devId": 214060404588862,
"lastUpgradeTime": 1501862400000,
"sourceVersion": "V100R002C00B030",
"targetVersion": "V100R002C00B040",
"process": 60,
"upgradeResult": 4
},
{
"devId": 213472461631079,
"lastUpgradeTime": 1501862400000,
"sourceVersion": "V100R002C00B030",
"targetVersion": "V100R002C00B040",
"process": 60,
"upgradeResult": 4
}
],
"failCode": 0,
"params": {
"devIds": "214060404588862,213472461631079",
"devTypeId": "1"
},

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 78


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

▲ Sample of return:

"message": null
}

2.18 Error Code List


No. failCode Description

1 20001 Nonexistent number of third party

2 20002 Third party forbidden

3 20003 Time-out of third party system

4 20004 Abnormal server

5 20005 The equipment ID cannot be empty in the input parameter

6 20006 There is the equipment that does not match the equipment type in
the incoming equipment.

7 20007 There is no relevant power station resource in the system.

8 20008 There is no relevant equipment resource in the system.

9 20009 There is no relevant index query item configured by the system.

10 20010 The power station list cannot be empty in the input parameter.

11 20011 The equipment list cannot be empty in the input parameter.

12 20012 The query time cannot be empty in the input parameter.

13 20013 The equipment type is wrong and the interface does not support the
operation of related equipment.

14 20014 Up to 1000 power stations can be queried at a time.

15 20015 Up to 100 power stations can be queried at a time.

16 20016 Up to 1000 equipment can be queried at a time.

17 20017 Up to 100 equipment can be queried at a time.

18 20018 Up to 10 equipment can be allowed to be operated at a time.

19 20019 The CB type is incorrectly input (1: power-on, 2: power-off).

20 20020 The upgrade package of related version corresponding to the


equipment cannot be found.

21 20021 The upgrade file does not exist.

22 20022 No upgrade record of system-related equipment is queried.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 79


SmartPVMS
Interface Reference 2 Format Definition for Northbound Interface

No. failCode Description

23 305 It is not currently logged in and needs to be logged in again.

24 401 There is no relevant data interface privilege

25 407 The interface is frequently accessed.

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 80


SmartPVMS
Interface Reference 3 Format Definition for Open API Interface

3 Format Definition for Open API Interface

3.1 Interface of Installer for Registration


3.2 Interface of Inverter for Registration
3.3 Information Interface for Query of Management System Version

3.1 Interface of Installer for Registration


Request address
https://IP:port/openApi/registerUser

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Description

sn Equipment SN Composed of capital letters, lowercase


letters and numbers, with a maximum length
of 20 characters

registrationCode Registration Composed of capital letters, lowercase


code letters and numbers, with a maximum length
of 20 characters

email Account e-mail Composed of capital letters, lowercase


letters, underlines (_), strikes (-) and dots,
with a maximum length of 64 characters

pwd Password Composed of capital letters, lowercase


letters and numbers or special characters
(space!"#$%&()*+,-./:;< =>?@[]^`{_|}~),
with the length of 8~32 characters

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 81


SmartPVMS
Interface Reference 3 Format Definition for Open API Interface

Parameter Name Description Description

company Company Length of 1-60 characters


Not allowed: null, not included: |’< >,? &

deviceName Equipment name Length of 1-32 characters


The equipment name is not allowed: null,
not included: < ' >& / " , |

Message returned
Parameter Name Description

200 Successful creation of new user

307 Error of Open API interface

400 Invalid SN or registration code

401 The equipment has already been registered.

402 The equipment SN does not match registration code

403 The current equipment is already being managed by another user

404 The equipment has not been connected to the management


system

405 Invalid email address

406 This email has already been registered in the management


system

407 Password does not meet complexity requirements

408 The equipment description information is too long or empty


character

409 The current IP address has been locked

412 Invalid company name

413 Company name already exists

414 Equipment is bound to power station

415 Invalid equipment name

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 82


SmartPVMS
Interface Reference 3 Format Definition for Open API Interface

Sample
▲Sample:

example:
{"errorMsg":200}

3.2 Interface of Inverter for Registration


Request address
https://ip:port/ openApi/registerInverter

Request mode
HTTP method: POST

Request parameter
Parameter Name Description Description

sn Equipment SN Composed of capital letters, lowercase


letters and numbers, with a maximum length
of 20 characters

registrationCode Registration Composed of capital letters, lowercase


code letters and numbers, with a maximum length
of 20 characters

email Account e-mail Composed of capital letters, lowercase


letters, underlines (_), strikes (-) and dots,
with a maximum length of 64 characters

deviceName Equipment name With the length of 1-32 characters, the


equipment name is not allowed as follows:
null, not included: < ' >& / " , |

Message returned
Parameter Name Description

200 Successful creation of new user

307 Error of Open API interface

400 Invalid SN or registration code

401 The equipment has already been registered.

402 The equipment SN does not match registration code

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 83


SmartPVMS
Interface Reference 3 Format Definition for Open API Interface

Parameter Name Description

403 The current equipment is already being managed by another user

404 The equipment has not been connected to the management


system

405 Invalid email address

406 This email has already been registered in the management


system

407 Password does not meet complexity requirements

408 The descriptive information of equipment is too long or empty


character.

409 The current IP address has been locked.

410 This email has not been registered in the management system

414 Equipment is bound to power station

415 Invalid equipment name

416 Equipment name already exists

417 It is not allowed to register the household inverter for managed


domain user

Sample
▲Sample:

example:
{"errorMsg":200}

3.3 Information Interface for Query of Management


System Version
Request address
https://ip:port/ openApi/queryMSInformation

Request mode
HTTP method: POST

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 84


SmartPVMS
Interface Reference 3 Format Definition for Open API Interface

Request parameter
Parameter Name Description Description

sn Equipment SN Composed of capital letters, lowercase


letters and numbers, with a maximum length
of 20 characters

registrationCode Registration Composed of capital letters, lowercase


code letters and numbers, with a maximum length
of 20 characters

Message returned
Parameter Name Description

404 Query failed

Sample
▲Sample:

example:
{"errorMsg":200}

Issue 01 (2018-09-30) Copyright © Huawei Technologies Co., Ltd. 85

You might also like