GET Workflow Instances AssignedToMe

The GET /WorkflowClosed A workflow is a series of steps necessary to complete a process. In Keyfactor Command, it refers to the workflow builder, which allows you to automate event-driven tasks such as when a certificate is requested, revoked or found in a certificate store./Instances/AssignedToMe operation retrieves the list of initiated workflows awaiting input from the user making the APIClosed An API is a set of functions to allow creation of applications. Keyfactor offers the Keyfactor API, which allows third-party software to integrate with the advanced certificate enrollment and management features of Keyfactor Command. request. Query parameters support filtering using defined criteria, control over pagination by specifying the page number and return limit, and customization of sorting based on specified fields and order. On success, the operation returns HTTP 200 OK with  details about the workflow instances.

Note:  If a workflow instance is initiated for a workflow definition that has more than one step requiring input (signals), a user can only provide that input (for example, approve or deny a require approval request) at the step in the workflow instance where the workflow instance was suspended pending input. The user cannot jump ahead and provide input for future steps in the workflow that have not yet occurred.
Tip:  The following permissions (see Security Roles and Claims) are required to use this feature:

/workflows/instances/read/
OR
/workflows/instances/read/pending/

Table 1183: GET Workflow Instances AssignedToMe Input Parameters

Name In Description
QueryString Query

A string containing a query to limit the results (for example, field1 -eq value1 AND field2 -gt value2). The default is to return all records. Fields available for querying through the API for the most part match those that appear in the Keyfactor Command Management Portal search dropdowns for the same feature. For querying guidelines, refer to: Searching Workflows Assigned to Me. The query fields supported for this operation are:

  • DefinitionId (workflow definition ID)
  • Id (workflow instance GUID)
  • InitiatingUserName (DOMAIN\\username)
  • LastModified
  • ReferenceId (workflow instance integer ID)
  • StartDate
  • Status
  • Title
  • WorkflowType
PageReturned Query

An integer that specifies how many multiples of the returnLimit to skip and offset by before returning results, to enable paging. The default is 1.

ReturnLimit Query

An integer that specifies how many results to return per page. The default is 50. Very large values can result in long processing time.

SortField Query

A string containing the property by which the results should be sorted. Fields available for sorting through the API include:

  • Id

  • LastModified

  • ReferenceId

  • StartDate

  • Status

  • Title

Available sort fields are affected by the query provided in QueryString. The default sort field is SQLrecordID.

SortAscending Query

An integer that sets the sort order on the returned results. A value of 0 sorts results in ascending order while a value of 1 sorts results in descending order. The default is ascending.

Table 1184: GET Workflow Instances AssignedToMe Response Data

Name

Description

Id A string indicating the Keyfactor Command reference GUID of the workflow instance.
Status

A string indicating the current status of the workflow instance. The possible statuses are:

  • CanceledForRestart
  • Complete
  • Failed
  • Rejected
  • Running
  • Waiting for Approval

Only instances with a Status of Waiting for Approval are returned using this operation.

Current Step ID A string indicating the Keyfactor Command reference GUID of the workflow instance step.
Status Message

A string indicating the current status message for the workflow instance. Possible status messages vary and may include:

  • Access is denied
  • Awaiting # more approvals from approval roles.
  • Either the credentials are invalid, or the CA on [CA host name] is not running

  • Issued

  • Issued. The private key was successfully retained.

  • Post-process Failed: [Message indicating reason for failure most often from the CA]

  • Pre-process failed: [Message indicating details of the failure]

  • Revoked

  • Step ‘Keyfactor-Enroll’ failed: [Message indicating details of the failure]

  • Step ‘Keyfactor-Revoke’ failed:[Message indicating details of the failure]

  • Step [custom step name] failed: [Message indicating details of the failure]

  • Taken Under Submission. The certificate template requires manager approval, and is marked as pending.

  • Workflow rejected by user with Id #.

Only instances with a StatusMessage of Awaiting # more approval(s) from approval roles. are returned using this operation.

Definition

An object containing the workflow definition. ClosedShow workflow definition details.

Current Step Display Name A string indicating the display name defined for the workflow instance step.
Current Step Unique Name A string indicating the unique name defined for the workflow instance step. This value is unique among the steps in a particular workflow definition. It is intended to be used as a user-friendly reference ID.
Title

A string indicating a description for the action taking place in the step, made up of the InitiatingUserName (either DOMAIN\\username or Timer Service) followed by an indication of the type of action and a specific message about the action. For example:

"KEYEXAMPLE\\jsmith is enrolling for a certificate with CN=appsrvr14.keyexample.com."

Or

"KEYEXAMPLE\\jsmith is revoking certificate with CN=appsrvr12.keyexample.com."
Last Modified A string indicating the date and time on which the initiated instance was last updated. The instance is updated each time a step in the workflow is completed, when signals are received for a step that accepts signals (for example, a requires approval step), or when an instance is stopped or restarted.
Start Date A string indicating the date and time when the instance was initiated.
Reference Id A integer indicating the Keyfactor Command reference ID for the workflow instance.
Tip:  See the Keyfactor API Reference and Utility, which allows you to call API operations and view results. It is primarily intended for validation, testing, and workflow development, and also serves as an interactive supplement to this API documentation. You can access it from the help menu () in the Management Portal.