Api session event editor netline move and insert
API Endpoint: api/session/event/editornetline/move_and_insert/
Description: Place an existing Net Node at a new location and insert it in an existing Net Line. Potentially split the Net Line into two parts. Also specify at what distance the new Net Nodes are merged with existing Nodes
| Index | Importance | Type | Description | Values |
|---|---|---|---|---|
| 0 | REQUIRED | (NET_NODE Integer ID) | Net Node | |
| 1 | REQUIRED | (NET_LINE Integer ID) | Net Line | |
| 2 | REQUIRED | (Point 3D with crs: EPSG:3857) | New Node Point | |
| 3 | 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
Curl example POST
curl 'https://engine.tygron.com/api/session/event/editornetline/move_and_insert/?crs=3857' -H 'Content-Type: application/json' -H 'Authorization: Bearer API_TOKEN' -d '
[ 1, 1, {
"type" : "Point",
"coordinates" : [ 658788.946651797, 6799363.651436119, -0.22 ]
} ]
'Curl example multi item POST
curl 'https://engine.tygron.com/api/session/event/editornetline/move_and_insert/?crs=3857' -H 'Content-Type: application/json' -H 'Authorization: Bearer API_TOKEN' -d '
[ 1, 1, {
"type" : "Point",
"coordinates" : [ 658784.4721568585, 6799368.337013238, -1.26 ]
} ]
'JavaScript example POST
var options = {
method: "POST",
headers: { "Content-Type": "application/json", "Authorization": "Bearer API_TOKEN" },
body: '[ 1, 1, { "type" : "Point", "coordinates" : [ 658788.946651797, 6799363.651436119, -0.22 ]} ]'
};
fetch("https://engine.tygron.com/api/session/event/editornetline/move_and_insert/?crs=3857", options)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));