Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
en:sidebar:remoteapi:codesamples:resources [05/06/2019 12:39]
chdi [Creating geozone]
en:sidebar:remoteapi:codesamples:resources [05/06/2019 13:08]
chdi [Deleting POI]
Line 46: Line 46:
 </​code>​ </​code>​
  
-===== Editing ​POI =====+===== Editing ​geozone ​=====
  
 Now let's change the name and radius of the new geozone: Now let's change the name and radius of the new geozone:
Line 52: Line 52:
 https://​hst-api.wialon.com/​wialon/​ajax.html?​svc=resource/​update_zone&​ https://​hst-api.wialon.com/​wialon/​ajax.html?​svc=resource/​update_zone&​
  params={  params={
- "itemId":37, + "n":"​Gurtam", 
- "id":8+"d":"​Autopista M-50, San Fernando de Henares 28830, Madrid, Spain", 
- "callMode":"​update", +"t":3, 
- "n":"​gurtam_office", /* change from "Madrid" ​to "gurtam_office" ​*/ +"w":5000, 
- "d":"​geozone", +"f":112, 
- "y":53.91069937030936+"c":​2568583984,​ 
- "x":27.516643322771575+"tc":16733440, 
- "r":5000, /* change from 100000 to 5000*/ +"ts":12
- "f":1+"min":0
- "c":16733440, +"max":18
- "tc":0+"libId":""​
- "ts":20+"path":""​
- "min":0+"p":[{"​x":​-3.715235,"y":40.415273,"​r":​10000}]
- "max":18+"itemId":37
 +"id":8
 +"callMode":"​update"​
  }&​sid=<​your_sid>​  }&​sid=<​your_sid>​
 </​code>​ </​code>​
Line 71: Line 73:
 <code javascript>​ <code javascript>​
 [1, { [1, {
-    "​id": ​1, +    ​[8,​{"​n":"​Gurtam","​d":"​Autopista M-50, San Fernando de Henares 28830, Madrid, Spain",​"​id":​8,"f":112,"t":3,"w":5000,"​e":​19652,"​c":​2568583984,"​i":​4294967295,"​libId":​0,"​path":"","​b":​{"​min_x":​-3.83305691988,"min_y":40.3252262094,"max_x":-3.59741308012,"max_y":40.5053197906,"cen_x":​-3.715235,"​cen_y":​40.415273},"​ct":​1559737413,"​mt":1559737413}]
-    ​"n": "gurtam_office", +
-    ​"y": ​53.9106993703, +
-    ​"x": ​27.5166433228, +
-    ​"t": ​0, +
-    ​"i": ​6515, +
-    ​"e": ​50676+
 }] }]
 </​code>​ </​code>​
  
-You can check how changes have been applied by making the request [[../​apiref/​resource/​get_poi_data|get_poi_data]].+===== Deleting geozone =====
  
-===== Deleting POI ===== +To delete a geozone, use the request resource/update_geozone:
- +
-To delete a POI, use the request ​[[../​apiref/​resource/update_poi|update_poi]]:+
 <​code>​ <​code>​
-https://​hst-api.wialon.com/​wialon/​ajax.html?​svc=resource/​update_poi&+https://​hst-api.wialon.com/​wialon/​ajax.html?​svc=resource/​update_geozone&
  params={  params={
- "​itemId":​50936+ "​itemId":​37
- "​id":​1,+ "​id":​8,
  "​callMode":"​delete"​  "​callMode":"​delete"​
  }&​sid=<​your_sid>​  }&​sid=<​your_sid>​
Follow us on Facebook Gurtam Wialon Twitter Gurtam Wialon info@gurtam.com   |   Copyright © 2002-2024 Gurtam