Common Object Migration Tasks

List Common Object Migration Tasks

get/commonobjectmigrationtasks

List all common object migration tasks.

Related SDK Methods:
Java

CommonObjectMigrationTasksApi.listCommonObjectMigrationTasks([param1, param2, ...])

Python

CommonObjectMigrationTasksApi.list_common_object_migration_tasks([param1, param2, ...])

JavaScript

CommonObjectMigrationTasksApi.listCommonObjectMigrationTasks([param1, param2, ...])

Request
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Responses
200

successful operation

400

The Workload Security link does not exist.

403

Not authorized to migrate common objects.

502

Failed to connect to Workload Security.

Request samples
import com.trendmicro.deepsecurity.ApiClient;
import com.trendmicro.deepsecurity.Configuration;
import com.trendmicro.deepsecurity.auth.ApiKeyAuth;
import com.trendmicro.deepsecurity.ApiException;
import com.trendmicro.deepsecurity.api.CommonObjectMigrationTasksApi;
import com.trendmicro.deepsecurity.model.CommonObjectMigrationTasks;


public class ListCommonObjectMigrationTasksExample {
	
	public static void main(String[] args) {
		// Setup
		ApiClient defaultClient = Configuration.getDefaultApiClient();
		defaultClient.setBasePath("YOUR HOST");

		// Authentication
		ApiKeyAuth DefaultAuthentication = (ApiKeyAuth) defaultClient.getAuthentication("DefaultAuthentication");
		DefaultAuthentication.setApiKey("YOUR API KEY");
		try {
			defaultClient.trustAllCertificates(false);
		} catch (Exception e) {
			System.err.println("An exception occurred when calling ApiClient.trustAllCertificates");
			e.printStackTrace();
		}
		
		// Initialization
		// Set Any Required Values
		CommonObjectMigrationTasksApi instance = new CommonObjectMigrationTasksApi();
		String apiVersion = "YOUR VERSION";
		try {
			// Please replace the parameter values with yours
			CommonObjectMigrationTasks result = instance.listCommonObjectMigrationTasks(apiVersion);
			System.out.println(result);
		} catch (ApiException e) {
			System.err.println("An exception occurred when calling CommonObjectMigrationTasksApi.listCommonObjectMigrationTasks");
			e.printStackTrace();
		}
	}
}

Response samples
application/json
{
  • "commonObjectMigrationTasks": [
    ]
}

Create a Common Object Migration Task

post/commonobjectmigrationtasks

Create a task to migrate common objects.

Related SDK Methods:
Java

CommonObjectMigrationTasksApi.createCommonObjectMigrationTask([param1, param2, ...])

Python

CommonObjectMigrationTasksApi.create_common_object_migration_task([param1, param2, ...])

JavaScript

CommonObjectMigrationTasksApi.createCommonObjectMigrationTask([param1, param2, ...])

Request
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Request Body schema: application/json

The task to migrate the common objects.

objectIDs
required
Array of integers <int32>

Target IDs to move from type.

type
required
string

Target type to move. Searchable as Choice.

Enum: "directory-lists" "file-extension-lists" "file-lists" "ip-lists" "mac-lists" "port-lists" "contexts" "stateful-configurations" "schedules"
Responses
200

successful operation

400

The Workload Security link does not exist.

403

Not authorized to migrate common objects.

409

A common object migration task already exists.

502

Failed to connect to Workload Security.

Request samples
application/json
{
  • "type": "directory-lists",
  • "objectIDs": [
    ]
}
Response samples
application/json
{
  • "type": "directory-lists",
  • "objectIDs": [
    ],
  • "taskGUID": "string",
  • "status": "requested",
  • "created": 0,
  • "lastUpdated": 0,
  • "commonObjectMappings": [
    ],
  • "errorCode": 0,
  • "commonObjectsUnableToMigrate": [
    ],
  • "ID": 0
}

Describe a Common Object Migration Task

get/commonobjectmigrationtasks/{commonObjectMigrationTaskID}

Describe a common object migration task.

Related SDK Methods:
Java

CommonObjectMigrationTasksApi.describeCommonObjectMigrationTask([param1, param2, ...])

Python

CommonObjectMigrationTasksApi.describe_common_object_migration_task([param1, param2, ...])

JavaScript

CommonObjectMigrationTasksApi.describeCommonObjectMigrationTask([param1, param2, ...])

Request
path Parameters
commonObjectMigrationTaskID
required
integer <int32> \d+

The ID number of the common object migration task to describe.

Example: 1
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Responses
200

successful operation

400

The Workload Security link does not exist.

403

Not authorized to migrate common objects.

404

The common object migration task does not exist.

502

Failed to connect to Workload Security.

Request samples
import com.trendmicro.deepsecurity.ApiClient;
import com.trendmicro.deepsecurity.Configuration;
import com.trendmicro.deepsecurity.auth.ApiKeyAuth;
import com.trendmicro.deepsecurity.ApiException;
import com.trendmicro.deepsecurity.api.CommonObjectMigrationTasksApi;
import com.trendmicro.deepsecurity.model.CommonObjectMigrationTask;


public class DescribeCommonObjectMigrationTaskExample {
	
	public static void main(String[] args) {
		// Setup
		ApiClient defaultClient = Configuration.getDefaultApiClient();
		defaultClient.setBasePath("YOUR HOST");

		// Authentication
		ApiKeyAuth DefaultAuthentication = (ApiKeyAuth) defaultClient.getAuthentication("DefaultAuthentication");
		DefaultAuthentication.setApiKey("YOUR API KEY");
		try {
			defaultClient.trustAllCertificates(false);
		} catch (Exception e) {
			System.err.println("An exception occurred when calling ApiClient.trustAllCertificates");
			e.printStackTrace();
		}
		
		// Initialization
		// Set Any Required Values
		CommonObjectMigrationTasksApi instance = new CommonObjectMigrationTasksApi();
		Integer commonObjectMigrationTaskID = 1;
		String apiVersion = "YOUR VERSION";
		try {
			// Please replace the parameter values with yours
			CommonObjectMigrationTask result = instance.describeCommonObjectMigrationTask(commonObjectMigrationTaskID, apiVersion);
			System.out.println(result);
		} catch (ApiException e) {
			System.err.println("An exception occurred when calling CommonObjectMigrationTasksApi.describeCommonObjectMigrationTask");
			e.printStackTrace();
		}
	}
}

Response samples
application/json
{
  • "type": "directory-lists",
  • "objectIDs": [
    ],
  • "taskGUID": "string",
  • "status": "requested",
  • "created": 0,
  • "lastUpdated": 0,
  • "commonObjectMappings": [
    ],
  • "errorCode": 0,
  • "commonObjectsUnableToMigrate": [
    ],
  • "ID": 0
}

Search Common Object Migration Tasks

post/commonobjectmigrationtasks/search

Search for common obeject migration tasks using optional filters.

Related SDK Methods:
Java

CommonObjectMigrationTasksApi.searchCommonObjectMigrationTasks([param1, param2, ...])

Python

CommonObjectMigrationTasksApi.search_common_object_migration_tasks([param1, param2, ...])

JavaScript

CommonObjectMigrationTasksApi.searchCommonObjectMigrationTasks([param1, param2, ...])

Request
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Request Body schema: application/json

A collection of options used to filter the search results.

maxItems
integer <int32>

Limits the number of objects returned. Default 5000.

Array of objects (searchCriteria)

Array of search critiera used to filter objects. Searching with multiple criteria returns results that satisfy all of the criteria. Searching with no criteria returns all objects.

sortByObjectID
boolean

If true, forces the response objects to be sorted by ID, overriding the default sort order. Default "false".

Responses
200

successful operation

400

The Workload Security link does not exist.

403

Not authorized to migrate common objects.

502

Failed to connect to Workload Security.

Request samples
application/json
{
  • "maxItems": 0,
  • "searchCriteria": [
    ],
  • "sortByObjectID": true
}
Response samples
application/json
{
  • "commonObjectMigrationTasks": [
    ]
}