---
title: "Does a path exist, and what is it. Never follows a final link."
method: GET
path: "/v1/sandboxes/{id}/files/stat"
tags: ["files"]
---

# Does a path exist, and what is it. Never follows a final link.

`GET /v1/sandboxes/{id}/files/stat`

## Request

- Base URL: `https://api.withruntime.com`
- URL: `https://api.withruntime.com/v1/sandboxes/{id}/files/stat`
- Auth: HTTP bearer

## Path parameters

- `id` string, required: Resource identifier (UUID).

## Query parameters

- `path` string: Absolute path in the sandbox, e.g. /workspace/app/main.py. Any path the sandbox user may use.

## Response `200`

Success

- union
  - object
    - `exists` false, required
    - `path` string, required
  - object
    - `exists` true, required
    - `name` string, required
    - `path` string, required
    - `type` 'file' | 'directory' | 'symlink' | 'other', required
    - `size` integer, required
    - `mode` string, required: Octal permissions, e.g. 0644.
    - `modifiedAt` string, date-time, required
    - `uid` integer
    - `gid` integer
    - `owner` string
    - `group` string
    - `symlinkTarget` string

## Other responses

- `default`: Error

---

[API](https://skmtc.dev/withruntime/apis/runtime-cloud-api.md) · [All operations](https://skmtc.dev/withruntime/apis/runtime-cloud-api/llms.txt) · [OpenAPI document](https://skmtc.dev/withruntime/apis/runtime-cloud-api/revisions/6f4012286988?raw)
