Get Space Pages
The space get commands download all pages in a Confluence space to a local directory in their native format. This works like space convert, but without converting to Markdown: pages are saved as Storage HTML or ADF JSON.
By default the result is a restorable backup: next to the page bodies, space get saves each page’s attachments and a manifest of the page and folder tree, versions, labels and content properties. space check compares it with the live space, and space restore puts it back.
Use this for backup and disaster recovery, engineering analysis, migration research, raw preservation, or custom downstream processing rather than immediate Markdown output.
Get by key
acs2md space get by-key SPACE_KEY [flags]Aliases: key, k
Examples
# A restorable backup: storage bodies, attachments, labels, properties, manifest
acs2md space get by-key DOCS --output-dir ./backups/
# ADF JSON for a processing pipeline
acs2md space get by-key DOCS --format atlas_doc_format
# Page bodies only, the fastest run
acs2md space get by-key DOCS --include-attachments=false \
--include-labels=false --include-properties=false
# Specify a custom output directory
acs2md space get by-key DOCS --output-dir ./my-export/
# Download only archived pages
acs2md space get by-key DOCS --status archived
# Re-download only changed pages and remove local files for removed pages
acs2md space get by-key DOCS --output-dir ./native-export --sync
# Re-download only changed pages but keep removed pages locally
acs2md space get by-key DOCS --output-dir ./native-archive --incrementalFlags
| Flag | Short | Default | Description |
|---|---|---|---|
--output-dir | — | ./output | Base output directory; <space-key>/ is always appended |
--format | -f | storage | Body format: storage or atlas_doc_format |
--status | -s | current | Page status: all, current, archived, trashed, deleted, draft |
--conflict-resolution | — | overwrite | Filename conflicts: suffix, overwrite, skip, versioned |
--sync | — | false | Re-download changed pages; delete files removed upstream. Mutually exclusive with --incremental. |
--incremental | — | true | Re-download changed pages; keep files removed upstream. Mutually exclusive with --sync. |
--manifest | — | true | Write .backup-manifest.json (needed to restore) |
--include-attachments | — | true | Download page attachments (extra API calls) |
--include-labels | — | true | Record page labels (one API call per page) |
--include-properties | — | true | Record content properties (one API call per page) |
The default format changed to storage in v1.0.12 (it was
atlas_doc_format). Storage refers to attachments and pages by name, which
survives a restore that gives them new IDs. Pass --format atlas_doc_format
for the previous behaviour. A directory that already holds a backup keeps its
format unless you pass --format, so a scheduled backup never mixes .html
and .json files.
Get by ID
acs2md space get by-id SPACE_ID [flags]Downloads all pages in a space using the numeric space ID.
Aliases: id
The flags and behavior mirror space get by-key.
acs2md space get by-id 123456 --format storage --output-dir ./export/Progress reporting
Long-running native downloads display a real-time progress bar on stderr. That keeps stdout clean for redirected output while still giving operators visibility into the current page and overall completion.
space getshows page download progress--resolve-usersonspace liststill reports user-resolution progress separately- use the global
--no-progressflag when you need a clean CI log or demo transcript
Progress output goes to stderr, so redirected files and piped stdout output do not get polluted by the progress bar.
Output structure
Pages are saved to a directory tree that mirrors the space hierarchy:
backups/DOCS/ # the space key is always appended
.backup-manifest.json # page and folder tree, versions, labels, properties, attachments
.get-sync-state.json # version tracking for --sync / --incremental
getting-started.html
guides.html
guides/
quickstart.html
advanced-usage.html
attachments/
3134096561/ # one directory per page ID
runbook.pdfWith --format atlas_doc_format, page files have a .json extension instead of .html.
Restorable backups
By default space get writes everything a restore needs, not only the page bodies.
The manifest (.backup-manifest.json) records, for every page: its ID, title, status, parent and position among its siblings, the version the backup holds, and a SHA-256 of its body file. It also records the space’s name, type, description and homepage, and every Confluence folder the pages sit under, so the page tree can be rebuilt even though folders have no file of their own. Paths in the manifest are relative, so the backup can be moved or copied to another machine. Keep the manifest with the files.
Labels and content properties are recorded in the manifest, one API call per page each. Turn them off with --include-labels=false and --include-properties=false.
Attachments are saved under attachments/<page-id>/, and the manifest records each one’s Confluence title, file ID, media type, version, size and SHA-256. A title with characters no filesystem accepts is saved under a safe name; the manifest keeps the original title. An attachment that fails to download is reported and recorded without a file, so nothing is silently missing. Unchanged attachments are not downloaded again on the next run. Turn them off with --include-attachments=false.
Which format. storage (the default) is the restore-safe choice: it refers to attachments and other pages by name, so the references survive a restore that gives them new IDs. atlas_doc_format is lossless and easier to process, but refers to attachments by file ID; space restore rewrites those references when it uploads the files again.
What a backup cannot hold. Page and attachment IDs, authors, creation dates and version history belong to Confluence. A restore brings the content and the tree back, but not those. Pages under a folder are written at the top of the space directory, because only pages have files; the manifest keeps their real place in the tree.
Sync and incremental mode
space get supports the same changed-only workflow shape as space convert, but it tracks native downloads with .get-sync-state.json instead of .convert-sync-state.json.
--syncre-downloads changed pages and removes local files when the source page disappears from Confluence; it also drops those pages and their attachments from the manifest--incrementalre-downloads changed pages but keeps local files when the source page disappears from Confluence
A page whose version has not changed is skipped, and so are its attachments: an attachment added without a new page version is picked up the next time the page changes. Run with --incremental=false for a complete refresh. A page missing from the manifest is always downloaded again, so the first run of v1.0.12 on a backup taken by an earlier release fetches every page once to complete it.
This makes space get suitable for both strict continuity mirrors and archive-oriented native preservation workflows.
When to use space get instead of space convert
- use
space getwhen you need native Confluence payloads - use
space convertwhen you need portable Markdown - use both when a migration or troubleshooting workflow needs native inspection first and Markdown output second
Practical examples
Nightly restorable backup
acs2md space get by-key DOCS --output-dir /backups
acs2md space check by-key DOCS --backup-dir /backups --fail-on-driftNative preservation for migration engineering
acs2md space get by-key DOCS --format atlas_doc_format --output-dir ./native-docsRepeatable native archive with changed-only refresh
acs2md space get by-key DOCS --format storage --output-dir ./native-archive --incremental