younifyd
Menu

Create a new master category

Create a new master category

POST/master-categories

Use it in a workflow

  1. Add a step and choose the SCAYLE Admin connector.
  2. Pick the Create a new master category action (under MasterCategories).
  3. Fill in the fields below, then reference the result from later steps as {{createANewMasterCategory.response.data}}.

Request

Request body

Enter the body as JSON in the step's Body field.

idinteger

The ID of the master category created by SCAYLE.

parentIdinteger

The ID of the parent master category if exists.

patharray<string>required

The complete category path.

attributesarray<object>

List of attributes which are related to this category.

namestringrequired

The attribute name.

typestringrequired

The attribute type.

One ofsimplesimpleListlocalizedStringlocalizedStringListadvancedadvancedList

isMandatorybooleanrequired

Whether the attribute is mandatory or not. Used in the state *calculation*.

defaultValueany

The default value of the attribute if it is mandatory. Used in all attribute related processes if that specific attribute is not provided.

json
{
  "path": [
    "Women",
    "Fashion",
    "Shirts"
  ],
  "id": 2,
  "parentId": 1,
  "attributes": [
    {
      "name": "color",
      "type": "simple",
      "isMandatory": false,
      "defaultValue": null
    }
  ]
}

Response

Returns 201 with an object. Read it in later steps with {{createANewMasterCategory.response.data.<field>}}.

idinteger

The ID of the master category created by SCAYLE.

parentIdinteger

The ID of the parent master category if exists.

patharray<string>

The complete category path.

attributesarray<object>

List of attributes which are related to this category.

namestringrequired

The attribute name.

typestringrequired

The attribute type.

One ofsimplesimpleListlocalizedStringlocalizedStringListadvancedadvancedList

isMandatorybooleanrequired

Whether the attribute is mandatory or not. Used in the state *calculation*.

defaultValueany

The default value of the attribute if it is mandatory. Used in all attribute related processes if that specific attribute is not provided.

json
{
  "path": [
    "Women",
    "Fashion",
    "Shirts"
  ],
  "id": 2,
  "parentId": 1,
  "attributes": [
    {
      "name": "color",
      "type": "simple",
      "isMandatory": false,
      "defaultValue": null
    }
  ]
}

Need more? See the SCAYLE Admin guide for connection setup and behaviour shared by every action.

Create a new master category — SCAYLE Admin — Documentation