Import - Export

Export entities and store them into a single file and later recover the state or import to a different instance

export

Migrating templates

This extension can be used to move templates to different servers as well to different servers using different template stores. This means you can for example copy templates from default file system store to mssql store or postgres store.

API

Export into stream

POST: /api/export
BODY: {
  //optional
  selection: ["id1", "id2" ...]
}

Import from stream

POST: /api/import
BODY: /* multipart import.jsrexport */

You can find how to send multiplart through postmant here.

CLI

The export/import can be called also using jsreport cli.

jsreport export jsreportExport.jsrexport
jsreport import jsreportExport.jsrexport

This can be done also remotely using --serverUrl switch. This is handy for deployment automation.

jsreport export --serverUrl=myjsreport.com jsreportExport.jsrexport
jsreport import --serverUrl=myjsreport.com jsreportExport.jsrexport

The cli export commands support also authentication, importing and exporting specific folder or specific entities, validation and also full import. See details in the cli help.

jsreport help export
jsreport help import

jsreport version