Changes for page 07 HTTP API
Last modified by Devin Chen on 2025/05/06 11:44
From version 26.1
edited by Devin Chen
on 2025/05/06 11:44
on 2025/05/06 11:44
Change comment:
There is no comment for this version
Summary
-
Page properties (3 modified, 0 added, 0 removed)
-
Attachments (0 modified, 0 added, 4 removed)
Details
- Page properties
-
- Title
-
... ... @@ -1,1 +1,1 @@ 1 - 07 HTTP API1 +7 HTTP API - Author
-
... ... @@ -1,1 +1,1 @@ 1 -XWiki. DevinChen1 +XWiki.Hunter - Content
-
... ... @@ -1,4 +1,4 @@ 1 -= **General** = 1 += **1 General** = 2 2 3 3 This documents introduces WECON V-BOX HTTP API. And this document also shows some examples. All example is tested from postman application. 4 4 ... ... @@ -43,12 +43,9 @@ 43 43 44 44 screctkey=f1cd9351930d4e589922edbcf3b09a7c 45 45 46 -(% class="box infomessage" %) 47 -((( 48 48 **✎Note:** If it is for Virtual Deployment, the comid and comkey would not be the same with values above. Try to get the actual value from HTTP access (V-NET~-~-Services~-~-HTTP access) 49 -))) 50 50 51 -== **Interface Parameter Description** == 48 +== **1.1 Interface Parameter Description** == 52 52 53 53 **Global parameters** 54 54 ... ... @@ -72,7 +72,7 @@ 72 72 (% style="text-align:center" %) 73 73 [[image:1.png||height="141" width="500" class="img-thumbnail"]] 74 74 75 -== **Example key and value** == 72 +== **1.2 Example key and value** == 76 76 77 77 1).**comid**=2 78 78 ... ... @@ -83,10 +83,10 @@ 83 83 4).**ts**=1573897380 84 84 85 85 ((( 86 -= **Basic API** = 83 += **2 Basic API** = 87 87 ))) 88 88 89 -== **{{id name="_Toc24963726"/}}Login operation** == 86 +== **2.1 {{id name="_Toc24963726"/}}Login operation** == 90 90 91 91 ((( 92 92 **2.1.1 Parameters** ... ... @@ -103,7 +103,7 @@ 103 103 |utype|(% style="width:535px" %)User Type: 1-Manage Account, 2-Viewer Account 104 104 |sid|(% style="width:535px" %)User session ID (Only available for 12 hours) 105 105 106 -**Operating procedures** 103 +**2.1.2 Operating procedures** 107 107 108 108 **Setp1: ** Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/login>>url:http://api.v-box.net/box-data/api/we-data/login]] 109 109 ... ... @@ -127,13 +127,11 @@ 127 127 128 128 "sign":"997513ff1320862f0cbb9ce19d0bd253" 129 129 130 -{{info}} 131 131 **✎Note: **For Virtual Deployment, the sign string should be append with domain, so the format would be like following: 132 132 133 133 alias=xxx&comid=xxx&compvtkey=xxx&domain=xxx&password=xxx&ts=1657682972386&key=f1cd9351930d4e589922edbcf3b09a7c 134 134 135 135 The timestamp must be unit as Millisecond level 136 -{{/info}} 137 137 138 138 **Step4: ** Set common of header 139 139 ... ... @@ -143,7 +143,7 @@ 143 143 [[image:V-BOX HTTP manual_html_cbfc9bbb7d0d4f84.png||height="230" width="700" class="img-thumbnail"]] 144 144 145 145 ((( 146 -**Result** 141 +**2.1.3 Result** 147 147 ))) 148 148 149 149 { ... ... @@ -170,17 +170,17 @@ 170 170 [[image:V-BOX HTTP manual_html_b00e7e6a00828e27.png||height="291" width="500" class="img-thumbnail"]] 171 171 172 172 ((( 173 -= **Service data APIs** = 168 += **3 Service data APIs** = 174 174 ))) 175 175 176 -== **V-Box list** == 171 +== **3.1 V-Box list** == 177 177 178 -**{{id name="_Toc24963732"/}}Parameters** 173 +**3.1.1 {{id name="_Toc24963732"/}}Parameters** 179 179 180 180 (% style="text-align:center" %) 181 181 [[image:X.png||height="412" width="700" class="img-thumbnail"]] 182 182 183 -** ~{{id name="_Toc24963733"/}}Operating procedures**178 +**3.1.2 {{id name="_Toc24963733"/}}Operating procedures** 184 184 185 185 **Step1:** Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/boxs>>url:http://api.v-box.net/box-data/api/we-data/boxs]] 186 186 ... ... @@ -204,7 +204,7 @@ 204 204 (% style="text-align:center" %) 205 205 [[image:V-BOX HTTP manual_html_999832f3a31ac851.png||height="232" width="700" class="img-thumbnail"]] 206 206 207 -**Result** 202 +**3.1.3 Result** 208 208 209 209 { 210 210 ... ... @@ -333,9 +333,9 @@ 333 333 (% style="text-align:center" %) 334 334 [[image:V-BOX HTTP manual_html_5999b14ed63e8065.png||height="348" width="600" class="img-thumbnail"]] 335 335 336 -== **Real-time group list** == 331 +== **3.2 Real-time group list** == 337 337 338 -**{{id name="_Toc24963736"/}} 333 +**3.2.1{{id name="_Toc24963736"/}} Parameters** 339 339 340 340 (% class="table-bordered" %) 341 341 |**acturl**|(% colspan="3" %)we-data/realgroups ... ... @@ -347,7 +347,7 @@ 347 347 |groupId|Group ID 348 348 |groupName|Group name 349 349 350 -**Operating procedures** 345 +**3.2.2 Operating procedures** 351 351 352 352 **Step1: **Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/realgroups>>url:http://api.v-box.net/box-data/api/we-data/realgroups]] 353 353 ... ... @@ -374,7 +374,7 @@ 374 374 (% style="text-align:center" %) 375 375 [[image:V-BOX HTTP manual_html_cc06cac462c1b77a.png||height="172" width="800" class="img-thumbnail"]] 376 376 377 -**Result** 372 +**3.2.3 Result** 378 378 379 379 { 380 380 ... ... @@ -420,19 +420,18 @@ 420 420 421 421 [[image:V-BOX HTTP manual_html_2445c358293d621.png||height="531" width="532"]] 422 422 423 -== **Real-time tags configuration list** == 418 +== **3.3 Real-time tags configuration list** == 424 424 425 -**Parameters** 420 +**3.3.1 Parameters** 426 426 427 427 (% class="table-bordered" %) 428 428 |**acturl**|(% colspan="3" %)we-data/realcfgs 429 429 |**Functions**|(% colspan="3" %)Get the tags configuration information in the specified group in V-BOX. 430 -|(% colspan="1"rowspan="6" %)**Parameters**|Parameter|(% colspan="2" %)Description425 +|(% rowspan="5" %)**Parameters**|Parameter|(% colspan="2" %)Description 431 431 |boxId|(% colspan="2" %)VBoxID(“None” means custom tags grouping) 432 432 |groupId|(% colspan="2" %)Group ID (Required) 433 433 |pageSize|(% colspan="2" %)Number of each page, 10 by default 434 434 |pageIndex|(% colspan="2" %)Number of current page, start from 1 435 -|devType|(% colspan="2" %)Device type (0:Box, 1:HMI) 436 436 |(% rowspan="15" %)**Return value**|Field name|(% colspan="2" %)Description 437 437 |(% rowspan="11" %)cfgList|monitorId|Tags ID 438 438 |monitorName|Tags name ... ... @@ -465,7 +465,7 @@ 465 465 |totalRecord|(% colspan="2" %)Total record number 466 466 |currentPage|(% colspan="2" %)Current page number 467 467 468 -**Operating procedures** 462 +**3.3.2 Operating procedures** 469 469 470 470 **Step1: **Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/realcfgs>>url:http://api.v-box.net/box-data/api/we-data/realcfgs]] 471 471 ... ... @@ -498,7 +498,7 @@ 498 498 (% style="text-align:center" %) 499 499 [[image:V-BOX HTTP manual_html_d284dfdd7b4844ee.png||height="288" width="800" class="img-thumbnail"]] 500 500 501 -**Result** 495 +**3.3.3 Result** 502 502 503 503 { 504 504 ... ... @@ -581,23 +581,18 @@ 581 581 (% style="text-align:center" %) 582 582 [[image:V-BOX HTTP manual_html_e7271097b71941cc.png||height="644" width="800" class="img-thumbnail"]] 583 583 584 -== **Tags data list** == 578 +== (% id="cke_bm_1151S" style="display:none" %)** {{id name="_Toc24963743"/}}**(%%)**3.4 Tags data list** == 585 585 586 -{{warning}} 587 -This API is not for getting the real-time data all the time.If you need to get the continuously updated real-time monitoring point data values,you need to use **[[Send switch to device>>https://docs.we-con.com.cn/bin/view/V-BOX/V-Net/Manual/6%20HTTP%20API/#HSendswitchtodevice]] **API with this API 588 -{{/warning}} 580 +**3.4.1 {{id name="_Toc24963744"/}}Parameters** 589 589 590 -**~ {{id name="_Toc24963744"/}}Parameters** 591 - 592 592 (% class="table-bordered" %) 593 593 |**acturl**|(% colspan="3" %)we-data/realdata 594 594 |**Functions**|(% colspan="3" %)Get the tags data in the specified group in V-BOX. 595 -|(% colspan="1"rowspan="6" %)**Parameters**|Parameter|(% colspan="2" %)Description585 +|(% rowspan="5" %)**Parameters**|Parameter|(% colspan="2" %)Description 596 596 |boxId|(% colspan="2" %)VBoxID(“None” means custom tag grouping) 597 597 |groupId|(% colspan="2" %)Group ID (Required) 598 598 |pageSize|(% colspan="2" %)Number of each page, 10 by default 599 599 |pageIndex|(% colspan="2" %)Number of current page, start from 1 600 -|devType|(% colspan="2" %)Device type (0:Box, 1:HMI) 601 601 |(% rowspan="11" %)**Return value**|Field name|(% colspan="2" %)Description 602 602 |(% rowspan="7" %)List|(% colspan="2" %)Real-time data list 603 603 |com|Communication port ID ... ... @@ -610,7 +610,7 @@ 610 610 |totalRecord|(% colspan="2" %)Total record 611 611 |currentPage|(% colspan="2" %)current page 612 612 613 -** ~{{id name="_Toc24963745"/}}Operating procedures**602 +**3.4.2 {{id name="_Toc24963745"/}}Operating procedures** 614 614 615 615 **Step1: **Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/realdata>>url:http://api.v-box.net/box-data/api/we-data/realdata]] 616 616 ... ... @@ -638,7 +638,7 @@ 638 638 639 639 {"boxId":"973","groupId":"7325","pageSize":"5","pageIndex":"2","sid":"2d7bfd344aa64d8ebc9beea0e4dad8ad","comid":"2","compvtkey":"589625dce895454dbff9782c299db156","ts":"1573897380","sign":"0769228e66c945eed5431c41a96949f2"} 640 640 641 -** ~{{id name="_Toc24963746"/}}Result**630 +**3.4.3 {{id name="_Toc24963746"/}}Result** 642 642 643 643 { 644 644 ... ... @@ -703,23 +703,21 @@ 703 703 (% style="text-align:center" %) 704 704 [[image:V-BOX HTTP manual_html_705682e81eae5ea7.png||height="651" width="800" class="img-thumbnail"]] 705 705 706 -== **Modify tag data** == 695 +== **3.5 Modify tag data** == 707 707 708 708 ((( 709 -**Parameters** 698 +**3.5.1 Parameters** 710 710 ))) 711 711 712 712 (% class="table-bordered" %) 713 713 |**acturl**|(% colspan="2" %)we-data/updrealdata 714 714 |**Functions**|(% colspan="2" %)Modify tag data 715 -|(% rowspan="5" %)**Parameters**|Parameter|Description 716 -|boxId|Box ID 704 +|(% rowspan="3" %)**Parameters**|Parameter|Description 717 717 |monitorId|Tag ID 718 718 |value|value 719 -|devType|Device type (0:Box, 1:HMI) 720 720 |**Return value**|(% colspan="2" %)None 721 721 722 -**Operating procedures** 709 +**3.5.2 Operating procedures** 723 723 724 724 **Step1:** Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/updrealdata>>url:http://api.v-box.net/box-data/api/we-data/updrealdata]] 725 725 ... ... @@ -728,28 +728,27 @@ 728 728 729 729 **Step2:** Set parameters on Params 730 730 731 -boxId:6397578 732 -monitorId:1001 733 -value:66 734 -devType:1 718 +"monitorId":"91541" 735 735 720 +"value":"60" 721 + 736 736 (% style="text-align:center" %) 737 -[[image:17 46502882467-849.png]]723 +[[image:V-BOX HTTP manual_html_5a3153add75ca7b4.png||height="246" width="800" class="img-thumbnail"]] 738 738 739 739 **Step3:** Get sign 740 740 741 - boxId=6397578&comid=128&compvtkey=7e421dd30a394d74b7b9c079e67e272c&devType=1&monitorId=1001&sid=d8c98edd64da40289fef565c94924fe5&ts=171746501715435&value=66&key=f1cd9351930d4e589922edbcf3b09a7c727 +comid=2&compvtkey=589625dce895454dbff9782c299db156&monitorId=91541&sid=2d7bfd344aa64d8ebc9beea0e4dad8ad&ts=1573897380&value=60&key=f1cd9351930d4e589922edbcf3b09a7c 742 742 743 -MD5 sign: 4 802a362fde2ca5053ad79fe4d272200729 +MD5 sign: 4119b1abc9176a187f781bece04a5296 744 744 745 745 **Step4: **Set common of header 746 746 747 -{" compvtkey":"7e421dd30a394d74b7b9c079e67e272c","sign":"4802a362fde2ca5053ad79fe4d272200","comid":"128","sid":"d8c98edd64da40289fef565c94924fe5","ts":171746501715435}733 +{"monitorId":"91541","value":"60","sid":"2d7bfd344aa64d8ebc9beea0e4dad8ad","comid":"2","compvtkey":"589625dce895454dbff9782c299db156","ts":"1573897380","sign":"4119b1abc9176a187f781bece04a5296"} 748 748 749 749 (% style="text-align:center" %) 750 -[[image: 1746503047845-902.png]]736 +[[image:V-BOX HTTP manual_html_59d54a5d886ef614.png||height="244" width="700" class="img-thumbnail"]] 751 751 752 -**Result** 738 +**3.5.3 Result** 753 753 754 754 { 755 755 ... ... @@ -764,24 +764,23 @@ 764 764 } 765 765 766 766 (% style="text-align:center" %) 767 -[[image: 1746503002289-932.png]]753 +[[image:V-BOX HTTP manual_html_590c8dab9e80fd0f.png||height="425" width="700" class="img-thumbnail"]] 768 768 769 -== **Historical tags name list** == 755 +== **3.6 {{id name="_Toc24963751"/}}Historical tags name list** == 770 770 771 -**Parameters** 757 +**3.6.1 Parameters** 772 772 773 773 (% class="table-bordered" %) 774 774 |**acturl**|(% colspan="3" %)we-data/monitors 775 775 |**Functions**|(% colspan="3" %)Get a list of historical tags 776 -|(% rowspan="3" %)**Parameters**|Parameter|(% colspan="2" %)Description 777 -|boxId|(% colspan="2" %)Box ID (Not required) 778 -|devType|(% colspan="2" %)Device type (0:Box, 1:HMI) 762 +|(% rowspan="2" %)**Parameters**|Parameter|(% colspan="2" %)Description 763 +|boxId|(% colspan="2" %)VBoxID (Not required) 779 779 |(% rowspan="4" %)**Return value**|Field name|(% colspan="2" %)Description 780 780 |(% rowspan="3" %)list|(% colspan="2" %)Tag list 781 781 |monitorId|tag ID 782 782 |monitorName|tag name 783 783 784 -**Operating procedures** 769 +**3.6.2 Operating procedures** 785 785 786 786 **Step1: **Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/monitors>>url:http://api.v-box.net/box-data/api/we-data/monitors]] 787 787 ... ... @@ -808,7 +808,7 @@ 808 808 (% style="text-align:center" %) 809 809 [[image:V-BOX HTTP manual_html_dba52ac718eeb66e.png||height="228" width="700" class="img-thumbnail"]] 810 810 811 -**Result** 796 +**3.6.3 Result** 812 812 813 813 { 814 814 ... ... @@ -851,9 +851,9 @@ 851 851 (% style="text-align:center" %) 852 852 [[image:V-BOX HTTP manual_html_2a739377a9fb10b2.png||height="400" width="700" class="img-thumbnail"]] 853 853 854 -== **Historical tag data list** == 839 +== (% id="cke_bm_1218S" style="display:none" %)** **(%%)**3.7 {{id name="_Toc24963755"/}}Historical tag data list** == 855 855 856 -** ~{{id name="_Toc24963756"/}}Parameters**841 +**3.7.1 {{id name="_Toc24963756"/}}Parameters** 857 857 858 858 (% class="table-bordered" %) 859 859 |**acturl**|(% colspan="3" %)we-data/historydata ... ... @@ -873,7 +873,7 @@ 873 873 |totalRecord|(% colspan="2" %)Total records 874 874 |currentPage|(% colspan="2" %)Current page 875 875 876 -**Operating procedures** 861 +**3.7.2 Operating procedures** 877 877 878 878 **Step:** Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/historydata>>url:http://api.v-box.net/box-data/api/we-data/historydata]] 879 879 ... ... @@ -908,7 +908,7 @@ 908 908 (% style="text-align:center" %) 909 909 [[image:V-BOX HTTP manual_html_fac48b1179b555ee.png||height="291" width="700" class="img-thumbnail"]] 910 910 911 -**Result** 896 +**3.7.3 Result** 912 912 913 913 { 914 914 ... ... @@ -971,14 +971,14 @@ 971 971 (% style="text-align:center" %) 972 972 [[image:V-BOX HTTP manual_html_f3b62eb69687a214.png||height="476" width="700" class="img-thumbnail"]] 973 973 974 -== **Alarm tags data list** == 959 +== **3.8 Alarm tags data list** == 975 975 976 -**{{id name="_Toc24963760"/}}Parameters** 961 +**3.8.1 {{id name="_Toc24963760"/}}Parameters** 977 977 978 978 (% class="table-bordered" %) 979 979 |**acturl**|(% colspan="3" %)we-data/alarmdata 980 980 |**Function**|(% colspan="3" %)Get alarm data 981 -|(% rowspan=" 10" %)**Parameters**|Parameter|(% colspan="2" %)Description966 +|(% rowspan="9" %)**Parameters**|Parameter|(% colspan="2" %)Description 982 982 |boxId|(% colspan="2" %)VBoxID, (Required) 983 983 |monitorBeginTime|(% colspan="2" %)Monitoring start time, (Not required) 984 984 |monitorEndTime|(% colspan="2" %)Monitoring end time, (Not required) ... ... @@ -995,7 +995,6 @@ 995 995 996 996 (Not necessary) 997 997 ))) 998 -|devType|(% colspan="2" %)Device type (0:Box, 1:HMI) 999 999 |(% rowspan="12" %)**Return value**|Field name|(% colspan="2" %)Description 1000 1000 |(% rowspan="8" %)List|(% colspan="2" %)Alarm data list 1001 1001 |monitorId|tag ID ... ... @@ -1009,7 +1009,7 @@ 1009 1009 |totalRecord|(% colspan="2" %)Total records 1010 1010 |currentPage|(% colspan="2" %)Current page 1011 1011 1012 -** ~{{id name="_Toc24963761"/}}Operating procedures**996 +**3.8.2 {{id name="_Toc24963761"/}}Operating procedures** 1013 1013 1014 1014 **Step1:** Set http: [[http:~~/~~/api.v-box.net/box-data/api/we-data/alarmdata>>url:http://api.v-box.net/box-data/api/we-data/alarmdata]] 1015 1015 ... ... @@ -1046,7 +1046,7 @@ 1046 1046 (% style="text-align:center" %) 1047 1047 [[image:V-BOX HTTP manual_html_cd9ce84648b86cb9.png||height="269" width="700" class="img-thumbnail"]] 1048 1048 1049 -**Result** 1033 +**3.8.3 Result** 1050 1050 1051 1051 { 1052 1052 ... ... @@ -1125,9 +1125,9 @@ 1125 1125 (% style="text-align:center" %) 1126 1126 [[image:V-BOX HTTP manual_html_d4a3e0114c402c27.png||height="475" width="700" class="img-thumbnail"]] 1127 1127 1128 -== **Get device state** == 1112 +== **3.9 Get device state** == 1129 1129 1130 -** ~{{id name="_Toc24963760"/}}Parameters**1114 +**3.9.1 {{id name="_Toc24963760"/}}Parameters** 1131 1131 1132 1132 (% class="table-bordered" %) 1133 1133 |**acturl**|(% colspan="3" %)we-data/getDeviceState ... ... @@ -1137,7 +1137,7 @@ 1137 1137 |(% rowspan="2" %)**Return value**|Field name|(% colspan="2" %)Description 1138 1138 |state|(% colspan="2" %)vbox state: 1-online, 0-offline 1139 1139 1140 -== **Send switch to device** == 1124 +== **3.10 Send switch to device** == 1141 1141 1142 1142 **3.10.1 {{id name="_Toc24963760"/}}Parameters** 1143 1143 ... ... @@ -1148,9 +1148,9 @@ 1148 1148 |(% style="width:450px" %)boxId|(% colspan="2" %)boxId(required) 1149 1149 |(% rowspan="1" style="width:102px" %)**Return value**|(% style="width:450px" %)Field name|(% colspan="2" %)Description 1150 1150 1151 -= **Appendix** = 1135 += **4 Appendix** = 1152 1152 1153 -== (% style="color:inherit; font-family:inherit; font-size:26px" %)**Data type**(%%) == 1137 +== (% style="color:inherit; font-family:inherit; font-size:26px" %)**4.1 Data type**(%%) == 1154 1154 1155 1155 100: 16-bit binary 1156 1156
- 1746502870811-166.png
-
- Author
-
... ... @@ -1,1 +1,0 @@ 1 -XWiki.DevinChen - Size
-
... ... @@ -1,1 +1,0 @@ 1 -36.4 KB - Content
- 1746502882467-849.png
-
- Author
-
... ... @@ -1,1 +1,0 @@ 1 -XWiki.DevinChen - Size
-
... ... @@ -1,1 +1,0 @@ 1 -36.4 KB - Content
- 1746503002289-932.png
-
- Author
-
... ... @@ -1,1 +1,0 @@ 1 -XWiki.DevinChen - Size
-
... ... @@ -1,1 +1,0 @@ 1 -20.3 KB - Content
- 1746503047845-902.png
-
- Author
-
... ... @@ -1,1 +1,0 @@ 1 -XWiki.DevinChen - Size
-
... ... @@ -1,1 +1,0 @@ 1 -42.1 KB - Content