Api session event editor netline add for points

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

API Event to Connect start and end point with one (or more) Net Line(s) of a specified Net Function. Nodes are created for start and end point. Optionally connection the two points using the road system. Also specify at what distance the new Nodes are merged with existing Nodes.

Name Importance Type Description Values
0 REQUIRED (NET_FUNCTION Integer ID or multiple values in array [1, 2, 3]) Net Function ID
1 REQUIRED (Point 3D with crs: EPSG:3857 or multiple values in array [a, b, c]) Start Point
2 REQUIRED (Point 3D with crs: EPSG:3857 or multiple values in array [a, b, c]) End Point
3 OPTIONAL (true, false) Connect via Roads (false = connect direct between points)
4 OPTIONAL (Floating point number) Node merge distance (optional, default: 1.0m)

Response Codes

Response Code: Description
204 No Content
300-600 Codes Overview

Example POST

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

with content:

[ [ 1, 2, 3 ], [ {
 "type" : "Point",
 "coordinates" : [ 658719.9387333055, 6799369.711016604, -1.17 ]
}, {
 "type" : "Point",
 "coordinates" : [ 658737.5053892966, 6799445.958824552, -1.72 ]
}, {
 "type" : "Point",
 "coordinates" : [ 658753.7402536907, 6799401.99041821, -1.93 ]
} ], [ {
 "type" : "Point",
 "coordinates" : [ 658666.920434658, 6799310.635578711, -0.49 ]
}, {
 "type" : "Point",
 "coordinates" : [ 658647.658180585, 6799323.708016394, -1.79 ]
}, {
 "type" : "Point",
 "coordinates" : [ 658653.0356951917, 6799318.778849001, -0.52 ]
} ], false, 1.0 ]