Changes for page 07 HTTP API

Last modified by Devin Chen on 2025/04/10 16:16

From version 8.1
edited by Hunter
on 2023/01/11 18:56
Change comment: There is no comment for this version
To version 19.1
edited by xingzhi lin
on 2025/04/01 11:34
Change comment: There is no comment for this version

Summary

Details

Page properties
Title
... ... @@ -1,1 +1,1 @@
1 -7 HTTP API
1 +07 HTTP API
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.Hunter
1 +XWiki.lxz
Content
... ... @@ -1,4 +1,4 @@
1 -= **1 General** =
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,9 +43,12 @@
43 43  
44 44  screctkey=f1cd9351930d4e589922edbcf3b09a7c
45 45  
46 +(% class="box infomessage" %)
47 +(((
46 46  **✎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 +)))
47 47  
48 -== **1.1 Interface Parameter Description** ==
51 +== **Interface Parameter Description** ==
49 49  
50 50  **Global parameters**
51 51  
... ... @@ -69,7 +69,7 @@
69 69  (% style="text-align:center" %)
70 70  [[image:1.png||height="141" width="500" class="img-thumbnail"]]
71 71  
72 -== **1.2 Example key and value** ==
75 +== **Example key and value** ==
73 73  
74 74  1).**comid**=2
75 75  
... ... @@ -80,10 +80,10 @@
80 80  4).**ts**=1573897380
81 81  
82 82  (((
83 -= **2 Basic API** =
86 += **Basic API** =
84 84  )))
85 85  
86 -== **2.1 {{id name="_Toc24963726"/}}Login operation** ==
89 +== **{{id name="_Toc24963726"/}}Login operation** ==
87 87  
88 88  (((
89 89  **2.1.1 Parameters**
... ... @@ -98,9 +98,9 @@
98 98  |domain(Optional)|(% style="width:535px" %)3rd party interface domain(Only available for Virtual Deployment)
99 99  |(% rowspan="3" %)**Return value**|Items|(% style="width:535px" %)Description
100 100  |utype|(% style="width:535px" %)User Type: 1-Manage Account, 2-Viewer Account
101 -|sid|(% style="width:535px" %)User session ID
104 +|sid|(% style="width:535px" %)User session ID (Only available for 12 hours)
102 102  
103 -**2.1.2 Operating procedures**
106 +**Operating procedures**
104 104  
105 105  **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]]
106 106  
... ... @@ -124,11 +124,13 @@
124 124  
125 125  "sign":"997513ff1320862f0cbb9ce19d0bd253"
126 126  
130 +{{info}}
127 127  **✎Note: **For Virtual Deployment, the sign string should be append with domain, so the format would be like following:
128 128  
129 129  alias=xxx&comid=xxx&compvtkey=xxx&domain=xxx&password=xxx&ts=1657682972386&key=f1cd9351930d4e589922edbcf3b09a7c
130 130  
131 131  The timestamp must be unit as Millisecond level
136 +{{/info}}
132 132  
133 133  **Step4: ** Set common of header
134 134  
... ... @@ -138,7 +138,7 @@
138 138  [[image:V-BOX HTTP manual_html_cbfc9bbb7d0d4f84.png||height="230" width="700" class="img-thumbnail"]]
139 139  
140 140  (((
141 -**2.1.3 Result**
146 +**Result**
142 142  )))
143 143  
144 144  {
... ... @@ -165,17 +165,17 @@
165 165  [[image:V-BOX HTTP manual_html_b00e7e6a00828e27.png||height="291" width="500" class="img-thumbnail"]]
166 166  
167 167  (((
168 -= **3 Service data APIs** =
173 += **Service data APIs** =
169 169  )))
170 170  
171 -== **3.1 V-Box list** ==
176 +== **V-Box list** ==
172 172  
173 -**3.1.1 {{id name="_Toc24963732"/}}Parameters**
178 +**{{id name="_Toc24963732"/}}Parameters**
174 174  
175 175  (% style="text-align:center" %)
176 176  [[image:X.png||height="412" width="700" class="img-thumbnail"]]
177 177  
178 -**3.1.2 {{id name="_Toc24963733"/}}Operating procedures**
183 +**~ {{id name="_Toc24963733"/}}Operating procedures**
179 179  
180 180  **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]]
181 181  
... ... @@ -199,7 +199,7 @@
199 199  (% style="text-align:center" %)
200 200  [[image:V-BOX HTTP manual_html_999832f3a31ac851.png||height="232" width="700" class="img-thumbnail"]]
201 201  
202 -**3.1.3 Result**
207 +**Result**
203 203  
204 204  {
205 205  
... ... @@ -328,9 +328,9 @@
328 328  (% style="text-align:center" %)
329 329  [[image:V-BOX HTTP manual_html_5999b14ed63e8065.png||height="348" width="600" class="img-thumbnail"]]
330 330  
331 -== **3.2 Real-time group list** ==
336 +== **Real-time group list** ==
332 332  
333 -**3.2.1{{id name="_Toc24963736"/}} Parameters**
338 +**{{id name="_Toc24963736"/}} Parameters**
334 334  
335 335  (% class="table-bordered" %)
336 336  |**acturl**|(% colspan="3" %)we-data/realgroups
... ... @@ -342,7 +342,7 @@
342 342  |groupId|Group ID
343 343  |groupName|Group name
344 344  
345 -**3.2.2 Operating procedures**
350 +**Operating procedures**
346 346  
347 347  **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]]
348 348  
... ... @@ -369,7 +369,7 @@
369 369  (% style="text-align:center" %)
370 370  [[image:V-BOX HTTP manual_html_cc06cac462c1b77a.png||height="172" width="800" class="img-thumbnail"]]
371 371  
372 -**3.2.3 Result**
377 +**Result**
373 373  
374 374  {
375 375  
... ... @@ -415,9 +415,9 @@
415 415  
416 416  [[image:V-BOX HTTP manual_html_2445c358293d621.png||height="531" width="532"]]
417 417  
418 -== **3.3 Real-time tags configuration list** ==
423 +== **Real-time tags configuration list** ==
419 419  
420 -**3.3.1 Parameters**
425 +**Parameters**
421 421  
422 422  (% class="table-bordered" %)
423 423  |**acturl**|(% colspan="3" %)we-data/realcfgs
... ... @@ -459,7 +459,7 @@
459 459  |totalRecord|(% colspan="2" %)Total record number
460 460  |currentPage|(% colspan="2" %)Current page number
461 461  
462 -**3.3.2 Operating procedures**
467 +**Operating procedures**
463 463  
464 464  **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]]
465 465  
... ... @@ -492,7 +492,7 @@
492 492  (% style="text-align:center" %)
493 493  [[image:V-BOX HTTP manual_html_d284dfdd7b4844ee.png||height="288" width="800" class="img-thumbnail"]]
494 494  
495 -**3.3.3 Result**
500 +**Result**
496 496  
497 497  {
498 498  
... ... @@ -575,10 +575,14 @@
575 575  (% style="text-align:center" %)
576 576  [[image:V-BOX HTTP manual_html_e7271097b71941cc.png||height="644" width="800" class="img-thumbnail"]]
577 577  
578 -== (% id="cke_bm_1151S" style="display:none" %)** {{id name="_Toc24963743"/}}**(%%)**3.4 Tags data list** ==
583 +== **Tags data list** ==
579 579  
580 -**3.4.1 {{id name="_Toc24963744"/}}Parameters**
585 +{{warning}}
586 +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 with this API
587 +{{/warning}}
581 581  
589 +**~ {{id name="_Toc24963744"/}}Parameters**
590 +
582 582  (% class="table-bordered" %)
583 583  |**acturl**|(% colspan="3" %)we-data/realdata
584 584  |**Functions**|(% colspan="3" %)Get the tags data in the specified group in V-BOX.
... ... @@ -599,7 +599,7 @@
599 599  |totalRecord|(% colspan="2" %)Total record
600 600  |currentPage|(% colspan="2" %)current page
601 601  
602 -**3.4.2 {{id name="_Toc24963745"/}}Operating procedures**
611 +**~ {{id name="_Toc24963745"/}}Operating procedures**
603 603  
604 604  **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]]
605 605  
... ... @@ -627,7 +627,7 @@
627 627  
628 628  {"boxId":"973","groupId":"7325","pageSize":"5","pageIndex":"2","sid":"2d7bfd344aa64d8ebc9beea0e4dad8ad","comid":"2","compvtkey":"589625dce895454dbff9782c299db156","ts":"1573897380","sign":"0769228e66c945eed5431c41a96949f2"}
629 629  
630 -**3.4.3 {{id name="_Toc24963746"/}}Result**
639 +**~ {{id name="_Toc24963746"/}}Result**
631 631  
632 632  {
633 633  
... ... @@ -692,10 +692,10 @@
692 692  (% style="text-align:center" %)
693 693  [[image:V-BOX HTTP manual_html_705682e81eae5ea7.png||height="651" width="800" class="img-thumbnail"]]
694 694  
695 -== **3.5 Modify tag data** ==
704 +== **Modify tag data** ==
696 696  
697 697  (((
698 -**3.5.1 Parameters**
707 +**Parameters**
699 699  )))
700 700  
701 701  (% class="table-bordered" %)
... ... @@ -706,7 +706,7 @@
706 706  |value|value
707 707  |**Return value**|(% colspan="2" %)None
708 708  
709 -**3.5.2 Operating procedures**
718 +**Operating procedures**
710 710  
711 711  **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]]
712 712  
... ... @@ -735,7 +735,7 @@
735 735  (% style="text-align:center" %)
736 736  [[image:V-BOX HTTP manual_html_59d54a5d886ef614.png||height="244" width="700" class="img-thumbnail"]]
737 737  
738 -**3.5.3 Result**
747 +**Result**
739 739  
740 740  {
741 741  
... ... @@ -752,9 +752,9 @@
752 752  (% style="text-align:center" %)
753 753  [[image:V-BOX HTTP manual_html_590c8dab9e80fd0f.png||height="425" width="700" class="img-thumbnail"]]
754 754  
755 -== **3.6 {{id name="_Toc24963751"/}}Historical tags name list** ==
764 +== **Historical tags name list** ==
756 756  
757 -**3.6.1 Parameters**
766 +**Parameters**
758 758  
759 759  (% class="table-bordered" %)
760 760  |**acturl**|(% colspan="3" %)we-data/monitors
... ... @@ -766,7 +766,7 @@
766 766  |monitorId|tag ID
767 767  |monitorName|tag name
768 768  
769 -**3.6.2 Operating procedures**
778 +**Operating procedures**
770 770  
771 771  **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]]
772 772  
... ... @@ -793,7 +793,7 @@
793 793  (% style="text-align:center" %)
794 794  [[image:V-BOX HTTP manual_html_dba52ac718eeb66e.png||height="228" width="700" class="img-thumbnail"]]
795 795  
796 -**3.6.3 Result**
805 +**Result**
797 797  
798 798  {
799 799  
... ... @@ -836,9 +836,9 @@
836 836  (% style="text-align:center" %)
837 837  [[image:V-BOX HTTP manual_html_2a739377a9fb10b2.png||height="400" width="700" class="img-thumbnail"]]
838 838  
839 -== (% id="cke_bm_1218S" style="display:none" %)** **(%%)**3.7 {{id name="_Toc24963755"/}}Historical tag data list** ==
848 +== **Historical tag data list** ==
840 840  
841 -**​​​​​​​3.7.1 {{id name="_Toc24963756"/}}Parameters**
850 +**~ {{id name="_Toc24963756"/}}Parameters**
842 842  
843 843  (% class="table-bordered" %)
844 844  |**acturl**|(% colspan="3" %)we-data/historydata
... ... @@ -858,7 +858,7 @@
858 858  |totalRecord|(% colspan="2" %)Total records
859 859  |currentPage|(% colspan="2" %)Current page
860 860  
861 -​​​​​​​**3.7.2 Operating procedures**
870 +**Operating procedures**
862 862  
863 863  **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]]
864 864  
... ... @@ -893,7 +893,7 @@
893 893  (% style="text-align:center" %)
894 894  [[image:V-BOX HTTP manual_html_fac48b1179b555ee.png||height="291" width="700" class="img-thumbnail"]]
895 895  
896 -**3.7.3 Result**
905 +**Result**
897 897  
898 898  {
899 899  
... ... @@ -956,9 +956,9 @@
956 956  (% style="text-align:center" %)
957 957  [[image:V-BOX HTTP manual_html_f3b62eb69687a214.png||height="476" width="700" class="img-thumbnail"]]
958 958  
959 -== **3.8 Alarm tags data list** ==
968 +== **Alarm tags data list** ==
960 960  
961 -**​​​​​​​​​​​​​​3.8.1 {{id name="_Toc24963760"/}}Parameters**
970 +**{{id name="_Toc24963760"/}}Parameters**
962 962  
963 963  (% class="table-bordered" %)
964 964  |**acturl**|(% colspan="3" %)we-data/alarmdata
... ... @@ -993,7 +993,7 @@
993 993  |totalRecord|(% colspan="2" %)Total records
994 994  |currentPage|(% colspan="2" %)Current page
995 995  
996 -**​​​​​​​​​​​​​​3.8.2 {{id name="_Toc24963761"/}}Operating procedures**
1005 +**~ {{id name="_Toc24963761"/}}Operating procedures**
997 997  
998 998  **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]]
999 999  
... ... @@ -1030,7 +1030,7 @@
1030 1030  (% style="text-align:center" %)
1031 1031  [[image:V-BOX HTTP manual_html_cd9ce84648b86cb9.png||height="269" width="700" class="img-thumbnail"]]
1032 1032  
1033 -**3.8.3 Result**
1042 +**Result**
1034 1034  
1035 1035  {
1036 1036  
... ... @@ -1109,9 +1109,9 @@
1109 1109  (% style="text-align:center" %)
1110 1110  [[image:V-BOX HTTP manual_html_d4a3e0114c402c27.png||height="475" width="700" class="img-thumbnail"]]
1111 1111  
1112 -== **3.9 Get device state** ==
1121 +== **Get device state** ==
1113 1113  
1114 -**3.9.1 {{id name="_Toc24963760"/}}Parameters**
1123 +**~ {{id name="_Toc24963760"/}}Parameters**
1115 1115  
1116 1116  (% class="table-bordered" %)
1117 1117  |**acturl**|(% colspan="3" %)we-data/getDeviceState
... ... @@ -1121,7 +1121,7 @@
1121 1121  |(% rowspan="2" %)**Return value**|Field name|(% colspan="2" %)Description
1122 1122  |state|(% colspan="2" %)vbox state: 1-online,  0-offline
1123 1123  
1124 -== **3.10 Send switch to device** ==
1133 +== **Send switch to device** ==
1125 1125  
1126 1126  **3.10.1 {{id name="_Toc24963760"/}}Parameters**
1127 1127  
... ... @@ -1132,9 +1132,9 @@
1132 1132  |(% style="width:450px" %)boxId|(% colspan="2" %)boxId(required)
1133 1133  |(% rowspan="1" style="width:102px" %)**Return value**|(% style="width:450px" %)Field name|(% colspan="2" %)Description
1134 1134  
1135 -= **4 Appendix** =
1144 += **Appendix** =
1136 1136  
1137 -== (% style="color:inherit; font-family:inherit; font-size:26px" %)**4.1 Data type**(%%) ==
1146 +== (% style="color:inherit; font-family:inherit; font-size:26px" %)**Data type**(%%) ==
1138 1138  
1139 1139  100: 16-bit binary
1140 1140