# Directory operations

### Check if directory exists <a href="#check-if-directory-exists" id="check-if-directory-exists"></a>

Determains whether directory at specified path exists.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter | Description        |
| --------- | ------------------ |
| Path      | The path to check. |

#### Output <a href="#output" id="output"></a>

Simple value,'True' if directory exists. 'False' otherwise.

#### Since <a href="#since" id="since"></a>

6.0

### Create directory <a href="#create-directory" id="create-directory"></a>

Creates all the directories at specified path.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter                                          | Description                                                                                                                                                    |
| -------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Path                                               | The path to create. Allow subdirectories on path will also be created if they do not exist.                                                                    |
| Allow Everyone to have full control over directory | If set to True, all users have full control over directory. If set to False, only the user the Connector is running as can access the directory. Default True. |

#### Output <a href="#output" id="output"></a>

Simple value containing the path to the newly created directory.

#### Since <a href="#since" id="since"></a>

6.0

### Delete directory <a href="#delete-directory" id="delete-directory"></a>

Deletes directory at provided path. Directory must be empty unless 'Also delete all subdirectories (and files)' is true.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter                                  | Description                                                                                                                       |
| ------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------- |
| Path                                       | The path to delete.                                                                                                               |
| Also delete all subdirectories (and files) | If set to True, all files and subdirectories will be deleted. If set to False, the directory must be empty in order to delete it. |

#### Output <a href="#output" id="output"></a>

Simple value,'True' if directory was successfully deleted. 'False' otherwise.

#### Since <a href="#since" id="since"></a>

6.0

### Delete files in directory <a href="#delete-files-in-directory" id="delete-files-in-directory"></a>

Deletes all files in directory matching specified pattern.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter      | Description                                                                                                  |
| -------------- | ------------------------------------------------------------------------------------------------------------ |
| Path           | The path to the directory to delete files from. Path can be UNC path or local file path.                     |
| Search pattern | Pattern to match files against. Supports wildcards \* and ? but not regular expressions. Default value "\*". |

#### Output <a href="#output" id="output"></a>

Simple value, number of files deleted.

#### Since <a href="#since" id="since"></a>

6.3

### Get all subdirectories of directory (full path) <a href="#get-all-subdirectories-of-directory-full-path" id="get-all-subdirectories-of-directory-full-path"></a>

Gets the full path of all subdirectories of given directory.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter                              | Description                                                                                                        |
| -------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| Path                                   | The path to get file names from. Path can be UNC path or local file path.                                          |
| Search pattern                         | Pattern to match directories against. Supports wildcards \* and ? but not regular expressions. Default value "\*". |
| Also get directories in subdirectories | Specifies whether to also include directories in subdirectories of Path. Default value False.                      |

#### Output <a href="#output" id="output"></a>

Table with column 'value' where each row is a full path to directory in given directory.

#### Since <a href="#since" id="since"></a>

6.0

### Get directory modification times <a href="#get-directory-modification-times" id="get-directory-modification-times"></a>

Gets a record containing directory modification times.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter | Description                               |
| --------- | ----------------------------------------- |
| Path      | The path to get modification times from.  |
| As UTC    | True to get the modification times in UTC |

#### Output <a href="#output" id="output"></a>

Record with members 'CreationTime', 'LastWriteTime' and 'LastAccessTime'.

#### Since <a href="#since" id="since"></a>

6.0

### Get files in directory (full path) <a href="#get-files-in-directory-full-path" id="get-files-in-directory-full-path"></a>

Gets the full path of all files in given directory.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter                        | Description                                                                                                  |
| -------------------------------- | ------------------------------------------------------------------------------------------------------------ |
| Path                             | The path to get file names from. Path can be UNC path or local file path.                                    |
| Search pattern                   | Pattern to match files against. Supports wildcards \* and ? but not regular expressions. Default value "\*". |
| Also get files in subdirectories | Specifies whether to also include files in subdirectories of Path. Default value False.                      |

#### Output <a href="#output" id="output"></a>

Table with column 'value' where each row is a full path to file in given directory.

#### Since <a href="#since" id="since"></a>

6.0

### Get name of all subdirectories of directory <a href="#get-name-of-all-subdirectories-of-directory" id="get-name-of-all-subdirectories-of-directory"></a>

Gets the names of all directories in given directory.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter      | Description                                                                                    |
| -------------- | ---------------------------------------------------------------------------------------------- |
| Path           | The path to get directory names from. Path can be UNC path or local file path.                 |
| Search pattern | Pattern to match directories against. Supports wildcards \* and ? but not regular expressions. |

#### Output <a href="#output" id="output"></a>

Table with column 'value' where each row is the name of a directory in given directory.

#### Since <a href="#since" id="since"></a>

6.0

### Get name of files in directory <a href="#get-name-of-files-in-directory" id="get-name-of-files-in-directory"></a>

Gets the names (including extension) of all files in given directory.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter      | Description                                                                              |
| -------------- | ---------------------------------------------------------------------------------------- |
| Path           | The path to get file names from. Path can be UNC path or local file path.                |
| Search pattern | Pattern to match files against. Supports wildcards \* and ? but not regular expressions. |

#### Output <a href="#output" id="output"></a>

Table with column 'value' where each row is the name of a file in given directory.

#### Since <a href="#since" id="since"></a>

6.0

### Move directory <a href="#move-directory" id="move-directory"></a>

Moves a directory to a new location.

#### Parameters <a href="#parameters" id="parameters"></a>

| Parameter                                    | Description                                                                                                                                            |
| -------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Source path                                  | The path to directory to move. Path can be UNC path or local file path.                                                                                |
| Destination path                             | The path to directory to move. Path can be UNC path or local file path.                                                                                |
| Overwrite destination directory if it exists | If set to True and destination path already exists, it is overwritten. If set to false and destination path already exists, no move operation is done. |

#### Output <a href="#output" id="output"></a>

Simple value, 'True' if directory was successfully moved. 'False' otherwise.

#### Since <a href="#since" id="since"></a>

6.0


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.novacuraflow.com/connectors/areas/utility/file-system/embedded-connector/directory-operations.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
