This API can be used to change the case of one or more open activities of the same case. The target case can be a new case or an existing case.
For this API to execute successfully:
As part of completing this API request:
Method | URL | Description |
---|---|---|
PUT | /ws/v12/interaction/activity/{IDs}/changecase | Change case of one or more activities. {IDs}: a comma separated string of activity IDs that belong to the same case. |
Authentication is required. The client must be logged in to call this API. Each API request must contain X-egain-session request header returned by Login API.
All of the following are required:
The logged in user must have the following licenses:
Name | Description | Allowed values | Default value |
---|---|---|---|
X-egain-session | Session ID obtained from Login API response header | N/A | N/A |
Accept | Content type accepted by client. | application/xml or application/json | N/A |
Content-Type | Media type sent by the client | application/xml or application/json | N/A |
Accept-Language | Language locale accepted by client (used for locale specific fields in resource representation and in error responses) | Supported 'Accept-Language' header codes | default system language |
The request body is mandatory and can be in either XML or JSON format. The request body varies depending on whether the target case for activities is a new case or an existing case.
If the target case for activities is an existing case, the 'case' element in the request body must contain:
Name | Description |
---|---|
id | Must be an existing case ID in the application |
None
None, although the request body must be present with the case element.
Name | Description |
---|---|
case.dueDate | Must be a valid date, in the future. |
case.severity.value | Must be 'urgent', 'high', 'medium' or 'low'. |
case.subject | If not provided, the subject of the original case would be used as the subject of the case as well. Must not exceed 1024 characters. |
case.description | Must not exceed 1024 characters. |
case.solution | Must not exceed 1024 characters. |
case.customAttributes | Names of the custom attributes must exist in ECE application. If the attribute is an enumeration, the values sent must be one from the list of allowed values. For string type of custom attribute that is not configured as an enumeration, refer list of Allowed Characters For Custom Attributes. |
None
Name | Description | Possible values |
---|---|---|
X-egain-session | ID of the current user session | N/A |
Content-Type | Media type of response body | application/xml or application/json |
If a new case is created, URI of the newly created case is returned in the Location response header:
Name | Description | Possible values |
---|---|---|
Location | URI of new resource, in the format /{context-root}/ws/v12/interaction/case/{ID} | N/A |
The response body will be sent only in case of error. It can be in either XML or JSON format.
201 - Created
204 - No Content
400 - Bad Request
401 - Unauthorized
403 - Forbidden
404 - Not Found
406 - Not Acceptable
500 - Internal server error
Example 1 - Change case of an activity to a new case without optional attributes
Example 2 - Change case of an activity to an existing case
Example 3 - Change case of multiple activities to an existing case and relate the two cases
Example 4 - Change case of multiple activities to a new case by providing all case attributes