Export a model
You export a model from the Export model dialog. This guide covers a direct export: writing your model to files in its own standard. To convert a model to a different standard instead, see Transform a model to another standard.
Prerequisites
Section titled “Prerequisites”- A model you can open in ModelDesk.
Open the Export model dialog
Section titled “Open the Export model dialog”- Open your model.
- In the bar at the top of the page, select Export. It is in the same place on every page of the model.
- The Export model dialog opens.

Export in the model’s own standard
Section titled “Export in the model’s own standard”- Leave Mapping on None (direct export). This exports the model in its own standard, without transforming it.
- Choose a Format. The available formats depend on the model’s standard. Each option shows the format name and its media type.
- If the format produces more than one file, use Document to choose which one to preview. When the format produces a single file, that file is already selected. The selected document is shown in the preview below.
- Download your export:
- Select the download button (its tooltip reads Download current document) to save the selected document.
- Select the archive button (its tooltip reads Download all documents as a zipped archive) to save every document together as a ZIP file.
Your browser downloads the file or ZIP archive. An export always reflects the model’s current working state, that is, the latest saved change; you cannot export an earlier commit or a named version. A direct export produces files only. It does not create a new model in your workspace.
Export a JSON Schema model
Section titled “Export a JSON Schema model”A JSON Schema export writes every Document of the model as its own .json file. Choose a file under Document to preview it, or download them all as a ZIP.
- File paths follow the Folders. A Document at the top of the model is written under its name, such as
order.json. A Document inside a Folder is written under its Folder path, such ascommon/address.json, also when it is the model’s only Document. The ZIP holds the Folders as directories. A published model serves each file under the same path. - References between the files resolve. A link from one Document to the root schema or a
$defsentry of another is written as a$refto that file. Where the files’$ids match their layout, or the target file declares no$id, the$refis a relative path, such ascommon/address.json#/$defs/Addressor../order.json. Where the$ids do not match the layout, the$refis the target’s$id. - Paths are unique and safe. Two Documents that would get the same path, compared without regard to case, are numbered, such as
common.jsonandCommon-2.json, and the references follow the number. A Folder name that is empty, and any name that is.or.., is written as_. So is each/or\in a name, so no file lands outside the export. A Document without a name is written asmodel.json. - Some references become copies. A
$refinto another file reaches only its root schema and its$defsentries. A link to any other schema in another Document is written as a copy of that schema, and the Export log in the dialog lists it as Reference written as a copy. To get a$ref, move the schema into$defsof its Document. - A Document without a root schema is left out. It has nothing to write, so the export skips it, writes the other Documents, and lists it in the Export log as Document left out.
With the CLI, modeldesk model export <model> --format "JSON Schema" -o <dir> writes each file into <dir>, with the Folder paths as subdirectories. Without -o, the CLI writes a single document to standard output, so for a model with several Documents it stops with exit code 2. Pass -o <dir>, or --compressed -o <file> for one ZIP.
Models with Extern packages
Section titled “Models with Extern packages”In a MIM model, an export writes a connected Extern package in full, as other tools expect it, and an unconnected one as it is. An element two packages hold is written once, under the first of them. When an export through a mapping, such as MIM to UML for XMI, meets a reference to an element of another model that no package holds, it leaves the reference out and lists it in the Export log, ending “Add the element to a package that represents that model.” See Export a model with Extern packages.
If this goes wrong
Section titled “If this goes wrong”- The Mapping list shows only “None (direct export)”. No transformation applies to this model, which is exactly what you want for a direct export. To learn when transformations are offered, see Transform a model to another standard.
- The Format you expected is not listed. The formats offered depend on the model’s standard. See Supported standards & formats for what each standard can produce.
- The preview is empty or the download buttons are missing. The document is still loading. Wait a moment, or select the Format again.
Related pages
Section titled “Related pages”- Supported standards & formats: the formats each standard can export to.
- Transform a model to another standard: export to a different standard using a mapping.
- Validate your model: check the model against its standard before you share an export.