Suspending, Resuming, or Terminating a BPM Instance
Function
This API is used to suspend, resume, or terminate a BPM instance. After a BPM instance is suspended, it will not be displayed in the to-do task list, the SLA timer stops, and no follow-up reminder will be sent. After a BPM instance is resumed, the system proceeds with subsequent operations. After a BPM instance is terminated, the BPM instance is forcibly stopped and you can view the BPM instance only in the historical task list.
URI
PUT Huawei Cloud Astro Zero domain name/u-route/baas/bp/v2.0/runtime/instances/{instance_id}
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
instance_id |
Yes |
String |
Explanation ID of a BPM instance, which can be obtained by invoking the API for Querying a BPM Instance (id in the response message). Constraints None Value None Default value None |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
action |
Yes |
String |
Explanation Name of the action to be taken for the BPM instance. Constraints None Value
Default value None |
Response Parameters
Parameter |
Type |
Description |
---|---|---|
resCode |
String |
Explanation Return code. Value If the request is successful, 0 is returned. For details about other error codes, see Error Codes. |
resMsg |
String |
Explanation Message returned. Value If the request is successful, "Success" is returned. In other cases, an error message is returned. |
result |
Object |
Explanation If the request is successful, the running information about the BPM instance after being started will be returned. |
Example Request
PUT https://Huawei Cloud Astro Zero domain name/u-route/baas/bp/v2.0/runtime/instances/002N000000Q3QW4IMAOO { "action": "suspend" }
Example Response
In the response, the value of suspended of the BPM instance is true.
{ "resCode":"0", "resMsg":"Success", "result":{ "name":"SimpleBP", "version":"1.0.1", "id":"002N000000Q3QW4IMAOO", "processDefID":"001L000000Peuw1Q318a", "interviewLabel":"SimpleBP 2019-05-10 15:14:09", "nextElem":"", "isTest":true, "state":"New", "bpStatus":"New", "urgency":0, "taskOutcome":"", "businessKey":"002N000000Q3QW4IMAOO", "startTime":"2019-05-10 15:14:09", "endTime":"", "Ext1":"", "Ext2":"", "Ext3":"", "Ext4":"", "Ext5":"", "Ext6":"", "Ext7":0, "Ext8":0, "suspended":true, "isClosed":false } }
Status Code
See Status Codes.
Error Code
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot