Directory Lists

List Directory Lists

get/directorylists

Lists all directory lists.

Related SDK Methods:
Java

DirectoryListsApi.listDirectoryLists([param1, param2, ...])

Python

DirectoryListsApi.list_directory_lists([param1, param2, ...])

JavaScript

DirectoryListsApi.listDirectoryLists([param1, param2, ...])

Request
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Responses
200

successful operation

403

Not authorized to view directory lists.

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.DirectoryListsApi;
import com.trendmicro.deepsecurity.model.DirectoryLists;


public class ListDirectoryListsExample {
	
	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
		DirectoryListsApi instance = new DirectoryListsApi();
		String apiVersion = "YOUR VERSION";
		try {
			// Please replace the parameter values with yours
			DirectoryLists result = instance.listDirectoryLists(apiVersion);
			System.out.println(result);
		} catch (ApiException e) {
			System.err.println("An exception occurred when calling DirectoryListsApi.listDirectoryLists");
			e.printStackTrace();
		}
	}
}

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

Create a Directory List

post/directorylists

Create a new directory list.

Related SDK Methods:
Java

DirectoryListsApi.createDirectoryList([param1, param2, ...])

Python

DirectoryListsApi.create_directory_list([param1, param2, ...])

JavaScript

DirectoryListsApi.createDirectoryList([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 settings of the new directory list.

description
string

Description of the directory list. Searchable as String.

items
Array of strings

List of directory paths. Windows directories need to end in a backslash (). Asterisk (*) is a wildcard character.

name
string

Name of the directory list. Searchable as String.

Responses
200

successful operation

403

Not authorized to create directory lists.

Request samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "items": [
    ]
}
Response samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "items": [
    ],
  • "ID": 0
}

Search Directory Lists

post/directorylists/search

Search for directory lists using optional filters.

Related SDK Methods:
Java

DirectoryListsApi.searchDirectoryLists([param1, param2, ...])

Python

DirectoryListsApi.search_directory_lists([param1, param2, ...])

JavaScript

DirectoryListsApi.searchDirectoryLists([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

403

Not authorized to view directory lists.

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

Describe a Directory List

get/directorylists/{directoryListID}

Describe a directory list by ID.

Related SDK Methods:
Java

DirectoryListsApi.describeDirectoryList([param1, param2, ...])

Python

DirectoryListsApi.describe_directory_list([param1, param2, ...])

JavaScript

DirectoryListsApi.describeDirectoryList([param1, param2, ...])

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

The ID number of the directory list to describe.

Example: 1
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Responses
200

successful operation

403

Not authorized to view directory lists.

404

The directory list does not exist.

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.DirectoryListsApi;
import com.trendmicro.deepsecurity.model.DirectoryList;


public class DescribeDirectoryListExample {
	
	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
		DirectoryListsApi instance = new DirectoryListsApi();
		Integer directoryListID = 1;
		String apiVersion = "YOUR VERSION";
		try {
			// Please replace the parameter values with yours
			DirectoryList result = instance.describeDirectoryList(directoryListID, apiVersion);
			System.out.println(result);
		} catch (ApiException e) {
			System.err.println("An exception occurred when calling DirectoryListsApi.describeDirectoryList");
			e.printStackTrace();
		}
	}
}

Response samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "items": [
    ],
  • "ID": 0
}

Modify a Directory List

post/directorylists/{directoryListID}

Modify a directory list by ID. Any unset elements will be left unchanged.

Related SDK Methods:
Java

DirectoryListsApi.modifyDirectoryList([param1, param2, ...])

Python

DirectoryListsApi.modify_directory_list([param1, param2, ...])

JavaScript

DirectoryListsApi.modifyDirectoryList([param1, param2, ...])

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

The ID number of the directory list to modify.

Example: 1
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Request Body schema: application/json

The settings of the directory list to modify.

description
string

Description of the directory list. Searchable as String.

items
Array of strings

List of directory paths. Windows directories need to end in a backslash (). Asterisk (*) is a wildcard character.

name
string

Name of the directory list. Searchable as String.

Responses
200

successful operation

403

Not authorized to modify directory lists or the requested modification is not permitted.

404

The directory list does not exist.

Request samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "items": [
    ]
}
Response samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "items": [
    ],
  • "ID": 0
}

Delete a Directory List

delete/directorylists/{directoryListID}

Delete a directory list by ID.

Related SDK Methods:
Java

DirectoryListsApi.deleteDirectoryList([param1, param2, ...])

Python

DirectoryListsApi.delete_directory_list([param1, param2, ...])

JavaScript

DirectoryListsApi.deleteDirectoryList([param1, param2, ...])

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

The ID number of the directory list to delete.

Example: 1
header Parameters
api-version
required
string

The version of the api being called.

Example: YOUR VERSION
Responses
200

Request is successful.

403

Not authorized to delete directory lists.

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.DirectoryListsApi;


public class DeleteDirectoryListExample {
	
	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
		DirectoryListsApi instance = new DirectoryListsApi();
		Integer directoryListID = 1;
		String apiVersion = "YOUR VERSION";
		try {
			// Please replace the parameter values with yours
			instance.deleteDirectoryList(directoryListID, apiVersion);
		} catch (ApiException e) {
			System.err.println("An exception occurred when calling DirectoryListsApi.deleteDirectoryList");
			e.printStackTrace();
		}
	}
}