Skip to the documentation
API

See what an export would hold

Whether an export can start now, and how much it would hold.

GET/exports/preview

Runs the real call on your workspace.

GET /exports/preview

Whether an export can start now, and how much it would hold.

Example

Needs threads:read. When allowed is false, reason is not-permitted, mailbox-login or two-factor-required and counts is null. nextAvailableAt is set while the daily limit holds, and activeExportId names an export still being made.

curl
curl "$OE/exports/preview" -H "$AUTH"
Response
{  "object": "export_preview",  "allowed": true,  "reason": null,  "nextAvailableAt": null,  "activeExportId": null,  "counts": {    "threads": 18420,    "attachments": 6211,    "attachmentBytes": 1532871224,    "deletedFiles": 14,    "contacts": 912,    "audiences": 6,    "calendarEvents": 233,    "templates": 18,    "rules": 9,    "labels": 24,    "notes": 41,    "addresses": 7  }}

Only the workspace owner, or a member whose role holds every permission, can export the workspace: an API key, or an app connected with every address. A key or an app limited to particular addresses or domains is a 422 capability_unsupported.

Reference