Flex Design

Description

A Flex design a studio saved to a brand's My Designs.

Properties

Property Description
aspectRatio

The canvas aspect ratio, e.g. 2 / 1.

basedOnTemplateId nullable read-only

The public identifier of the template this design started from, if any.

body

The serialized Flex section (a JSON object, at most 64 KB). ((tokens)) the studio kept are left intact.

created read-only

When this design was created.

id read-only

The public identifier of this design. Set by the server; do not send it on create.

lastUpdated read-only

When this design was last updated.

links required read-only

Each property defines a hypertext link relationship as indicated by a link object or array of link objects. The target URL of each hypertext link relationship is related to the current resource according to the defined semantics of the link relationship property name.

name

The name shown in My Designs.

schemaVersion

The Flex section shape version. Defaults to 1.

scope

The Flex catalog this design belongs to. Set on create only.

source read-only

Where the design comes from, for pickers that mix templates and saved designs.

status

Whether the design is active or inactive. The brand's design list returns both unless filtered. Defaults to active on create.

templateId nullable write-only

On create, the public identifier (a UUID) of the active template (in the same scope) this design started from.

type

The type of object represented.

OpenAPI Schema

The following schema is based on OpenAPI 3.0 and is provided in our downloadable OpenAPI document.

{
  "description": "A Flex design a studio saved to a brand's My Designs.",
  "properties": {
    "aspectRatio": {
      "description": "The canvas aspect ratio, e.g. `2 / 1`.",
      "maxLength": 16,
      "type": "string"
    },
    "basedOnTemplateId": {
      "description": "The public identifier of the template this design started from, if any.",
      "nullable": true,
      "readOnly": true,
      "type": "string"
    },
    "body": {
      "description": "The serialized Flex section (a JSON object, at most 64 KB). `((tokens))` the studio kept are left intact.",
      "type": "object"
    },
    "created": {
      "description": "When this design was created.",
      "format": "date-time",
      "readOnly": true,
      "type": "string"
    },
    "id": {
      "description": "The public identifier of this design. Set by the server; do not send it on create.",
      "readOnly": true,
      "type": "string"
    },
    "lastUpdated": {
      "description": "When this design was last updated.",
      "format": "date-time",
      "readOnly": true,
      "type": "string"
    },
    "links": {
      "$ref": "#/components/schemas/Links"
    },
    "name": {
      "description": "The name shown in My Designs.",
      "maxLength": 250,
      "type": "string"
    },
    "schemaVersion": {
      "description": "The Flex section shape version. Defaults to 1.",
      "minimum": 1,
      "type": "integer"
    },
    "scope": {
      "description": "The Flex catalog this design belongs to. Set on create only.",
      "enum": [
        "email-header"
      ],
      "type": "string"
    },
    "source": {
      "description": "Where the design comes from, for pickers that mix templates and saved designs.",
      "enum": [
        "saved"
      ],
      "readOnly": true,
      "type": "string"
    },
    "status": {
      "description": "Whether the design is active or inactive. The brand's design list returns both unless filtered. Defaults to `active` on create.",
      "enum": [
        "active",
        "inactive"
      ],
      "type": "string"
    },
    "templateId": {
      "description": "On create, the public identifier (a UUID) of the active template (in the same scope) this design started from.",
      "nullable": true,
      "type": "string",
      "writeOnly": true
    },
    "type": {
      "description": "The type of object represented.",
      "enum": [
        "flex-design"
      ],
      "type": "string"
    }
  },
  "required": [
    "name",
    "scope",
    "aspectRatio",
    "body"
  ],
  "title": "Flex Design",
  "type": "object"
}