عمليات التصدير
كل عملية في هذه المجموعة: ما تقبله وما تُرجعه والأخطاء التي قد تردّ بها.
العمليات
A zip of the whole workspace, as the Export page of the app makes it: every conversation as mbox files with its attachments, contacts as vCard, audiences, calendar events as .ics, templates with every version, rules, labels, notes and addresses. An export is made in the background, can be started once a day and is kept for 365 days.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
GET/exports/preview
See what an export would hold
Whether this workspace can be exported by the caller now, when the next export can start, the export still being made, if there is one, and how much an export would hold. When allowed is false, reason says why and counts is null.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
Requires the threads:read scope.
يُرجع
What an export would hold, and whether one can start.
الأخطاء
الأخطاء التي يمكن أن تُرجعها أي عملية400401403404422500دليل الأخطاء
متاح أيضًا في
GET/exports
List the exports
Every export of the workspace, newest first, with its status and progress. limit and offset page through them, and total counts them all.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
Requires the threads:read scope.
معلمات الاستعلام
limitintegerExports per page, 1 to 100.
على الأقل 1على الأكثر 100الافتراضي25offsetintegerHow many exports to skip.
على الأقل 0الافتراضي0
يُرجع
A page of exports, newest first.
الأخطاء
الأخطاء التي يمكن أن تُرجعها أي عملية400401403404422500دليل الأخطاء
متاح أيضًا في
POST/exports
Start an export
Starts making a zip of the whole workspace, as Export now on the Export page does. It is made in the background: read it with GET /exports/{id} until status is ready, then download it. One export can run at a time, and a workspace can be exported once a day.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
Requires the threads:read scope.
يُرجع
The export, queued.
الأخطاء
- 403
The key lacks the scope, or may not send as that address.
step_up_required: the call was made with an OAuth access token that has not been verified in the last 60 minutes. Ask for a code withPOST /security/step-up, send it toPOST /security/step-up/verify, then repeat the call. The person can also choose Allow changes for 60 minutes on the app in Account settings, Connected apps, on the OpenEmail website. An API key is never asked for a code.- 409
already_running: an export of this workspace is already being made.- 429
export_limit_reached: the workspace was exported in the last day.
الأخطاء التي يمكن أن تُرجعها أي عملية400401404422500دليل الأخطاء
متاح أيضًا في
GET/exports/{id}
Retrieve an export
One export, with its status, its progress through the conversations and, once it is ready, its size, file name and when it is deleted.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
Requires the threads:read scope.
معلمات المسار
idstringمطلوبThe export id from
GET /exportsorPOST /exports.
يُرجع
The export.
الأخطاء
الأخطاء التي يمكن أن تُرجعها أي عملية400401403404422500دليل الأخطاء
متاح أيضًا في
GET/exports/{id}/content
Download an export
The zip itself, as application/zip with its file name in Content-Disposition. It is only there once the export is ready: before that the call is a 409 export_not_ready, and an export older than 365 days is a 409 expired.
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, and an account the workspace cannot export for is a 403 export_not_permitted.
Requires the threads:read scope.
معلمات المسار
idstringمطلوبThe export id from
GET /exportsorPOST /exports.
يُرجع
application/zipThe zip.
الأخطاء
- 403
The key lacks the scope, or may not send as that address.
step_up_required: the call was made with an OAuth access token that has not been verified in the last 60 minutes. Ask for a code withPOST /security/step-up, send it toPOST /security/step-up/verify, then repeat the call. The person can also choose Allow changes for 60 minutes on the app in Account settings, Connected apps, on the OpenEmail website. An API key is never asked for a code.- 409
export_not_ready: the export is still being made or failed.expired: it was deleted a year after it was made.
الأخطاء التي يمكن أن تُرجعها أي عملية400401404422500دليل الأخطاء
متاح أيضًا في
الكائنات
Exportobject
objectstringمطلوب- أحد
"export" idstringمطلوبstatusstringمطلوب- أحد
"queued""running""ready""failed""expired" phasestringWhat it is doing while
statusisrunning.يمكن أن يكون nullأحد"planning""mail""records""finishing"createdAtstringمطلوب- التنسيق
date-time createdByobjectWho started it, or null when that account is gone.
يمكن أن يكون nullnamestring- يمكن أن يكون null
emailstring
startedAtstring- يمكن أن يكون nullالتنسيق
date-time finishedAtstring- يمكن أن يكون nullالتنسيق
date-time expiresAtstringWhen the zip is deleted, a year after it was made.
يمكن أن يكون nullالتنسيقdate-timesizeBytesinteger- يمكن أن يكون null
fileNamestring- يمكن أن يكون null
threadsDoneinteger- على الأقل 0
threadsTotalinteger- يمكن أن يكون null
errorstringWhy it failed, when
statusisfailed.يمكن أن يكون null
ExportListobject
objectstring- أحد
"list" dataExport[]totalintegerHow many exports there are in all.
على الأقل 0hasMorebooleanWhether more exports follow this page.
ExportPreviewobject
objectstringمطلوب- أحد
"export_preview" allowedbooleanمطلوبWhether the caller may export this workspace.
reasonstringمطلوبWhy not, when
allowedis false:not-permittedfor an account that is neither the owner nor holds every permission,mailbox-loginfor a sign-in for one address, andtwo-factor-requiredwhen the workspace requires two-factor sign-in and the account has none.يمكن أن يكون nullأحد"not-permitted""mailbox-login""two-factor-required"nextAvailableAtstringمطلوبWhen the next export can start, or null when one can start now.
يمكن أن يكون nullالتنسيقdate-timeactiveExportIdstringمطلوبThe export still being made, if there is one.
يمكن أن يكون nullcountsobjectمطلوبHow much an export would hold now. Null when
allowedis false.يمكن أن يكون nullthreadsintegerConversations.
على الأقل 0attachmentsintegerAttachments inside them.
على الأقل 0attachmentBytesintegerThe size of those attachments, in bytes.
على الأقل 0deletedFilesintegerDeleted files, listed by name and date but not included.
على الأقل 0contactsintegerContacts.
على الأقل 0audiencesintegerAudiences.
على الأقل 0calendarEventsintegerCalendar events.
على الأقل 0templatesintegerTemplates.
على الأقل 0rulesintegerRules.
على الأقل 0labelsintegerLabels.
على الأقل 0notesintegerNotes of the caller.
على الأقل 0addressesintegerAddresses.
على الأقل 0