GET /hub/v1/approvals-v2/{id}
Retrieves an approval item belonging to current user. The response includes details of the approval and workflow item, with the current state and the transitions available for the current user's roles. Use the GET /approvals resource to retrieve all active approval items.
Name | Type | | Description |
---|
id | string | Required | Approval item id |
Status | Name | Type | Description |
---|
200 | | | Response includes details about the approval item. |
| approvalItemId | string | Id of approval item |
| objectType | string | Object type for the approval item |
| objectId | string | Unique Id of the object associated with the approval item |
| name | string | Name of approval item |
| description | string | Description of the approval item |
| workflowItemId | string | Id of the workflow item |
| workflowState | string | Workflow state of the approval item |
| workflowType | string | Type of workflow |
| workflowName | string | Name of the workflow |
| deadline | array | Deadline for the approval item |
| commentCounts | object | Comment counts |
| commentCounts.open | string | Number of comments that are open |
| commentCounts.addressed | string | Number of comments that are addressed |
| commentCounts.completed | string | Number of comments that are completed |
| commentCounts.total | string | Total number of comments |
| workflowItem | object | Workflow item object |
| workflowItem.workflowItemId | string | Workflow item Id |
| workflowItem.workflowRound | string | Workflow round |
| workflowItem.type | string | Workflow type |
| workflowItem.currentState | object | Current state of the workflow |
| workflowItem.currentState.stateId | string | Id of the current state |
| workflowItem.currentState.stateName | string | Current state name |
| workflowItem.currentState.isEndState | string | Is the current state the final state? |
| workflowItem.currentState.modifiedDate | string | The date the workflow item is modified |
| workflowItem.availableTransitions | array | Collection of available workflow states |
| workflowItem.availableTransitions.id | string | Id of the available workflow state |
| workflowItem.availableTransitions.name | string | Name of the available workflow state |
| workflowItem.availableTransitions.isPersistable | string | Defines if the workflow item is persistable |
| blocked | string | Defines if emails will be sent out. If blocked = true, then emails will not be sent. |
| | | |
400 | | | id is a required field |
| message | string | id is a required field. |
| errorcode | string | Error code for the exception (10002) |
| | | |
404 | | | No active approval with the given id exists. |
| message | string | No active approval with the given id exists. |
| errorcode | string | Error code for the exception (30003) |