Contents
Recording Non-Deletion API
ENTIRE PAGE IS NEW
Source: https://intranet.genesys.com/display/RP/Summary+of+Label+APIs+to+be+documented
Pre-requisite
Set Elasticsearch schema v2 in Interaction Recording Web Services, to enable it to use labels and non-deletion features. For existing deployments, follow the migration steps here: Migrating an Existing Elasticsearch Deployment to Schema V2). New deployments after GIR version 8.5.2xx.xx (TBD) will have Elasticsearch schema v2 enabled by default.
Permissions
See: Configuring Permissions for Recording Non-Deletion
Overview
You can tag recordings for non-deletion: exclude voice and associated screen recordings from Media Life Cycle Management purge tasks. Tagged SpeechMiner recordings are also protected from deletion. To enable deletion, remove the non-deletion tag from the recordings.
Note: For voice recordings which have associated screen recordings, tagging or untagging the voice recording for non-deletion also tags/untags associated screen recordings.
The following API operations are accessible at the base path /api/v2
For example, http://localhost:8080/api/v2/recordings<recid>
Apply Non-Deletion to a Recording
Use this operation to prevent a voice recording from being deleted.
| Method | Path | Required Roles | Required Recording Permissions |
| POST | /recordings/<recid> | CC Admin | N/A |
|
RECORDING_PERMISSION_APPLY_NON_DELETE |
| Payload | ||||||
| Attribute | JSON Data Type | Mandatory | Possible Values | Default Value | Description | Notes |
| operationName | String | yes | applyNonDelete | N/A | Mark a recording for non-deletion. | If it is for a voice recording, all the associated screen recordings at the time of the operation will also be updated. |
Mark a voice recording for non-deletion
# Mark voice recording d15a8bee-a720-4def-9674-0767e6fde196 and its screen recordings(if any) for non-deletion
POST /recordings/d15a8bee-a720-4def-9674-0767e6fde196
{
"operationName" : "applyNonDelete"
}
Response
| HTTP Status | ||
| Status Codes | Situations | Notes |
| 200 OK | The recording(s) has been marked for non-deletion successfully. | |
| 400 BAD REQUEST | The operationName does not match any of the possible values described above. | |
| 403 FORBIDDEN |
|
|
| 404 NOT FOUND | The recording for which to mark non-deletion cannot be found; | |
| 500 INTERNAL SERVER ERROR | If an internal error occurs. | |
| Payload | ||||||
| Attribute | JSON Data Type | Mandatory | Possible Values | Default Value | Situations | Notes |
|---|---|---|---|---|---|---|
| statusCode | Integer | yes | ||||
| 0 (Ok) | N/A | The recording has been marked for non-deletion. | ||||
| 2 (InvalidRequestParameter) | The operationName does not match the above-mentioned operations | |||||
| 3 (OperationForbidden) | The requesting user does not have the recording permissions required. | |||||
| 4 (InternalError) | If internal error occurs. | |||||
| 5 (Unauthorized) | The requesting user does not have the roles required. | |||||
| 6 (ResourceNotFound) | The recording for which to mark non-deletion cannot be found. | |||||
| statusMessage | String | no |
|
N/A | The statusMessage will provide more information about a failure if statusCode is not 0. | |
Response when one recording is requested
200 OK
{
"statusCode" : 0
}
400 BAD REQUEST
{
"statusCode" : 2,
"statusMessage" : "Parameter 'operationName' is invalid: The specified value is not within valid range"
}
403 FORBIDDEN
{
"statusCode" : 5,
"statusMessage" : "Insufficient user roles."
}
403 FORBIDDEN
{
"statusCode" : 3,
"statusMessage" : "Insufficient recording permissions."
}
404 NOT FOUND
{
"statusCode" : 6,
"statusMessage" : "Requested recording [f2197c79-3304-4427-9e73-48a5a8903484] cannot be found."
}
500 INTERNAL SERVER ERROR
{
"statusCode" : 4,
"statusMessage" : "Internal server error - please contact administrator."
}
Unmark a Single Recording From Non-Deletion
| Method | Path | Required Roles | Required Recording Permissions |
| POST | /recordings/<recid> | CC Admin | N/A |
|
RECORDING_PERMISSION_UNAPPLY_NON_DELETE |
| Payload | ||||||
| Attributes | JSON Data Type | Mandatory | Possible Values | Default Value | Description | Notes |
| operationName | String | yes | unapplyNonDelete | N/A | Unmark a recording for non-deletion |
|
Response
| HTTP Status | ||
| Status Codes | Situations | Notes |
|---|---|---|
| 200 OK | the recording(s) has been unmarked for non-deletion successfully. | |
| 400 BAD REQUEST | the operationName does not match any of the possible values described above. | |
| 403 FORBIDDEN |
|
|
| 404 NOT FOUND | the recording for which to unmark non-deletion cannot be found. | |
| 500 INTERNAL SERVER ERROR | An internal error occurs. |
| Payload | ||||||
| Attribute | JSON Data Type | Mandatory | Possible Values | Default Value | Situations | Notes |
|---|---|---|---|---|---|---|
| statusCode | Integer | yes | 0 (Ok) | N/A | the recording has been unmarked for non-deletion. | |
| 2 (InvalidRequestParameter) | The operationName does not match any of the possible values described above. | |||||
| 3 (OperationForbidden) | The requesting user does not have the recording permissions required. | |||||
| 4 (InternalError) | If internal error occurs. | |||||
| 5 (Unauthorized) | The requesting user does not have the roles required. | |||||
| 6 (ResourceNotFound) | The recording for which to unmark non-deletion cannot be found. | |||||
| statusMessage | String | no |
|
N/A | The statusMessage will provide more information about a failure if statusCode is not 0. | |
Unmark a Voice Recording for Non-deletion
Use this operation to remove a voice recording's protection from deletion.
# Unmark voice recording d15a8bee-a720-4def-9674-0767e6fde196 and its screen recordings(if any) for non-deletion
POST /recordings/d15a8bee-a720-4def-9674-0767e6fde196
{
"operationName" : "unapplyNonDelete"
}Response
| HTTP Status | ||
| Status Codes | Situations | Notes |
| 200 OK | the recording(s) has been unmarked for non-deletion
successfully. |
|
| 400 BAD REQUEST | the operationName does not match any of the possible values
described above. |
|
| 403 FORBIDDEN |
|
|
| 404 NOT FOUND | the recording for which to unmark non-deletion cannot be
found. |
|
| 500 INTERNAL SERVER ERROR | An internal error occurs. | |
| Payload | ||||||
| Attributes | JSON Data Type | Mandatory | Possible Values | Default Value | Situations | Notes |
| statusCode | Integer | yes | 0 (Ok) | N/A | The recording has been unmarked for non-deletion. | |
| 2 (InvalidRequestParameter) | The operationName does not match any of the possible values described above. | |||||
| 3 (OperationForbidden) | The requesting user does not have the recording permissions required. | |||||
| 4 (InternalError) | An internal error occurs. | |||||
| 5 (Unauthorized) | The requesting user does not have the roles required. | |||||
| 6 (ResourceNotFound) | The recording for which to unmark non-deletion cannot be found. | |||||
| statusMessage | String | no |
|
N/A | The statusMessage will provide more information about a failure if statusCode is not 0. | |
Response when one recording is requested
200 OK
{
"statusCode" : 0
}
400 BAD REQUEST
{
"statusCode" : 2,
"statusMessage" : "Parameter 'operationName' is invalid: The specified value is not within valid range"
}
403 FORBIDDEN
{
"statusCode" : 5,
"statusMessage" : "Insufficient user roles."
}
403 FORBIDDEN
{
"statusCode" : 3,
"statusMessage" : "Insufficient recording permissions."
}
404 NOT FOUND
{
"statusCode" : 6,
"statusMessage" : "Requested recording [f2197c79-3304-4427-9e73-48a5a8903484] cannot be found."
}
500 INTERNAL SERVER ERROR
{
"statusCode" : 4,
"statusMessage" : "Internal server error - please contact administrator."
}
| Payload | ||||||
| Attributes | JSON Data Type | Mandatory | Possible Values | Default Value | Situations | Notes |
| statusCode | Integer | yes | 0 | N/A | label definition was updated | |
| 1 (RequiredParameterMissing) | The required payload attributes are missing | |||||
| 2 (InvalidRequestParameter) | The constraints of payload attributes are not met | |||||
| 3 (OperationForbidden) | The requesting user does not have the permissions required or is attempting to update with different name | |||||
| 5 (Unauthorized) | The requesting user does not have the roles required | |||||
| 6 (ResourceNotFound) | The specified label definition cannot be found | |||||
| statusMessage | String | no |
|
N/A | The statusMessage will provide more information about a
failure if statusCode is not 0. | |
| labelDefinition | JSON object | yes |
|
N/A | ||
