Data Management API
The Data Management API allows managing database and S3 data purging, as well as data achival and restoration operations.
Authentication
For Data Management API, form-based authentication is required. For details, read about the WorkFusion REST API security.
Two permissions are essential for working with Data Management API:
Configure Database and S3 Data Management: allows viewing, executing, creating, updating, and deleting data management configurations to purge S3 and database data.
Configure Data Archival and Restoration: allows viewing, executing, creating, updating, and deleting data management configurations for archiving and restoring process data.
To enable the permissions, follow the instructions in the Manage Control Tower roles and permissions guide.
All URLs are to begin with the following pattern:
https://control.tower.host/api/v1
Database data management
GET /data-managements
Returns a list of all available database data management configurations. Each returned configuration is an object comprising the following data:
uuid: unique identifier of the data management configurationactive: enabled or disabled statecreationDate: timestamp to indicate when the configuration was createdexecutionId: identifier of the last data management configuration run (if any)customSql: only for the ds schema, the name of the underlying custom SQL scriptstoredProcedureName: for schemas other than ds, the name of the underlying stored procedureparameters: parameters for the underlying stored procedure (if any)submitProcedureDate: timestamp to indicate when the underlying stored procedure (if any) was submittedlastExecutionPointandnextExecutionPoint: timestamps for the last and next runs of scheduled data management configurationsname: data management configuration namedescription: additional details (if any) to describe the cleanup operationcronExpression: execution schedule (if any)status: data management configuration status
Query parameters
page: requested page number.size: page size.sort: sorting criterion. Available values :NAME,DESCRIPTION,ACTIVE,LAST_EXECUTION_POINT,NEXT_EXECUTION_POINT,CREATION_DATE.sortDirection: sorting order. Available values:ASC(ascending order),DESC(descending order).
Successful response example
[
{
"active": true,
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "QUEUED",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"uuid": "string"
}
]
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/{uuid}
Returns information about a particular database data management configuration, including:
active: enabled or disabled statecreationDate: timestamp to indicate when the configuration was createdsubmitProcedureDate: timestamp to indicate when the underlying stored procedure (if any) was submittedexecutionId: identifier of the last data management configuration run (if any)name: data management configuration namedescription: additional details (if any) to describe the cleanup operationcustomSql: only for ds schemas, the name of the underlying custom SQL scriptstoredProcedureName: for schemas other than ds, the name of the underlying stored procedureparameters: parameters for the underlying stored procedure (if any)lastExecutionPointandnextExecutionPoint: timestamps for the last and next runs of scheduled data management configurationscronExpression: execution schedule (if any)status: data management configuration status
Path parameter
uuid: the UUID for the database data management configuration you want to get information about. Required.
Successful response example
{
"active": true,
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "QUEUED",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/procedures
Returns a list of available stored procedures to create database data management configurations for schemas other than ds.
No parameters are required for the API method.
Successful response example
[
"string"
]
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/procedures/{sp_name}
Returns the parameters for a specific stored procedure.
Path parameter
sp_name: name of the stored procedure for which you want to get parameters. Required.
Successful response example
{
"parameters": [
"string"
]
}
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/{uuid}/events
Returns all events for a particular database data management configuration. Each event object includes the following information:
eventDate: date when the event occurredlevel: log leveldescription: event details
Path parameter
uuid: UUID of the requested database data management configuration. Required.
Query parameter
level: log level. Optional.Available values:
DEBUG,INFO,WARNING,ERROR. The default value isINFO.
Successful response example
[
{
"configurationUuid": "string",
"description": "string",
"eventDate": "2021-01-26T09:49:34.235Z",
"executionId": 0,
"level": "INFO"
}
]
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/{data_management_uuid}/events/{execution_id}
Returns events for a particular execution of a database data management configuration. Each returned event object comprises the following information:
eventDate: date when the event occurredlevel: log leveldescription: event details
Path parameters
data_management_uuid: UUID of the requested database data management configuration. Required.execution_id: ID of the data management configuration run for which event information is requested. Required.
Query parameter
level: log level. Optional. Available values:DEBUG,INFO,WARNING,ERROR. The default value isINFO.
Successful response example
[
{
"configurationUuid": "string",
"description": "string",
"eventDate": "2021-01-26T09:20:25.552Z",
"executionId": 0,
"level": "INFO"
}
]
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
GET /data-managements/{uuid}/statuses/{executionId}
Returns the current statuses for a particular execution of a specific database data management configuration. The following statuses are possible:
- QUEUED: the execution is in the queue at the execution engine.
- PROCESSING: the execution is in progress.
- FAILED: the execution failed on the database side.
- DONE: the execution was completed successfully.
Path parameters
uuid: UUID of the requested database data management configuration. Required.executionId: ID of the database data management execution for which status information is requested. Required.
Successful response example
[
{
"configUuid": "string",
"executionId": 0,
"status": "QUEUED",
"submitDate": "2021-01-26T09:43:43.271Z"
}
]
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
POST /data-managements
Creates a database data management configuration based on a stored procedure or custom SQL as specified in the request body.
Once the configuration is created, it is submitted to a queue under a unique ID (uuid). From the queue, you can launch it using POST /data-managements/{data_management_uuid}/start.
A successful response returns the following information about the configuration:
uuid: unique identifier.creationDate: creation timestamp.status: current status. For a new database data management configuration, the status isQUEUED.
For scheduled database data management configurations, a successful response body can also include a timestamp for the next execution (nextExecutionPoint).
Request body
For the endpoint, the request body is a required DataManagement object to be saved to the Control Tower (CT) database. The object comprises the following parameters:
active: defines whether the created configuration is enabled or disabled. Configurations must be enabled to be executed. So, set the value totrue.cronExpression: the schedule for running the configuration. With the parameter specified, the configuration is run according to the schedule once you submit POST /data-managements/{data_management_uuid}/start. Set tonullto create an unscheduled configuration.storedProcedureName: name of the stored procedure for data cleanup. Used for purging any database schema other than the ds one. For the ds schema, set it tonulland specify thecustomSqlparameter instead.customSql: custom SQL code for cleaning up Data Stores. Set it tonulland specify thestoredProcedureNameparameter instead to create a configuration for purging schemas other than thedsone.description: additional details to describe the created data management configuration.name: any random name defined for the configuration.parameters: includes stored procedure parameters if the created configuration is based on one—that meansstoredProcedureNameis specified. Otherwise, set tonull.
Request body example
{
"active": true,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string"
}
Successful response example
{
"active": true,
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "QUEUED",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
POST /data-managements/{data_management_uuid}/start
Launches a database cleanup from the specified configuration without a schedule. Once the method is called, the stored procedure or custom SQL underlying the configuration is executed, and an execution ID is returned.
Path parameter
data_management_uuid: UUID of the database data management configuration to be executed. Required.
Request body
The request body is a required parameter array. It specifies the names and values of the parameters for the underlying stored procedure if the data management configuration is to be executed for a schema other than the ds one. For ds schema configurations based on custom SQLs, set the array elements to null.
Request body example
[
{
"name": "string",
"value": "string"
}
]
Successful response example
{
"executionId": 0
}
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
PUT /data-managements/{uuid}
Updates an existing database data management configuration.
A successful response returns the following information about the configuration:
uuid: unique identifierexecutionId: last execution IDcreationDate: creation timestampstatus: current status
For scheduled database data management configurations, a successful response body can also include timestamps for the last (lastExecutionPoint) and next (nextExecutionPoint) executions of the configuration.
Path parameter
uuid: UUID of the database data management configuration to be updated. Required.
Request body
A required DataManagement object to be updated on the CT side, comprising the same elements as described for POST /data-managements.
Request body example
{
"active": true,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string"
}
Successful response example
{
"active": true,
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "QUEUED",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"message": "string"
}
],
"message": "string"
}
DELETE /data-managements/{uuid}
Deletes an existing database data management configuration.
Path parameter
uuid: the unique identifier of the database data management configuration to be deleted. Required.
Database data archive management
POST /data-archive
Creates a database data archive management configuration.
Request body
A required DataManagement object to be saved to the CT database, comprising the following parameters:
active: a Booleantrue/falsevalue to enable or disable the posted archive configurationarchiveFile: the data archive filebucket*: the Ceph bucket where the archived data is to be storedcronExpression*: cron expression for the scheduled execution of the configurationcustomSql: only for the ds schema, the name of the underlying custom SQL scriptdescription: additional details (if any) to describe the archival configurationname: the configuration nameparameters: parameters of the underlying stored procedure (if a stored procedure is used)storedProcedureName*: for schemas other than ds, the name of the underlying stored procedure
The parameters marked with an asterisk (*) are required.
Request body example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string",
"timestamp": "2025-06-26T10:29:30.954Z"
}
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T10:29:30.974Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
POST data-archive/{uuid}/toggle
Enables the database data archive management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data archive management configuration to be enabled or disabled. Required.
Request body
When the active request body parameter is set to true, the database data archive management configuration specified in the path parameter is enabled. Otherwise, it is disabled.
Request body example
{
"active": true
}
Response
If the request is successful, the Successful operation response is returned. Otherwise, you get a failed response similar to this one:
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
POST /data-archive/{uuid}/start
Starts the database data archive management configuration with the specified UUID without Scheduler.
Path parameter
uuid: UUID of the database data archive management configuration to be launched. Required.
Request body
The request body is a required execution parameter array with a structure similar to the one shown below.
Request body example
[
{
"name": "string",
"value": "string"
}
]
Successful response example
{
"executionId": 0
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
GET /data-archive/{uuid}
Retrieves the information about the database data archive management configuration with the specified UUID, including:
active: whether the configuration is in the enabled or disabled state.archiveFile: the data archive file data.bucket: the Ceph bucket where the archived data is stored.creationDate: timestamp to indicate when the configuration was created.cronExpression: cron expression set for the configuration.customSql: only for ds schemas, the name of the underlying custom SQL script.dataManagementType: the type of data managed by the configuration.description: additional details (if any) to describe the cleanup operation.executionId: identifier of the last configuration run (if any).name: configuration name.lastExecutionPointandnextExecutionPoint: timestamps for the last and next runs of scheduled configurations.parameters: parameters for the underlying stored procedure (if any).storedProcedureName: for schemas other than ds, the name of the underlying stored procedure.status: status of the configuration.QUEUED: the execution is in the queue at the execution engine.PROCESSING: the execution is in progress.FAILED: the execution failed on the database side.DONE: the execution was completed successfully.
parameters: stored procedure parameters.submitProcedureDate: timestamp to indicate when the underlying stored procedure (if any) was submitted.uuid: configuration UUID.
Path parameter
uuid: UUID of the database data archive management configuration for which the information is to be retrieved. Required.
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T10:52:09.041Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
GET /data-archive/procedures
Returns a list of available stored procedures to create database data archival management configurations for schemas other than ds. No parameters are required for the API method.
Successful response example
[
"string"
]
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
GET /data-archive/procedures/{sp_name}
Retrieves the parameters of a specific stored procedure.
Path parameter
sp_name: stored procedure name. Required.
Successful response example
{
"parameters": [
"string"
]
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
PUT /data-archive/{uuid}
Updates the database data archive management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data archive management configuration to be updated. Required.
Request body
A required DataArchiveDataManagementConfigurationDto object to be updated on the CT database side, comprising the same parameters as described for the POST /data-archive endpoint.
Request body example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string",
"timestamp": "2025-06-26T11:07:32.508Z"
}
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T11:07:38.886Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
DELETE /data-archive/{uuid}
Deletes the database data archive management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data archive management configuration to be deleted. Required.
Response
If the request is successful, the Successful operation response is returned. Otherwise, you get a failed response similar to this one:
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
Data restoration management
POST /data-restoration
Creates a new database data restoration management configuration.
Request body
A required DataArchiveDataManagementConfigurationDto object to be saved to the CT database, comprising the following parameters:
active: a Booleantrue/falsevalue to enable or disable the posted archive configurationarchiveFile*: the data archive file to be restoredbucket: the Ceph bucket where the archived data is storedcronExpression*: cron expression for the scheduled execution of the configurationcustomSql: only for the ds schema, the name of the underlying custom SQL scriptdescription: additional details (if any) to describe the restoration configurationname*: the configuration nameparameters: parameters of the stored procedure underlying the configuration (if a stored procedure is used)storedProcedureName: for schemas other than ds, the name of the underlying stored procedure
The parameters marked with an asterisk (*) are required.
Request body example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string",
"timestamp": "2025-06-26T12:10:29.136Z"
}
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T12:10:29.169Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
POST /data-restoration/{uuid}/toggle
Enables or disables the database data restoration management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data restoration management configuration to be enabled or disabled. Required.
Request body
When the active request body parameter is set to true, the database data restoration management configuration specified in the path parameter is enabled. Otherwise, it is disabled.
Request body example
{
"active": true
}
Response
If the request is successful, the Successful operation response is returned. Otherwise, you get a failed response similar to this one:
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
POST /data-restoration/{uuid}/start
Starts data restoration from the configuration with the specified UUID without Scheduler.
Path parameter
uuid: UUID of the database data restoration management configuration to be started. Required.
Successful response example
{
"executionId": 0
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
GET /data-restoration/{uuid}
Returns information about the database data restoration management configuration with the specified UUID, including:
active: whether the configuration is in the enabled or disabled state.archiveFile: the data archive file data.bucket: the Ceph bucket where the archived data is stored.creationDate: timestamp to indicate when the configuration was created.cronExpression: cron expression set for the configuration.customSql: only for ds schemas, the name of the underlying custom SQL script.dataManagementType: the type of data managed by the configuration.description: additional details (if any) to describe the configuration.executionId: identifier of the last configuration run (if any).name: configuration name.lastExecutionPointandnextExecutionPoint: timestamps for the last and next runs of scheduled configurations.parameters: parameters for the underlying stored procedure (if one is used).storedProcedureName: for schemas other than ds, the name of the underlying stored procedure.status: status of the configuration.QUEUED: the execution is in the queue at the execution engine.PROCESSING: the execution is in progress.FAILED: the execution failed on the database side.DONE: the execution was completed successfully.
submitProcedureDate: timestamp to indicate when the underlying stored procedure (if any) was submitted.uuid: the configuration UUID.
Path parameter
uuid: UUID of the database data restoration management configuration for which the information is to be retrieved. Required.
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T13:16:02.702Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
GET /data-restoration/archival-files
Restores all files archived by database data archive management configurations. The API endpoint requires no parameters.
Successful response example
{
"parameters": [
"string"
]
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
PUT /data-restoration/{uuid}
Updates the database data restoration management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data restoration management configuration to be updated. Required.
Request body
A required DataArchiveDataManagementConfigurationDto object to be updated on the CT database side, comprising the same parameters as described for the POST /data-restoration endpoint.
Request body example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"cronExpression": "string",
"customSql": "string",
"description": "string",
"name": "string",
"parameters": [
{
"name": "string",
"value": "string"
}
],
"storedProcedureName": "string",
"timestamp": "2025-06-26T13:26:54.021Z"
}
Successful response example
{
"active": true,
"archiveFile": "string",
"bucket": "string",
"creationDate": 0,
"cronExpression": "string",
"customSql": "string",
"dataManagementType": "DATABASE",
"description": "string",
"executionId": 0,
"lastExecutionPoint": 0,
"name": "string",
"nextExecutionPoint": 0,
"parameters": [
{
"name": "string",
"value": "string"
}
],
"status": "string",
"storedProcedureName": "string",
"submitProcedureDate": 0,
"timestamp": "2025-06-26T13:26:54.053Z",
"uuid": "string"
}
Failed response example
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}
DELETE /data-restoration/{uuid}
Deletes the database data restoration management configuration with the specified UUID.
Path parameter
uuid: UUID of the database data restoration management configuration to be deleted. Required.
Response
If the request is successful, the Successful operation response is returned. Otherwise, you get a failed response similar to this one:
{
"code": "string",
"errors": [
{
"field": "string",
"message": "string"
}
],
"message": "string"
}