---
schema_version: "1"
id: 270e3aa126451b5c0f8cecd7f76a5a7c1eea76b6d3f4099c27f72f0b49b21b31
title: File Check
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/rpa-builder/latest/toolbox-file-operations-file-check.md
canonical_url: https://docs.mulesoft.com/rpa-builder/latest/toolbox-file-operations-file-check
source_site: docs.mulesoft.com
content_type: documentation
content_hash: da98692e80e2d0caccb685b922c67a6150b972fe0aceb3d572b696c80e15f5a5
description: MuleSoft Documentation Site
release: "6.7"
latest: true
---
---
product: RPA Builder
version: 6.7
is-latest-version: true
---

# File Check

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

Use the _File Check_ action step to check whether a file exists or not. You can evaluate the result
using the _File Check.Check Succeeded_ variable and use it in the later stages of the workflow.

Before the process starts, the specified _Directory Path_ is checked against the _Allowed Paths_. If
the _Directory Path_ specified in the action step is not allowed, the workflow is cancelled and an
error message displayed.

## Properties

- **File Operation Settings**

  - **Directory path** Path to the directory in which you want to search for the file. You can enter
    the path either as an absolute or relative path. If you enter it as a relative path, the path
    refers to the _Base Path_ variable.

  - **File Check mode** Specify wether to check if the exists or if it doesn’t exist.

    - **File exists** (default) Checks whether the file exists. If it doesn’t exist, the workflow
      stops and displays an error message.

    - **File not exists** Checks if the file _doesn’t_ exist. If it does, the workflow stops and
      displays an error message.

  - **File Name** Name of the file you are searching for.

This action step does not support using Placeholders. For additional details about path and file
name settings and a list of unsupported characters, see
[Path / file name / invalid characters](https://docs.mulesoft.com/rpa-builder/latest/toolbox-file-operations#invalid-characters).

## Inbound Variables

- **Directory path** Path to the directory in which you want to search for the file. You can enter
  the path either as an absolute or relative path. If you enter it as a relative path, the path
  refers to the _Base Path_ variable.

- **File Name** Name of the file you are searching for.

## Outbound Variables

- **Check Succeeded** Specifies whether the check was successful or not (True/False).

- **File Name** The name of the file to be found.

- **Directory Path** The path used in the search.

## Wizard

Define the path to the file to be found. You can create an absolute path or a path relative to the
_Base Path_. The initial value is `` %STWS_BASEPATH%` ``. Select an existing path You can also
insert variables from the workflow to create the path. To do this, click the pin and select one of
the available variables.

In the **File name** field, enter the name of the file to be found. You can also insert the _File
Name_ using a variable from the workflow. To do this, click the pin and select one of the available
variables. You then use the **Check mode** to define the result that is to be searched for.

## See Also

[Common File Settings and Properties](https://docs.mulesoft.com/rpa-builder/latest/toolbox-file-operations#common-settings)
