Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation  Back up to About Overview 
ContentIndex
  
[+] Expand All
[-] Collapse All

Transactions RESTful Web Services

The following operations can be performed using the Edge Services Director Transactions RESTful Web Services. A transaction refers to an operation or a task that is performed on the service definitions, configuration parameters, and policy settings that are created for provisioning on the devices or Service Delivery Gateways (SDGs).

Get All Transactions

This request is used to retrieve all the transactions associated with deploy plans. A one-to-one mapping exists between the deployment plan and a transaction. A unique identifier for each transaction for easy tracking and filtering is automatically assigned by the Edge Services Director application.

URI

/api/sgd/configmanager/transactionmgmt/getalltransactions?page=1&start=0&limit=30

HTTP Method

GET

Content-Type

application/vnd.net.juniper.space.configmanager.
transactionmgmt.getalltransactions?page=1&start=0&limit=30+json;
version=1;charset=UTF-8

Consumes

None

Produces

Collects all the transactions created

Response Status Code

Message

Description

200 OK

Successful collection of all created transactions

Output

Sample JSON Output

{ "response" : { "data" : { "deploymentPlans" : 70302,
          "jobID" : 163879,
          "serviceInstances" : "lb1",
          "timeStamp" : "2014-11-18T11:11:10+05:30",
          "transactionID" : 70503,
          "transactionStatus" : "success",
          "transactionStatusMsg" : "There is no configuration change."
        },
      "success" : true,
      "totalRows" : 1
    } }

Get a Transaction By ID

This request is used to retrieve details of a specific transaction based on its identifier.

URI

/api/sgd/configmanager/transactionmgmt/gettransactiondetailbyid/{transactionId}

HTTP Method

GET

Content-Type

application/vnd.net.juniper.space.configmanager.
transactionmgmt.gettransactiondetailbyid.{transactionId}+json;
version=1;charset=UTF-8

Consumes

None

Produces

Collects details for a particular transaction

Response Status Code

Message

Description

200 OK

Successful collection of a particular transaction

Output

Sample JSON Output

{ "transdetailresponse" : { "data" : [ { "host" : "mobst480x",
            "hostId" : 32891,
            "hostStatus" : "success",
            "hostStatusMsg" : "There is no configuration change.",
            "sdgId" : 33091,
            "sdgName" : "mobst480w-mobst480x",
            "transactionID" : 70503
          },
          { "host" : "mobst480w",
            "hostId" : 32937,
            "hostStatus" : "success",
            "hostStatusMsg" : "There is no configuration change.",
            "sdgId" : 33091,
            "sdgName" : "mobst480w-mobst480x",
            "transactionID" : 70503
          }
        ] } }

Get Previous Configuration Details

This request is used to retrieve the XML form of configuration parameters and statements that are currently running on the device.

URI

/api/sgd/configmanager/transactionmgmt/
getconfigdetails/{transId}/{sdgId}/{hostId}/previousConfig

HTTP Method

GET

Content-Type

application/vnd.net.juniper.space.configmanager.
transactionmgmt.getconfigdetails.{transId}.
{sdgId}/{hostId}.previousConfig}+json;
version=1;charset=UTF-8

Consumes

None

Produces

Displays the currently running configuration on a device

Response Status Code

Message

Description

200 OK

Successful display of currently running configuration on a device

Output

Sample JSON Output

    <configuration>
            <version>14.2-20140710_ib_14_2_psd.1</version>
            <groups>
                <name>re0</name>
                <system>
                    <host-name>sugar</host-name>
                    <backup-router>
                        <address>192.168.184.126</address>
                        <destination>0.0.0.0/0</destination>
                    </backup-router>
                </system>
                <interfaces>
                    <interface>
                        <name>fxp0</name>
                        <unit>
                            <name>0</name>
                            <family>
                                <inet>
                                    <address>
                                        <name>192.168.184.76/25</name>
                                    </address>
                                </inet>
                            </family>
                        </unit>
                    </interface>
                </interfaces>
            </groups>
            <groups>
                <name>re1</name>
                <system>
                    <host-name>sugar1</host-name>
                    <backup-router>
                        <address>192.168.184.126</address>
                        <destination>0.0.0.0/0</destination>
                    </backup-router>
                </system>
                <interfaces>
                    <interface>
                        <name>fxp0</name>
                        <unit>
                            <name>0</name>
                            <family>
                                <inet>
                                    <address>
                                        <name>192.168.184.78/25</name>
                                    </address>
                                </inet>
                            </family>
                        </unit>
                    </interface>
                </interfaces>
            </groups>
            <groups>
                <name>global</name>
                <system>
                    <domain-name>device1.example.com</domain-name>
                    <domain-search>device1.example.com</domain-search>
                    <domain-search>example.com</domain-search>
                    <domain-search>example1.com</domain-search>
                    <domain-search>device2.example.com</domain-search>
                    <time-zone>America/Los_Angeles</time-zone>
                    <undocumented><debugger-on-panic/></undocumented>
                    <undocumented><debugger-on-break/></undocumented>
                    <undocumented><dump-on-panic>
                    </dump-on-panic></undocumented>
                    <authentication-order>radius</authentication-order>
                    <authentication-order>password</authentication-order>
                    <authentication-order>tacplus</authentication-order>
                    <root-authentication>
                        <encrypted-password>$1$ZUlES4dp$OUwWo1g7cLoV/aMWpHUnC/</
encrypted-password>
                    </root-authentication>
                    <name-server>
                        <name>192.168.5.68</name>
                    </name-server>
                    <name-server>
                        <name>172.17.28.101</name>
                    </name-server>
                    <name-server>
                        <name>172.17.28.100</name>
                    </name-server>
                    <radius-server>
                        <name>192.168.69.162</name>
                        <secret>$9$N0-YoDjq.PT4oZjik5T369pBIhSlL7dCtKWLNws</secr
et>
                    </radius-server>
                    <radius-server>
                        <name>192.168.60.52</name>
                        <secret>$9$peFVuRSvMXxNVcSlMWLdVYgoGikmfQ9t0aZF69p1I</se
cret>
                    </radius-server>
                    <radius-server>
                        <name>192.168.64.10</name>
                        <secret>$9$oeajqTQn69tkqPQz3AtO1RSev8XNY4JEcdwYoUD</secr
et>
                    </radius-server>
                    <radius-server>
                        <name>192.168.60.55</name>
                        <secret>$9$4.oDk5T3n/AHkmTQFCA0BIclKWL7sgaRh-bs4GU</secr
et>
                    </radius-server>
                    <radius-server>
                        <name>192.168.4.240</name>
                        <secret>$9$Y02ZjmPQz3/DjkPfT6/tuORSrKMLVsgBIx-VYaJ</secr
et>
                    </radius-server>
                    <tacplus-server>
                        <name>192.168.5.73</name>
                        <secret>$9$Swge87g4Zk.5s2DkPQ9CcylKMX</secret>
                        <timeout>15</timeout>
                        <single-connection/>
                    </tacplus-server>
                    <login>
                        <class>
                            <name>wheel</name>
                            <permissions>admin</permissions>
                            <permissions>clear</permissions>
                            <permissions>field</permissions>
                            <permissions>floppy</permissions>
                            <permissions>interface</permissions>
                            <permissions>maintenance</permissions>
                            <permissions>network</permissions>
                            <permissions>reset</permissions>
                            <permissions>routing</permissions>
                            <permissions>shell</permissions>
                            <permissions>snmp</permissions>
                            <permissions>system</permissions>
                            <permissions>trace</permissions>
                            <permissions>view</permissions>
                        </class>
                        <class>
                            <name>readonly</name>
                            <permissions>interface</permissions>
                            <permissions>network</permissions>
                            <permissions>routing</permissions>
                            <permissions>system</permissions>
                            <permissions>trace</permissions>
                            <permissions>view</permissions>
                        </class>
                        <user>
                            <name>user</name>
                            <uid>928</uid>
                            <class>superuser</class>
                            <undocumented><shell>csh</shell></undocumented>
                            <authentication>
                                <encrypted-password>$1$kPU..$w.4FGRAGanJ8U4Yq6sb
j7.</encrypted-password>
                            </authentication>
                        </user>
                    </login>
                    <services>
                        <finger>
                        </finger>
                        <ftp>
                        </ftp>
                        <undocumented><rlogin>
                        </rlogin></undocumented>
                        <undocumented><rsh>
                        </rsh></undocumented>
                        <ssh>
                        </ssh>
                        <telnet>
                        </telnet>
                        <xnm-clear-text>
                        </xnm-clear-text>
                    </services>
                    <syslog>
                        <user>
                            <name>*</name>
                            <contents>
                                <name>any</name>
                                <emergency/>
                            </contents>
                        </user>
                        <host>
                            <name>log</name>
                            <contents>
                                <name>kernel</name>
                                <info/>
                            </contents>
                            <contents>
                                <name>any</name>
                                <notice/>
                            </contents>
                            <contents>
                                <name>pfe</name>
                                <info/>
                            </contents>
                            <contents>
                                <name>interactive-commands</name>
                                <any/>
                            </contents>
                        </host>
                        <file>
                            <name>messages</name>
                            <contents>
                                <name>kernel</name>
                                <info/>
                            </contents>
                            <contents>
                                <name>any</name>
                                <notice/>
                            </contents>
                            <contents>
                                <name>authorization</name>
                                <info/>
                            </contents>
                            <contents>
                                <name>pfe</name>
                                <info/>
                            </contents>
                            <archive>
                                <world-readable/>
                            </archive>
                        </file>
                        <file>
                            <name>security</name>
                            <contents>
                                <name>interactive-commands</name>
                                <any/>
                            </contents>
                            <archive>
                                <world-readable/>
                            </archive>
                        </file>
                    </syslog>
                    <processes>
                        <routing>
                            <undocumented><enable/></undocumented>
                        </routing>
                        <ntp>
                            <undocumented><enable/></undocumented>
                        </ntp>
                        <undocumented><management>
                            <enable/>
                        </management></undocumented>
                        <watchdog>
                            <enable/>
                        </watchdog>
                        <daemon-process>
                            <name>snmp</name>
                            <undocumented><enable/></undocumented>
                        </daemon-process>
                        <daemon-process>
                            <name>inet-process</name>
                            <undocumented><enable/></undocumented>
                        </daemon-process>
                        <daemon-process>
                            <name>mib-process</name>
                            <undocumented><enable/></undocumented>
                        </daemon-process>
                    </processes>
                    <ntp>
                        <boot-server>172.17.28.5</boot-server>
                        <server>
                            <name>172.17.28.5</name>
                        </server>
                    </ntp>
                </system>
                <chassis>
                    <undocumented><dump-on-panic/></undocumented>
                </chassis>
                <interfaces>
                    <interface>
                        <name>lo0</name>
                        <unit>
                            <name>0</name>
                            <family>
                                <inet>
                                    <address>
                                        <name>127.0.0.1/32</name>
                                        <primary/>
                                    </address>
                                </inet>
                            </family>
                        </unit>
                    </interface>
                </interfaces>
                <snmp>
                    <location>Systest lab</location>
                    <contact>Jay Lloyd</contact>
                    <interface>fxp0.0</interface>
                    <community>
                        <name>public</name>
                        <authorization>read-only</authorization>
                    </community>
                    <community>
                        <name>private</name>
                        <authorization>read-write</authorization>
                    </community>
                </snmp>
                <routing-options>
                    <static>
---(more)---

Get Modified Configuration Details

This request is used to retrieve the XML form of configuration parameters and statements that are to be deployed on a device

URI

/api/sgd/configmanager/transactionmgmt/
getconfigdetails/{transId}/{sdgId}/{hostId}/modifiedConfig

HTTP Method

GET

Content-Type

application/vnd.net.juniper.space.configmanager.
transactionmgmt.getconfigdetails.{transId}.
{sdgId}/{hostId}.modifiedConfig+json;
version=1;charset=UTF-8

Consumes

None

Produces

Displays the configuration parameters and statements that are to be deployed on a device

Response Status Code

Message

Description

200 OK

Successful display of configuration parameters and statements that are to be deployed on a device

Output

Sample JSON Output

<configuration>
  <extensions>
    <adc>
      <adc-instance>
        <name>lb1</name>
        <real-servers>
          <real>
            <name>DNS1</name>
            <health-check>
              <interval>4</interval>
            </health-check>
          </real>
        </real-servers>
      </adc-instance>
    </adc>
  </extensions>
</configuration>

Get Configuration Difference Details

This request is used to retrieve the XML form of the differential set of configuration statements and attributes to be deployed on a device

URI

/api/sgd/configmanager/transactionmgmt/getconfigdetails/{transId}/{sdgId}/{hostId}/pconfigDiff

HTTP Method

GET

Content-Type

application/vnd.net.juniper.space.configmanager.
transactionmgmt.getconfigdetails.{transId}.{sdgId}/{hostId}.configDiff+json;
version=1;charset=UTF-8

Consumes

None

Produces

Displays the differential set of configuration statements and attributes to be deployed on a device

Response Status Code

Message

Description

200 OK

Successful display of the differential set of configuration statements and attributes to be deployed on a device

Output

Sample JSON Output

<configuration>
  <extensions>
    <adc>
      <adc-instance>
        <name>lb1</name>
        <real-servers>
          <real>
            <name>DNS1</name>
            <health-check>
              <interval>4</interval>
            </health-check>
          </real>
        </real-servers>
      </adc-instance>
    </adc>
  </extensions>
</configuration>

Modified: 2016-08-02