AE REST API - Execute Objects with and without Inputs
You can get the expected input, execute objects, monitor objects and their children, and get object variables of executions with and without inputs (PromptSets).
This page includes the following:
Get Expected Input
Get variables of PromptSet assigned to the object.
Request: GET http://{host}:{port}/ae/api/v1/{client}/objects/{object name}/inputs
Example: http://my-jcp-host:8088/ae/api/v1/8001/objects/WORKFLOW.DEMO/inputs
HTTP 200 Response:
{ "PRPT.WORKFLOW.2": { "NUMBER100#": "0", "TEXT100#": null }, "PRPT.WORKFLOW.1": { "TEXT1#": null, "RADIOGROUP1#": null, "CHECKBOX1#": [], "COMBOBOX1#": null, "NUMBER1#": "0", "DATETIME1#": "171214" } }
Execute Object
Request: POST http://{host}:{port}/ae/api/v1/{client}/executions
Example: http://my-jcp-host:8088/ae/api/v1/8001/executions
Immediately
Execute the object immediately and pass input variables (PromptSet variables) with an alias name.
{ "object_name": "WORKFLOW.DEMO", "alias": "WORKFLOW.DEMO.ALIAS", "inputs": { "TEXT1#": "passed text", "NUMBER1#": "1234", "COMBOBOX1#": "ANALYTICS", "RADIOGROUP1#": "Simple Rule", "CHECKBOX1#": ["ITPA Shared", "Simple Rule"], "DATETIME1#": "170730", "TEXT100#": "first passed line\nsecond passed line", "NUMBER100#": "7777" } }
HTTP 200 Response:
{ "run_id": 26350635 }
Once
{ "object_name": "SCRI.ONCE", "execution_option": "once", "alias": "MYSCRI.ONCE", "timezone": "TZ.PEPI1", "queue": "FAST.QUEUE", "inputs": { "NUMBER1#": "8888", "TEXT1#": "passed text" }, "once": { "wait_for_manual_release": "false", "execution_date_time": "2018-02-27T10:00:00Z", "use_logical_time": "2018-05-03T10:30:00Z" } }
HTTP 200 Response:
{ "run_id": 26350635 }
Recurring
{ "object_name": "SCRI.RECURRING", "alias": "SCRI.RECURRING.ALIAS.P2", "timezone": "TZ.MY", "queue": "FAST.QUEUE", "execution_option": "recurring", "inputs": { "NUMBER1#": "3333", "TEXT1#": "passed text" }, "recurring": { "start_date": "2016-03-18", "end_after_executions": "5", "execute_interval": "000:01", "between_start": "00:00", "between_end": "23:59", "allow_one_overlap": "false", "adjust_start_time": "true" } }
HTTP 200 Response:
{ "run_id": 26350635 }
Monitor Object Execution
Monitor object execution including alias, archive keys, title, estimated runtime.
Request: GET http://{host}:{port}/ae/api/v1/{client}/executions/{run id}
Example: http://my-jcp-host:8088/ae/api/v1/8001/executions/26355155
HTTP 200 Response:
{ "name": "SCRI.1", "type": "SCRI", "run_id": 26355155, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:51:06Z", "start_time": "2018-04-17T12:51:06Z", "end_time": "2018-04-17T12:51:06Z", "parent": 0, "user": "SMITH/DEP", "estimated_runtime": 0, "archive_key1": "myvalue1", "archive_key2": "myvalue2", "title": "MyTitle", "alias": "MY.ALIAS" }
Monitor Child Task Executions of a Workflow
Monitor children executions of a workflow including alias, archive keys, title, estimated runtime.
Without Pagination
Request: GET http://{host}:{port}/ae/api/v1/{client}/executions/{run id}/children
HTTP 200 Response:
{ "total": 3, "data": [ { "name": "SCRI1", "type": "SCRI", "run_id": 26352285, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:54:50Z", "start_time": "2018-04-17T12:54:50Z", "end_time": "2018-04-17T12:54:50Z", "parent": 26352284, "user": "SMITH/DEP", "estimated_runtime": 0, "alias": "SCRI1" }, { "name": "SCRI3", "type": "SCRI", "run_id": 26352287, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:54:50Z", "start_time": "2018-04-17T12:54:50Z", "end_time": "2018-04-17T12:54:50Z", "parent": 26352284, "user": "SMITH/DEP", "estimated_runtime": 1, "alias": "SCRI3" }, { "name": "SCRI2", "type": "SCRI", "run_id": 26352286, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:54:50Z", "start_time": "2018-04-17T12:54:50Z", "end_time": "2018-04-17T12:54:50Z", "parent": 26352284, "user": "SMITH/DEP", "estimated_runtime": 1, "alias": "SCRI2" } ], "hasmore": true }
With Pagination
This request includes pagination information through the query parameters.
Request: GET http://{host}:{port}/ae/api/v1/{client}/executions/{run id}/children?max_results={integer}&start_at_run_id={run id}
-
max_results = limit of resultset entries returned
-
start_at_run_id = run id of the execution of the last requested page
so this requested page returns executions with run id > start_at_run_id
Example: http://my-jcp-host:8088/ae/api/v1/8001/executions/23021234/children?max_results=1&start_at_run_id=263522
HTTP 200 Response:
{ "total": 3, "data": [ { "name": "SCRI3", "type": "SCRI", "run_id": 26352287, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:54:50Z", "start_time": "2018-04-17T12:54:50Z", "end_time": "2018-04-17T12:54:50Z", "parent": 26352284, "user": "SMITH/DEP", "estimated_runtime": 1, "alias": "SCRI3" }, ], "hasmore": true }
Get Object Variables of Executions
Exclusively
Request: GET http://{host}:{port}/ae/api/v1/{client}/executions/{run id}/variables
Example: http://my-jcp-host:8088/ae/api/v1/8001/executions/23021234/variables
HTTP 200 Response:
{ "VAR1#": "any text value", "VAR2#": "0000000000002345" }
Part of Execution Information
Request: GET http://{host}:{port}/ae/api/v1/{client}/executions/{run id}?fields=variables
Example: http://my-jcp-host:8088/ae/api/v1/8001/executions/23021234?fields=variables
HTTP 200 Response:
The object variables are listed within the sub-structure Variables at the bottom of the response.
{ "name": "SCRI.WITH.VARIABLES", "type": "SCRI", "run_id": 26355159, "status": 1900, "status_text": "ENDED_OK - ended normally", "runtime": 0, "activation_time": "2018-04-17T12:57:08Z", "start_time": "2018-04-17T12:57:08Z", "end_time": "2018-04-17T12:57:08Z", "parent": 0, "user": "SMITH/DEP", "estimated_runtime": 1, "alias": "SCRI.WITH.VARIABLES", "variables": { "VAR1#": "any text value", "VAR2#": "0000000000002345" } }
See also: