v48

latestOpenAPI 3.0.0raw.githubusercontent.com2025-12-0297180624.8 KB
File System

Check if file/dir exists

post/boxes/{boxId}/fs/exists

Path parameters

boxIdstring required
Example:c9bdc193-b54b-4ddb-a035-5ac0c598d32d

Box ID

Request body

workingDirstring

Working directory. If not provided, the file will be read from the box.config.workingDir directory.

pathstring required

Target path in the box. If the path does not start with '/', the file/directory will be checked relative to the working directory

Example request

{
  "workingDir": "/home/user/documents",
  "path": "/home/user/documents/output.txt"
}

Response

Checks whether a file or directory exists inside a box. Use this endpoint for path validation.

OR

Example response

{
  "exists": true,
  "type": "file"
}