Skip to main content
The object field is the heart of every line in an import file. It holds the actual configuration and is where most of the work goes. This page walks through building it from scratch.

Object structure

The object takes one of two shapes, depending on whether the type uses named prototypes or a single default prototype:
The first form names a prototype explicitly. The second is for types with a single default prototype, so no prototype key is needed.

Step by step

1

Pick a top-level type

The type at the top level of the line decides what you are building. Only the types below are allowed at the top level of an import line.The main types you start from:Connection types, referenced by the ones above:Helper types:
2

Find the prototypes for that type

Each type offers a set of prototypes or a default prototype: templates with a JSON schema that lists the fields you fill in. Fetch the supported prototypes for a type from the Alumio API:
See Finding configuration types and schemas below for more information.
3

Set the prototype and its parameters

Put the chosen prototype identifier in prototype, and fill the fields from its schema into parameters:
For a type that uses its default prototype, omit the prototype key and provide only parameters.
4

Reference or inline a nested configuration

Some fields hold another prototype or configuration rather than a plain value. The field’s schema tells you which through its di:type and di:allow properties (see Common schema properties below). When a reference is allowed, you have two options.Inline as its own prototype and parameters:
Or reference a configuration that is already saved in the environment (or defined on another line in the same file), by its identifier:
To see what already exists to reference, list the saved configurations of that type:
5

Nest as deep as you need

Prototypes can hold other prototypes, so the structure nests. In the example below, a list-transformer (prototype data) contains an http-transformer, whose client is a reference to a saved http-client (webshop) and whose request.serializer is an inline json prototype:

ULIDs

Alumio stamps a ulid on every prototype object during import validation. Do not generate them yourself.
  • When creating: omit ulid everywhere. The server injects them.
  • When updating: start from the exported or fetched JSON and keep the ulid fields it already contains, so embedded objects keep their identity.

Finding configuration types and schemas

Use the Alumio API to find prototypes and configurations.

Search for prototypes of a type

To list all available prototypes for a type use the following API call.

List saved configurations

To see what is already configured in the environment (so you reuse instead of duplicate), list the saved configurations of a type.

Common schema properties

When you read a prototype’s schema, a handful of properties tell you how to fill in a field. They live under a field’s ui object.

di:type

Marks a field that holds a nested configuration of a given type, rather than a plain value. For example, a field with di:type: subscriber expects a subscriber prototype (inline) or a reference to a saved subscriber. The value is either an inline prototype object or a reference object, as shown in the steps above.

di:allow and di:force

These say whether a di:type field may point at a saved configuration.
  • di:allow: configuration means a reference to a saved configuration is allowed. Use a reference object { "identifier": "..." }, or inline the prototype if you prefer. The route’s incoming and outgoing fields work this way.
  • di:force: configuration means the value must be its own saved configuration, referenced by identifier. Every transformers array uses this: create a standalone list-transformer line and reference it. Inline objects are accepted by the importer but render poorly in the dashboard.

ui:supportsPlaceholders

Marks a field that accepts a placeholder. For example &{id}. See Placeholders.

ui:patterns

Marks a field that uses path patterns to select or write data. For example products.*.sku. See Patterns.