Alter (Circuits)

URL:
https://<root>/<serviceName>/UtilityNetworkServer/circuits/alter
Methods:
GETPOST
Version Introduced:
11.5

The alter operation on the circuits resource allows you to modify circuit information for an existing circuit in a telecom domain network. The alter operation replaces the existing circuit definition with that provided in the circuits parameter. If any properties or information is excluded from the circuit definition in the parameter, it is removed from the circuit.

When the operation is successful, the editor tracking fields for the circuit in the circuit management tables are updated.

Request parameters

ParameterDetails

f

Specifies the output format of the response. The default response format is html.

Use dark colors for code blocksCopy
1
f=html | json | pjson

gdbVersion

(Optional)

Specifies the name of the geodatabase version. The default is 'sde.DEFAULT'.

Syntax: gdbVersion=<version>

sessionId

(Optional)

Specifies the token (guid) used to lock the version. If a client has previously started an edit session and holds an exclusive lock on the version specified, the request will fail if the sessionId is not provided. If the specified version is currently locked by any other session, the request will fail if the sessionId is not provided or does not match the sessionId that holds the exclusive lock.

Syntax: sessionId=<guid>

domainNetworkName

(Required)

Specifies the name of the telecom domain network containing the circuit to be altered.

Syntax: domainNetworkName=<string>

Example: domainNetworkName=Telco

circuit

(Required)

The circuit or circuit information to be altered.

Syntax:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
{
"circuits":[
	{
	"name": <string>,
	"globalId": <guid>,
	"isSectioned": <boolean>,
	"sectionOrder": <string>,
	"circuitType": "Physical" | "Virtual",               // Default is Physical
	"startPoint" :              // Only if isSectioned is false
		{
			"sourceId"   : <short>,
			"globalId"   : <guid>,
			"terminalId" : <short>,
			"firstUnit"  : <short>,
			"numUnits"   : <short>
		},
	"stopPoint" :               // Only if isSectioned is false
		{
			"sourceId"   : <short>,
			"globalId"   : <guid>,
			"terminalId" : <short>,
			"firstUnit"  : <short>,
			"numUnits"   : <short>
		},
	"sections": [
		{
			"sectionId": <long>,
			"role": "Start and end"| "Start" | "End" | "Midspan",               // Default is Start and end
			"sectionType": "Physical" | "Virtual",               // Default is Physical
			"startPoint": {
				"sourceId"   : <short>,
				"globalId"   : <guid>,
				"terminalId" : <short>,
				"firstUnit"  : <short>,
				"numUnits"   : <short>
			},
			"stopPoint": {
				"sourceId"   : <short>,
				"globalId"   : <guid>,
				"terminalId" : <short>,
				"firstUnit"  : <short>,
				"numUnits"   : <short>
			}
		}
	],
	"subcircuits": [
		{
			"name": <string>,
			"globalId": <guid>,
			"providerId": <guid>,
			"consumerId": <guid>,
			"isReserved": true | false               // Default is false
		}
	]
}

JSON Response syntax

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
{
  "success" : <boolean>,
  "error" : {                   // only if success is false
    "extendedCode" : <HRESULT>,
    "message" : <string>,
    "details" : [ <string> ]
	}
}

Example usage

Request URL and parameters:

https://myserver.esri.com/server/rest/services/Telco/UtilityNetworkServer/circuits/alter

Use the alter operation to make modifications to a sectioned circuit named A48/T3U/89032834/89253420. The circuit was created with a single section using the createoperation on the circuits resource as follows:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32

f=json
gdbVersion=sde.Default
domainNetworkName=Telco
circuit={
	"name": "A48/T3U/89032834/89253420",
	"globalId" : "{D592806A-4EDD-458A-92C2-7A653556C131}",
	"circuitType": "Physical",
	"isSectioned": true,
	"sections": [
		{
			"sectionId": 1,
			"role": "Start and end",
			"sectionType": "Physical",
			"startPoint": {
				"sourceId": 20,
				"globalId": "{8A1B5A33-3EBA-42CC-9085-31B22DAFE5DC}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			},
			"stopPoint": {
				"sourceId": 20,
				"globalId": "{F081B917-499E-43FC-AEC9-7C1B313BF128}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			}
		}
	],
	"subcircuits": []
}

Add a second section and subcircuit to the circuit created above using the alter operation:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59

f=json
gdbVersion=sde.Default
domainNetworkName=Telco
circuit={
	"name": "A48/T3U/89032834/89253420",
	"globalId": "{D592806A-4EDD-458A-92C2-7A653556C131}",
	"circuitType": "Physical",
	"isSectioned": true,
	"sections": [
		{
			"sectionId": 1,
			"role": "Start",
			"sectionType": "Physical",
			"startPoint": {
				"sourceId": 20,
				"globalId": "{8A1B5A33-3EBA-42CC-9085-31B22DAFE5DC}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			},
			"stopPoint": {
				"sourceId": 20,
				"globalId": "{F081B917-499E-43FC-AEC9-7C1B313BF128}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			}
		},
		{
			"sectionID": 2,
			"role": "End",
			"sectionType": "Physical",
			"startPoint": {
				"sourceId": 20,
				"globalId": "{F081B917-499E-43FC-AEC9-7C1B313BF128}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			},
			"stopPoint": {
				"sourceId": 20,
				"globalId": "{A8ADC6B0-B7DB-4999-ADB3-D7958F10D4A8}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			}
		}
	],
	"subcircuits": [
		{
			"name": "S1A48/T3U/89032834/89253420",
			"providerId": "{661614F5-4A19-404A-B4F2-F3D7F1D2362B}",
			"consumerId": "{FFBA459C-28A6-4978-88F8-3C0A34C81BF4}",
			"isReserved": false

		}
	]
}

Remove the first section and subcircuit from the circuit using the alter operation: 

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32

f=json
gdbVersion=sde.Default
domainNetworkName=Telco
circuit={
	"name": "A48/T3U/89032834/89253420",
	"globalId": "{D592806A-4EDD-458A-92C2-7A653556C131}",
	"circuitType": "Physical",
	"isSectioned": true,
	"sections": [
		{
			"sectionID": 2,
			"role": "Start and end",
			"sectionType": "Physical",
			"startPoint": {
				"sourceId": 20,
				"globalId": "{F081B917-499E-43FC-AEC9-7C1B313BF128}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			},
			"stopPoint": {
				"sourceId": 20,
				"globalId": "{A8ADC6B0-B7DB-4999-ADB3-D7958F10D4A8}",
				"terminalId": 1,
				"firstUnit": 1,
				"numUnits": 1
			}
		}
	],
	"subcircuits": []
}

JSON response:

Use dark colors for code blocksCopy
1
2
3
{
	"success": true
}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.