Base URL
Workflow action endpoints are accessed through:
Where {baseUrl} is the RISKSHEET application server URL.
Authentication
All workflow API requests require valid Polarion user authentication via HTTP Basic Auth or session cookies.
Get Available Actions
Retrrieves the list of workflow actions available for a specific work item based on its current state.
GET {baseUrl}/risksheet/api/getWorkflowActions
Request Parameters
Parameter Type Required Description projectIdquery string Yes Polarion project identifier workItemIdquery string Yes Work item identifier (e.g., ‘RISK-001’)
Query Examples
GET /risksheet/api/getWorkflowActions?projectId=PROJ&workItemId=RISK-001
GET /risksheet/api/getWorkflowActions?projectId=PROJ&workItemId=REQ-042
{
"actions" : [
{
"id" : "review" ,
"name" : "Send for Review" ,
"description" : "Submit item for review approval"
},
{
"id" : "approve" ,
"name" : "Approve" ,
"description" : "Approve reviewed item"
},
{
"id" : "reject" ,
"name" : "Reject" ,
"description" : "Return item for revision"
}
]
}
Response Properties
Property Type Description actionsarray List of available workflow actions actions[].idstring Unique action identifier for use in changeStatus requests actions[].namestring Display name of the workflow action actions[].descriptionstring Human-readable description of what the action does
Execute Workflow Action
Executes a workflow action to transition a work item to a new status.
POST {baseUrl}/risksheet/api/changeWorkItemStatus
Request Body
{
"projectId" : "PROJ" ,
"workItemId" : "RISK-001" ,
"actionId" : "review"
}
Property Type Required Description projectIdstring Yes Polarion project identifier workItemIdstring Yes Work item identifier to transition actionIdstring Yes Action ID from getWorkflowActions response
Success Response:
{
"status" : "success" ,
"message" : "Workflow action executed successfully" ,
"newStatus" : "In Review"
}
Error Response:
{
"status" : "error" ,
"message" : "Cannot review item: required field 'Risk Level' is empty" ,
"errorCode" : "MISSING_REQUIRED_FIELD"
}
Response Properties
Property Type Description statusstring success or errormessagestring Result message or error description newStatusstring New status value after successful transition errorCodestring Error code for programmatic handling (only in error responses)
Change Document Status
Executes a workflow action on a RISKSHEET document (Polarion module).
POST {baseUrl}/risksheet/api/changeDocumentStatus
Request Body
{
"projectId" : "PROJ" ,
"documentLocation" : "space/path/DocumentName" ,
"actionId" : "approve"
}
Property Type Required Description projectIdstring Yes Polarion project identifier documentLocationstring Yes Document path (e.g., ‘MySpace/RiskAnalysis’) actionIdstring Yes Workflow action ID to execute
Same as work item status change:
{
"status" : "success" ,
"message" : "Document status changed successfully" ,
"newStatus" : "Approved"
}
Common Error Codes
Error Code HTTP Status Description Resolution ITEM_NOT_FOUND404 Work item or document does not exist Verify projectId and workItemId/documentLocation INVALID_ACTION400 Action ID is not valid for this item Call getWorkflowActions to get valid actions ACCESS_DENIED403 User lacks permissions for this action Check user roles and permissions in Polarion MISSING_REQUIRED_FIELD400 Required field is empty or invalid Complete all required fields before transitioning DOCUMENT_NOT_ACCESSIBLE404 Document was deleted or access denied Verify document exists and is accessible TRANSACTION_FAILED500 Database transaction error occurred Retry request; contact administrator if persists
Status Transition Flow
User selects workflow action
|
v
Query getWorkflowActions
?projectId=PROJ&workItemId=ITEM
|
v
Display available actions
- Review
- Approve
- Reject
|
v
User clicks action
|
v
POST changeWorkItemStatus
projectId: PROJ
workItemId: ITEM
actionId: selected_action
|
v
Validate required fields
|
+----+----+
| |
v v
Success Error
(New) (Show message)
Status
| |
+----+----+
|
v
Refresh UI
Required Field Validation
Before executing a workflow action, Nextedy RISKSHEET validates that all required fields for that status are populated. If validation fails:
The action is not executed
Error response indicates which fields are missing
User must complete required fields before retrying
Workflow actions are configured in Polarion’s workflow definition. The RISKSHEET API exposes whatever actions are available in the underlying Polarion workflow. To modify available actions or required fields, configure the workflow in Polarion’s workflow manager.
Suggestions API
The API can optionally provide suggested workflow actions based on item state:
GET /risksheet/api/suggestedActions?projectId=PROJ&workItemId=ITEM
This returns a filtered list of the most relevant actions for the current state, ordered by likelihood of use.
Example Response:
{
"suggested" : [
{
"id" : "review" ,
"name" : "Send for Review" ,
"score" : 0.95
}
]
}
Batch Operations
To execute the same action on multiple items:
Query getWorkflowActions once to verify action is valid
Execute changeWorkItemStatus for each item individually
Collect results and display summary
Batch endpoint is not available; operations must be sequential.
Transaction Management
All workflow operations are atomic — either the entire action succeeds or it fails and is rolled back. Partial updates never occur.
Workflow operations on locked or checked-out documents may fail. Ensure the document is not locked by another user before attempting status changes.
Related Pages
Source Code
StatusChangeCommand.ts
WorkflowActionServlet.java
CommandFactory.ts
AppConfig.ts
AppConfigParser.ts