Documentation Index
Fetch the complete documentation index at: https://docs.squarecloud.app/llms.txt
Use this file to discover all available pages before exploring further.
Latest patch covered here: v4.0.1 (released 2026-05-30).
Requirements
- Node.js 20.0.0 or newer (v3 supported Node 18)
Breaking changes summary
| v3.x | v4.x |
|---|---|
client.users.* | client.user.* |
app.backup / app.backups | app.snapshots |
Backup export | Snapshot export |
app.deploys.list() returns flat Deployment[] | Returns Deployment[][] (call .flat() for old shape) |
Deployment.id formatted as `git-${string}` | Plain commit SHA-1 (40 hex chars) |
app.network.dns() returns an array | Returns { ownership, ssl } |
app.network.analytics() takes no arguments | Requires { start, end } (ISO string or Date) |
app.network.purgeCache(paths?) | purgeCache() — argument removed in v4.0.1, always purges the whole cache |
app.custom === undefined | app.custom === null |
workspace.members / .applications held data arrays | Renamed to workspace.memberList / .applicationList; the original names are now modules |
app.commit(file, name, restart) | app.commit(file, name) — third argument removed |
app.files.create(content, fullPath) | app.files.create(content, fileName, path) |
Renames
client.users → client.user
api.users is still exported as a deprecated getter that proxies to api.user, but it prints a warning at runtime.
Backups → Snapshots
Backup export is now a deprecated alias of Snapshot.
Application
Application.custom
app.custom is now null (was undefined in v3) when no custom domain is bound.
app.commit(file, fileName, restart)
The third restart argument has been removed. Restart manually after committing:
app.files.create(content, path)
The signature is now create(content, fileName, path = "/"). Migrating:
Deploys
app.deploys.list() shape
Deployment.id
Now a plain commit SHA-1 (40 hex chars) instead of a `git-…` formatted string.
Network
app.network.dns()
app.network.analytics()
app.network.purgeCache()
Workspaces
What’s new in v4
Beyond the renames and signature changes above, v4 adds a substantial feature set:- Databases — full lifecycle, credentials, snapshots and metrics (Databases)
- Workspaces — team collaboration with invite codes and roles (Workspaces)
- Environment variables — list / set / replace / delete (Environment variables)
- Application metrics — 24h CPU/RAM/network samples (Managing applications)
- Real-time SSE stream —
app.realtime()(Realtime) - Edge analytics — analytics, errors, logs and latency percentiles (Network)
- GitHub App integration —
app.deploys.linkGithubApp({ ... })(Deploys) - Snapshot restore —
app.snapshots.restore({ snapshotId, versionId })anddb.snapshots.restore(snapshotId, versionId) - Status-all endpoints —
api.applications.statusAll(),api.databases.statusAll() - Service status —
api.service.status() - User scoped snapshots —
api.user.snapshots(scope) - New User fields —
User.locale,User.createdAt,User.databases - New BaseApplication fields —
domain,custom,createdAt SquareCloudAPIError.code— public forswitch-based error handling

