Use the Get Active Reachable Transitions method to receive an XML file that contains the state transitions for a specified work order state within a specified workflow. The XML file contains only the state transitions that are directly reachable from the specified work order state.
HTTP method: GET
URI: /workorder/connection_name/transitions/workflow_id/state_id
Request payload content type: None
Response payload content type: application/xml
Expected response: HTTP/1.1 200 OK
The method URI contains the following parameters.
| Name | Description | Required |
|---|---|---|
| connection_name | Enter the name that identifies the Optim™ directory connection that contains the work order. | Y |
| workflow_id | Enter the ID that identifies the workflow whose reachable transitions you want to receive. Enter 1 for the default workflow that is used by the manager. | Y |
| state_id | Enter the ID that identifies the state whose reachable transitions you want to receive. | Y |
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<ns2:transitions xmlns:ns2="http://www.ibm.com/optim/xsd/workorder/9.1.0">
<ns2:transition>
<id>2</id>
<wfId>1</wfId>
<oldStateId>200</oldStateId>
<transitionName>DENY</transitionName>
<newStateId>250</newStateId>
<owner>2</owner>
</ns2:transition>
<ns2:transition>
<id>4</id>
<wfId>1</wfId>
<oldStateId>200</oldStateId>
<transitionName>TERMINATE</transitionName>
<newStateId>999</newStateId>
<owner>1</owner>
</ns2:transition>
<ns2:transition>
<id>5</id>
<wfId>1</wfId>
<oldStateId>200</oldStateId>
<transitionName>TERMINATE</transitionName>
<newStateId>999</newStateId>
<owner>2</owner>
</ns2:transition>
<ns2:transition>
<id>6</id>
<wfId>1</wfId>
<oldStateId>200</oldStateId>
<transitionName>TERMINATE</transitionName>
<newStateId>999</newStateId>
<owner>3</owner>
</ns2:transition>
<ns2:transition>
<id>10</id>
<wfId>1</wfId>
<oldStateId>200</oldStateId>
<transitionName>APPROVE</transitionName>
<newStateId>300</newStateId>
<owner>2</owner>
</ns2:transition>
</ns2:transitions>
The following response codes can be received when the method is complete.
| Response code | Description |
|---|---|
| 200 | OK. The active reachable transitions list was successfully returned. |
| 400 | Bad Request. A malformed request was submitted. |
| 404 | Not Found. No active reachable transitions exist for the workflow ID and state ID. |