Stat Path
curl --request GET \
--url https://api.example.com/browser/sessions/{id}/fs/infoimport requests
url = "https://api.example.com/browser/sessions/{id}/fs/info"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/browser/sessions/{id}/fs/info', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/browser/sessions/{id}/fs/info",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/browser/sessions/{id}/fs/info"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/browser/sessions/{id}/fs/info")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/browser/sessions/{id}/fs/info")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"path": "<string>",
"type": "<string>",
"size": 123,
"mode": 123,
"mtime": "<string>",
"uid": 123,
"gid": 123
}Filesystem
Stat Path
Return metadata for a workspace path (type, size, mode, mtime, uid/gid).
GET
/
browser
/
sessions
/
{id}
/
fs
/
info
Stat Path
curl --request GET \
--url https://api.example.com/browser/sessions/{id}/fs/infoimport requests
url = "https://api.example.com/browser/sessions/{id}/fs/info"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.example.com/browser/sessions/{id}/fs/info', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/browser/sessions/{id}/fs/info",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/browser/sessions/{id}/fs/info"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.example.com/browser/sessions/{id}/fs/info")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/browser/sessions/{id}/fs/info")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"path": "<string>",
"type": "<string>",
"size": 123,
"mode": 123,
"mtime": "<string>",
"uid": 123,
"gid": 123
}Overview
Returnsstat(2)-style metadata for a workspace path. Works for files, directories, and symlinks. Use this to check existence without pulling content, or to branch on type before calling the read vs. list endpoints.
Path Parameters
string
required
Browser session ID (UUID).
Query Parameters
string
required
Workspace-relative path to stat.
Example Request
curl -G "https://api.scrapengine.io/api/v1/browser/sessions/baa3f390-fa6e-4a24-b84a-a575a5f3a9c7/fs/info" \
-H "Authorization: Bearer $SCRAPENGINE_API_KEY" \
--data-urlencode "path=notes/todo.txt"
Response
Success Response (200)
string
The workspace-relative path that was stat’d.
string
One of
file, dir, symlink, other.integer
Size in bytes. For directories this is the directory entry size, not the tree size.
integer
Unix mode.
string
Last modified timestamp (ISO 8601).
integer
Owner UID.
integer
Owner GID.
{
"path": "notes/todo.txt",
"type": "file",
"size": 11,
"mode": 420,
"mtime": "2026-04-24T09:12:44Z",
"uid": 1000,
"gid": 1000
}
Error Responses
| Status | Description |
|---|---|
400 | Invalid path. |
401 | Unauthorized — invalid or missing API key. |
404 | Session or path not found. |
Was this page helpful?