Api session event editor measure import upgrades

From Tygron Support wiki
Revision as of 07:51, 31 March 2026 by Frank@tygron.nl (talk | contribs)
Jump to navigation Jump to search

API Event to Import Measure Upgrade Collection

Name Importance Type Description Values
0 REQUIRED (GeometryCollection with crs: EPSG:3857) Collection of Upgrade Geometries
1 REQUIRED (UPGRADE_TYPE Integer ID or multiple values in array [1, 2, 3]) Upgrade Type
2 OPTIONAL (MEASURE Integer ID) Set for existing Measure ID (optional)
3 OPTIONAL (Floating point number) Buffer for Points and Lines to make Polygons (optional)
4 OPTIONAL (SOURCE Integer ID) Source (optional)

Response Codes

Response Code: Description
200 Integer (Measure ID)
300-600 Codes Overview

Example POST

Example POST: https://engine.tygron.com/api/session/event/editormeasure/import_upgrades/?crs=3857&f=HTML&token=API_TOKEN

with content:

[ {
 "type" : "GeometryCollection",
 "geometries" : [ {
 "type" : "MultiPolygon",
 "coordinates" : [ [ [ [ 658636.7618515313, 6799461.8964563515 ], [ 658636.7618515313, 6799431.206838901 ], [ 658746.6590203216, 6799431.206838901 ], [ 658746.6590203216, 6799461.8964563515 ], [ 658636.7618515313, 6799461.8964563515 ] ] ] ]
 }, {
 "type" : "MultiPolygon",
 "coordinates" : [ [ [ [ 658636.7618515313, 6799461.8964563515 ], [ 658636.7618515313, 6799410.70709681 ], [ 658748.1808358415, 6799410.70709681 ], [ 658748.1808358415, 6799461.8964563515 ], [ 658636.7618515313, 6799461.8964563515 ] ] ] ]
 }, {
 "type" : "MultiPolygon",
 "coordinates" : [ [ [ [ 658636.7618515313, 6799461.8964563515 ], [ 658636.7618515313, 6799448.154652527 ], [ 658678.4907801906, 6799448.154652527 ], [ 658678.4907801906, 6799461.8964563515 ], [ 658636.7618515313, 6799461.8964563515 ] ] ] ]
 } ]
}, [ 1, 2, 3 ], "", "", "" ]