POST sites/{id}/channels
Creates one or more new channels in the identified site.
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
id |
Site id of the site where the channels will be created. |
integer |
Required |
Body Parameters
An array of channel objects. Each item defines a channel to be created on the site.
Collection of CreateChannelVMName | Description | Type | Additional information |
---|---|---|---|
ChannelName |
The name of the channel to be created. |
string |
None. |
Unit |
Unit of measurement of the channel. |
string |
None. |
ChannelType |
The type of channel. Supported types are: "Raw", "Calculated", "Note", "FACEPro", "Photo". |
string |
None. |
IsVisible |
Indicates if the channel visible in FlowWork's mapping, graphing, reporting, and other tools. |
boolean |
None. |
IsRainfallEnabled |
Indicates if the channel is configured to work with rainfall tools. |
boolean |
None. |
Request Formats
application/json, text/json
[ { "ChannelName": "sample string 1", "Unit": "sample string 2", "ChannelType": "sample string 3", "IsVisible": true, "IsRainfallEnabled": true }, { "ChannelName": "sample string 1", "Unit": "sample string 2", "ChannelType": "sample string 3", "IsVisible": true, "IsRainfallEnabled": true } ]
application/xml, text/xml
<ArrayOfCreateChannelVM xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FW.WebApi2.ViewModels"> <CreateChannelVM> <ChannelName>sample string 1</ChannelName> <ChannelType>sample string 3</ChannelType> <IsRainfallEnabled>true</IsRainfallEnabled> <IsVisible>true</IsVisible> <Unit>sample string 2</Unit> </CreateChannelVM> <CreateChannelVM> <ChannelName>sample string 1</ChannelName> <ChannelType>sample string 3</ChannelType> <IsRainfallEnabled>true</IsRainfallEnabled> <IsVisible>true</IsVisible> <Unit>sample string 2</Unit> </CreateChannelVM> </ArrayOfCreateChannelVM>
application/x-www-form-urlencoded
Sample not available.
Response Information
Resource Description
ResponseVMOfChannelVMName | Description | Type | Additional information |
---|---|---|---|
Resources | Collection of ChannelVM |
None. |
|
ResultCode | FwApiResultCode |
None. |
|
ResultMessage | string |
None. |
Response Formats
application/json, text/json
{ "Resources": [ { "Id": 1, "Name": "sample string 2", "Unit": "sample string 3", "ChannelType": "sample string 4", "IsVisible": true, "IsRainfallEnabled": true }, { "Id": 1, "Name": "sample string 2", "Unit": "sample string 3", "ChannelType": "sample string 4", "IsVisible": true, "IsRainfallEnabled": true } ], "ResultCode": 0, "ResultMessage": "sample string 1" }
application/xml, text/xml
<ResponseVMOfChannelVMFXJgzlgx xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/FW.WebApi2.ViewModels"> <ResultCode>Ok</ResultCode> <ResultMessage>sample string 1</ResultMessage> <Resources> <ChannelVM> <ChannelType>sample string 4</ChannelType> <Id>1</Id> <IsRainfallEnabled>true</IsRainfallEnabled> <IsVisible>true</IsVisible> <Name>sample string 2</Name> <Unit>sample string 3</Unit> </ChannelVM> <ChannelVM> <ChannelType>sample string 4</ChannelType> <Id>1</Id> <IsRainfallEnabled>true</IsRainfallEnabled> <IsVisible>true</IsVisible> <Name>sample string 2</Name> <Unit>sample string 3</Unit> </ChannelVM> </Resources> </ResponseVMOfChannelVMFXJgzlgx>