Passa al contenuto principale

Export Models Create​

Saves a column selection under a name, so the same export can be repeated without picking the same columns again. Requires the export permission of the kind the model belongs to.

Request Body required
    name Name required

    Name of the export model, shown in the picker.

    kind object

    An enumeration.

    fields string[] required

    Keys of the columns to save, in the order they should appear. The mandatory identifier is not stored: an export writes it whether or not the model asks for it. Read the available keys from the fields endpoint of the same kind.

    script Script

    Post-processing script to offer with the model. It runs only when the model is used for a CSV export, and only if it is passed to the export request as script. Null or blank for none.

Responses

OK


Schema
    id Id required

    Unique identifier of the export model.

    name Name required

    Name of the export model, shown in the picker.

    kind object

    An enumeration.

    script Script

    Post-processing script offered with the model, for CSV exports. Null when it has none.

    field_keys string[] required

    Keys of the columns of the model, in the order they appear in the file. The mandatory identifier is not listed: an export writes it whether or not the model asks for it.

    fields object[] required

    Columns of the model, with their human-readable name.

  • Array [
  • key Key required

    Identifier of the column, as written in the file header.

    label Label required

    Human-readable name of the column. Falls back to the key when the column no longer exists.

  • ]
  • fields_count Fields Count required

    How many columns the model selects.

    create_date date-time required

    When the export model was created.

    update_date date-time required

    When the export model was last modified.

Loading...