On September 25th, 2024, we released v2 of the Apps SDK. To learn what’s new and how to upgrade, see Migration FAQ and Migration guide.

requestExport

API reference for the requestExport method.
This version of the API is in beta. Beta APIs are unstable and may change without warning. You can't release public apps using this API until it's stable.

Exports the user's design as one or more static files.

Parameters

requestExportRequest
REQUIRED

The request object containing configurations of the design export.

Properties of request
acceptedFileTypesExportFileType[]
REQUIRED

The types of files the user can export their design as.

You must provide at least one file type.

The available options include:

  • "png"
  • "jpg"
  • "pdf_standard"
  • "video"
  • "gif"
  • "pptx"
  • "svg"

Returns

The result of exporting a design. This is a Promise that resolves with the following object:

The result when a user successfully completes an export flow.

statusstring

The status of the export flow.

This must be "completed".

exportBlobsExportBlob[]

The exported files.

This array only contains one element. This is because, if a multi-page design is exported as multiple files, the files are exported in a ZIP file. In the future, there'll be an option for each file to be a separate element in the array.

Properties of exportBlobs
urlstring

The URL of the exported design.

If a user's design contains multiple pages but is exported in a format that doesn't support multiple pages, this URL will point to a ZIP file that contains each page as a separate file.

For example:

  • If a single-page design is exported as a JPG, the URL will point to a JPG file.
  • If a multi-page design is exported as a JPG, the URL will point to a ZIP file that contains a JPG file for each page.
  • If a multi-page design is exported as a PDF file, the URL will point to a PDF file.

The following file types support multiple pages:

  • "GIF"
  • "PDF_STANDARD"
  • "PPTX"
  • "VIDEO"

The following file types do not support multiple pages:

  • "JPG"
  • "PNG"
  • "SVG"
titlestring
OPTIONAL

The title of the design, if set by the user.

The result when a user abandons the export flow, such as by closing the export menu.

statusstring

The status of the export flow.

This must be "aborted".