<< Click to Display Table of Contents >> Abort Cases |
Overview
This web method is used to abort (cancel) one or more existing cases in Bizagi (from an external application).
This method receives mainly: the creation number (for any number of open cases) and a reason for cancellation, to abort cases the same as it could be done from the Admin options at the Work Portal.
For further information about aborting cases from the Work Portal options, please refer to Bizagi Work Portal.
•For the abortCases method, the request and response XML's are of the native .NET XmlDocument type.
•For the abortCasesAsString method the same XML structure is handled, but this parameter is sent as a string type using CDATA.
If processes and Sub-Processes use the same radNumber (case ID), all cases with the same radNumber will be aborted. |
Input
Input Schema
The following shows a sample XML structure of information to send to Bizagi:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:element name="BizAgiWSParam">
<xs:complexType>
<xs:sequence>
<xs:element name="domain" type="xs:string" minOccurs="0"/>
<xs:element name="userName" type="xs:string" minOccurs="0"/>
<xs:element name="cases">
<xs:complexType>
<xs:sequence>
<xs:element name="case" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="radNumber" type="xs:unsignedShort"/>
<xs:element name="abortReason" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Input Parameters
•BizAgiWSParam: The mandatory root node.
•domain: Contains the domain name of the Bizagi user, which will be registered as the one who canceled the case.
•userName: Contains the name (used in Bizagi) of the user, which will be registered as the one who canceled the case.
•cases: This element is included to enclose several case elements depending on the number of cases being canceled.
•case: Here, the information of the case to be canceled, is included.
•radNumber: Refers to the case number. This parameter is mandatory when the idCase is not sent.
•idCase: Refers to the case identifier. Use this parameter when radNumber is not available.
•abortReason: The explanation for aborting the case.
Input Example
With the following example, two cases will be canceled by the domain\admon user.
We suggest you use How to start a process in Bizagi from other applications as a guideline to invoke this service.
AbortCases Method Input
<BizAgiWSParam>
<domain>domain</domain>
<userName>admon</userName>
<cases>
<case>
<idCase>8951</idCase>
<abortReason>Invalid case</abortReason>
</case>
<case>
<radNumber>9001</radNumber>
<abortReason>Test case</abortReason>
</case>
</cases>
</BizAgiWSParam>
AbortCasesAsString Method Input
<info>
<![CDATA[<BizAgiWSParam>
<domain>domain</domain>
<userName>admon</userName>
<cases>
<case>
<idCase>1</idCase>
<abortReason>Invalid case</abortReason>
</case>
<case>
<radNumber>9001</radNumber>
<abortReason>Test case</abortReason>
</case>
</cases>
</BizAgiWSParam>]]>
</info>
Output
Output Schema
The following shows a sample XML structure of information returned by Bizagi:
<?xml version="1.0" encoding="utf-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="unqualified" attributeFormDefault="qualified">
<xs:element name="Processes">
<xs:complexType>
<xs:sequence>
<xs:element name="Process" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="ProcessId" type="xs:integer"/>
<xs:element name="ProcessRadNumber" type="xs:string"/>
<xs:element name="ProcessCreationDate" type="xs:dateTime"/>
<xs:element name="ProcessSolutionDate" type="xs:dateTime"/>
<xs:element name="ProcessWorkflowClass">
<xs:complexType>
<xs:sequence>
<xs:element name="workflowClassId" type="xs:integer"/>
<xs:element name="workflowClassName" type="xs:string"/>
<xs:element name="workflowClassDisplayName" type="xs:string"/>
<xs:element name="workflowClassDescription" type="xs:string"/>
<xs:element name="workflowClassHelpText" type="xs:string"/>
<xs:element name="workflowClassHelpURL" type="xs:string"/>
<xs:element name="workflowClassDisplayOrder" type="xs:unsignedByte"/>
<xs:element name="workflowClassCreationDate" type="xs:dateTime"/>
<xs:element name="workflowClassGlobalForm" type="xs:integer"/>
<xs:element name="workflowClassAllocationPrinciple" type="xs:string"/>
<xs:element name="workflowClassProcessType" type="xs:string"/>
<xs:element name="workflowClassDisplay" type="xs:boolean"/>
<xs:element name="workflowClassUseParentRadicationNumber" type="xs:boolean"/>
<xs:element name="workflowClassSupportsScopes" type="xs:boolean"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ProcessError">
<xs:complexType>
<xs:sequence>
<xs:element name="errorCode" type="xs:integer"/>
<xs:element name="errorMessage" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Output Parameters
•Processes: Root node.
•Process: This element is included for each case that is to be canceled.
•ProcessId: Identification number of the case (idCase).
•ProcessRadNumber: Alphanumeric value corresponding to the creation number of the case.
•ProcessCreationDate: Case creation date.
•ProcessSolutionDate: Case solution date.
•ProcessWorkflowClass: The information in this node is all about the Process (Process metadata) not about the particular case.
•workflowClassId: Identification number (or key) of the Process.
•workflowClassName: Name of the Process.
•workflowClassDisplayName: Display name of the Process.
•workflowClassDescription: Process description.
•workflowClassHelpText: Process help text.
•workflowClassHelpURL: Help URL for the Process.
•workflowClassDisplayOrder: The order in which the Process will be viewed in the web application.
•workflowClassCreationDate: Creation date of the Process.
•workflowClassGlobalForm: Identification number of the Process’s global form (zero if it is not configured).
•workflowClassAllocationPrinciple: Reserved for future use.
•workflowClassProcessType: Process type.
•workflowClassDisplay: Indicates whether the Process is visible or not.
•workflowClassUseParentRadicationNumber: Indicates if a case of this Process uses its own creation number or the same number as the parent Process (if it is a Sub-Process).
•workflowClassSupportScopes: Indicates if the Process supports long-term transactions in Bizagi (Scopes); which is an efficient method of data persistence.
•ProcessError: If the procedure of canceling a case is not successful, this element will contain information of the error.
•errorCode: Code of the error that occurred, otherwise it will be empty.
•errorMessage: Message of the error that occurred, otherwise it will be empty.
Output Example
In the following example, we illustrate a returned XML-structured response from Bizagi's SOA layer, in which we can see:
AbortCases Method Output
•For case number 8951, the abort case operation was executed successfully.
•For case 9001, which was previously aborted, the returned message states that the case is no longer available to be aborted.
AbortCasesAsString Method Output
•For case number 1, the abort case operation was executed successfully.
•For case 9001, which doesn't exist, the returned message states that the case does not exist.
Last Updated 1/6/2022 5:13:30 PM