Create site backups

View as MarkdownOpen in Claude
Creates one manual backup per website of an explicit selection, with each website's configured areas unless `included` names them. Exclusions always come from the website's configuration. Body parameters: - `sites` (integer array, required): exact website ids, 1 to 200, scoped to the token's organization. - `included` (string array, optional): areas to copy instead of the configured ones - `database`, `core`, `plugins`, `themes`, `mu_plugins`, `content`, `uploads`. Answers **202** at once with the created `site-backups` documents (`phase: in_progress`) and `meta.skipped`: the websites the preflight refused, each with `site_id`, `site_name`, `backup_id` (null here), `reason_code` and `message`. Reason codes: `SITE_UNREACHABLE` (not connected), `UNSUPPORTED` (no backup configuration), `CONFLICT` (a backup or a restoration already running), `PERMISSION_DENIED` (id outside the token's reach, `site_name` null). `data: []` is still a 202. A copy takes minutes: follow it with `GET /site-backups?filter[id][]=...` or the show endpoint and read `phase`; only `done` is a usable copy. - **409**: the organization's storage quota is exhausted and no overage add-on is active - nothing is created. - **422**: `sites` missing, empty, over 200 ids, or containing an id that resolves to no row; an invalid `included` value. - **403**: a read-only token. - **404**: the organization's plan does not include manual backups, or the member lacks the permission. The MCP twin is the `site-backups-store` tool; the dashboard API offers the same call at `POST /api/site-backups/bulk`.

Authentication

AuthorizationBearer

Personal access token created in the Modular DS dashboard; read-only tokens can only call GET endpoints.

Request

This endpoint expects an object.
includedlist of stringsOptional
siteslist of doublesOptional

Response

202 Accepted - one copy created, one website skipped

datalist of objectsOptional
jsonapiobjectOptional
metaobjectOptional