You run schema import and export from the more actions icon (vertical …) next to the model name heading on the Schema screen. Import creates fields in bulk from a JSON file, and export saves the current schema as a JSON file.
Owner, Maintainer, and Writer can import. Owner, Maintainer, Writer, and Reader can all export.
Import a schema
Section titled “Import a schema”Creates fields in bulk from a JSON file. JSON is the only file format you can use. For how to write the JSON, see Import / Export.
When you import for the first time, a template gives you a file that matches the expected format. You can download the template from the link on the Import Schema screen, which you open in step 4.
-
Under Models on Schema, choose a model that has no fields at all.
-
Open the Fields tab.
-
Click the more actions icon (vertical …) next to the model name heading and choose Import.
-
On the Import Schema screen, select a JSON file or drag and drop it.
-
In Schema preview, check the list of fields that will be created from the file.
- The type of each field is detected automatically from the file’s contents. To use a different type, choose it from Field Type in that row.
- To leave a field out, clear the check at the right of its row. Leave at least one field to bring in.
- You can change the order by grabbing the icon at the left of a row.
-
Click Import. Import cannot be clicked when no check is left. When the import finishes, Import successful! is shown and the screen closes.
When a file can be read as JSON but its format does not match, the screen switches to a list of errors. Download error log saves the errors to a file, and Back returns you to file selection. When you select a file whose extension is not json, a file with no contents, or a file that is broken as JSON, a notice is shown on the file selection screen.
You can only import on the Fields tab of a model that has no fields at all. Import in the menu cannot be operated in the following cases. The reason is shown when you hover over the menu item.
- A group is selected
- The Meta Data tab is open
- The selected model has one or more fields
- Your role does not have permission to add fields
Export a schema
Section titled “Export a schema”The schema of the model you chose is downloaded on the spot.
- Under Models on Schema, choose the model you are exporting.
- Click the more actions icon (vertical …) next to the model name heading and choose Export.
The download of a JSON file begins. The file name uses the model’s ID rather than the model name, as 〈model ID〉-schema.json. Export cannot be operated for a model that has no fields at all.