POST api/Service/Dev/Meter/Status/SetTo/OnLine

设置一个流量计的在线状态。 这个操作通常发生在流量计通过某种方式链入云平台或云平台收到心跳包之后。

Request Information

URI Parameters

None.

Body Parameters

MeterOnlineParm
NameDescriptionTypeAdditional information
SerialId

流量计的ID

integer

Required

NetworkType

链路的类型,U:Udp,T :TCP.

string

Required

Max length: 1

IPV4

IPV4地址。

string

Max length: 15

IPV6

IPV6地址。

string

Max length: 64

Port

端口号。

integer

None.

Request Formats

application/json, text/json

Sample:
{
  "SerialId": 1,
  "NetworkType": "sample string 2",
  "IPV4": "sample string 3",
  "IPV6": "sample string 4",
  "Port": 5
}

application/xml, text/xml

Sample:
<MeterOnlineParm xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DigitalScience.DataTransfer.Flowmeter.ForService">
  <IPV4>sample string 3</IPV4>
  <IPV6>sample string 4</IPV6>
  <NetworkType>sample string 2</NetworkType>
  <Port>5</Port>
  <SerialId>1</SerialId>
</MeterOnlineParm>

application/x-www-form-urlencoded

Sample:

Sample not available.

application/bson

Sample:
Binary JSON content. See http://bsonspec.org for details.

Response Information

Resource Description

设置一个流量计的在线状态。 这个操作通常发生在流量计通过某种方式链入云平台或云平台收到心跳包之后。

CommonOperationResult
NameDescriptionTypeAdditional information
errcode

错误代码,通常0表示成功,其他值表示错误。

integer

None.

errmsg

错误描述,当errcode不为零时,此值可以用于呈现给用户。

string

None.

tag

操作同时,服务器端需要返回的其他值。

string

None.

Response Formats

application/json, text/json

Sample:
{
  "errcode": 1,
  "errmsg": "sample string 2",
  "tag": "sample string 3"
}

application/xml, text/xml

Sample:
<CommonOperationResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DigitalScience.DataTransfer">
  <errcode>1</errcode>
  <errmsg>sample string 2</errmsg>
  <tag>sample string 3</tag>
</CommonOperationResult>

application/bson

Sample:
Binary JSON content. See http://bsonspec.org for details.