List the archived workflows for a system
You can use this operation to list the archived z/OSMF workflows for a system or sysplex.
HTTP method and URI path
GET /zosmf/workflow/rest/<version>/archivedworkflows
In this request, the URI path variable <version> identifies the version of the z/OSMF workflow service. The following value is valid: 1.0.
Query parameters
- Orderby
- To sort the returned instances by time, specify either of the following values:
- “desc”:
- From the newest to the oldest
- “asc”:
- From the oldest to the newest
- View
- An string type to select the list instances by view:
- “user”:
- Return the archived workflow instances that are owned by the user, up to a maximum of 200 workflow instances. This value is the default.
- “domain”:
- For archived provisioning workflows, return the instances that the user is authorized to view. The user must be a domain owner. The results are grouped by domain, with up to 200 instances per domain.
- Query parameters are optional; you can specify one or more query parameters, as needed.
- You use a question mark ('?') to separate the first query parameter from the resource.
- To specify multiple query parameters in combination, use an ampersand (&).
Description
This operation retrieves a list of archived workflows that you are authorized to view.
On successful completion, HTTP status code 200 (OK) is returned and the response body is provided, as described in Table 2.
Authorization requirements
HTTP status codes
On successful completion, HTTP status code 200 (OK) is returned.
Otherwise, the following HTTP status codes are returned for the indicated errors. The response body is a standard error response body providing the reason code that is indicated and associated error message.
HTTP error status code | Description |
---|---|
HTTP 400 Bad request | The request contained an error, such as an incorrect query parameter. |
Additional standard status codes can be returned, as described in HTTP status codes.
Response content
On successful completion, the response body contains one property, which is called archived workflows. This property is an array of workflow-info objects. Table 2 lists the fields in the workflow-info object. If no workflows match the filter criteria, HTTP status code 200 (OK) is returned with an empty array.
Field name | Type | Description |
---|---|---|
workflowName | String | Descriptive name for the workflow. |
workflowKey | String | Workflow key. A string value, generated by z/OSMF to uniquely identify the workflow instance. |
archivedInstanceURI | String | Workflow instance URI path, which you can use to retrieve information about the archived workflow. |
Example HTTP interaction
GET /zosmf/workflow/rest/1.0/archivedworkflows?orderBy=desc HTTP/1.1
Host: zosmf1.yourco.com
Connection: close
Authorization: Basic em9zbWZhZDp6b3NtZmFk
HTTP/1.1 200 OK
content-length: 464
content-language: en-US
x-powered-by: Servlet/3.0
server: WebSphere Application Server
connection: Close
date: Wed, 11 Feb 2015 18:30:34 GMT
content-type: application/json; charset=UTF-8
HTTP/1.1 200 OK
{
"archivedWorkflows": [
{
"workflowName": "Sample demonstrating variable substitution and the use of a wizard. - Workflow_5",
"workflowKey": "2535b19e-a8c3-4a52-9d77-e30bb920f912",
"archivedInstanceURI": "\/zosmf\/workflow\/rest\/1.0\/archivedworkflows\
/2535b19e-a8c3-4a52-9d77-e30bb920f912"
},
{
"workflowName": "Sample demonstrating variable substitution and the use of a wizard. - Workflow_0",
"workflowKey": "8f0f572a-0eb5-493e-91b2-3d549374e07d",
"archivedInstanceURI": "\/zosmf\/workflow\/rest\/1.0\/archivedworkflows\
/8f0f572a-0eb5-493e-91b2-3d549374e07d"
},
{
"workflowName": "Sample demonstrating variable substitution and the use of a wizard. - Workflow_5",
"workflowKey": "1aead54d-3507-4473-9cda-e4fd25eb21b8",
"archivedInstanceURI": "\/zosmf\/workflow\/rest\/1.0\/archivedworkflows\
/1aead54d-3507-4473-9cda-e4fd25eb21b8"
}
]
}