younifyd
Menu

Batch Product Categories

Batch create, update, and delete product categories

POST/products/categories/batch

Use it in a workflow

  1. Add a step and choose the WooCommerce connector.
  2. Pick the Batch Product Categories action (under Product categories).
  3. Fill in the fields below, then reference the result from later steps as {{batchProductCategories.response.data}}.

Request

Request body

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

createarray<object>
idinteger

Unique identifier for the resource.

namestringrequired

Category name.

slugstring

An alphanumeric identifier for the resource unique to its type.

parentinteger

The ID for the parent of the resource.

descriptionstring

HTML description of the resource.

displaystring

Category archive display type.

One ofdefaultproductssubcategoriesbothDefault "default"

imageobject8 fields
menu_orderinteger

Menu order, used to custom sort the resource.

countinteger

Number of published products for the resource.

updatearray<object>
idinteger

Unique identifier for the resource.

namestringrequired

Category name.

slugstring

An alphanumeric identifier for the resource unique to its type.

parentinteger

The ID for the parent of the resource.

descriptionstring

HTML description of the resource.

displaystring

Category archive display type.

One ofdefaultproductssubcategoriesbothDefault "default"

imageobject8 fields
menu_orderinteger

Menu order, used to custom sort the resource.

countinteger

Number of published products for the resource.

deletearray<integer>
json
{
  "create": [
    {
      "name": "string",
      "id": 0,
      "slug": "string",
      "parent": 0,
      "description": "string",
      "display": "default",
      "image": {
        "id": 0,
        "date_created": "2025-01-01T00:00:00Z",
        "date_created_gmt": "2025-01-01T00:00:00Z",
        "date_modified": "2025-01-01T00:00:00Z",
        "date_modified_gmt": "2025-01-01T00:00:00Z",
        "src": "string",
        "name": "string",
        "alt": "string"
      },
      "menu_order": 0,
      "count": 0
    }
  ],
  "update": [
    {
      "name": "string",
      "id": 0,
      "slug": "string",
      "parent": 0,
      "description": "string",
      "display": "default",
      "image": {
        "id": 0,
        "date_created": "2025-01-01T00:00:00Z",
        "date_created_gmt": "2025-01-01T00:00:00Z",
        "date_modified": "2025-01-01T00:00:00Z",
        "date_modified_gmt": "2025-01-01T00:00:00Z",
        "src": "string",
        "name": "string",
        "alt": "string"
      },
      "menu_order": 0,
      "count": 0
    }
  ],
  "delete": [
    0
  ]
}

Response

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

createarray<object>
idinteger

Unique identifier for the resource.

namestringrequired

Category name.

slugstring

An alphanumeric identifier for the resource unique to its type.

parentinteger

The ID for the parent of the resource.

descriptionstring

HTML description of the resource.

displaystring

Category archive display type.

One ofdefaultproductssubcategoriesbothDefault "default"

imageobject8 fields
menu_orderinteger

Menu order, used to custom sort the resource.

countinteger

Number of published products for the resource.

updatearray<object>
idinteger

Unique identifier for the resource.

namestringrequired

Category name.

slugstring

An alphanumeric identifier for the resource unique to its type.

parentinteger

The ID for the parent of the resource.

descriptionstring

HTML description of the resource.

displaystring

Category archive display type.

One ofdefaultproductssubcategoriesbothDefault "default"

imageobject8 fields
menu_orderinteger

Menu order, used to custom sort the resource.

countinteger

Number of published products for the resource.

deletearray<object>
idinteger

Unique identifier for the resource.

namestringrequired

Category name.

slugstring

An alphanumeric identifier for the resource unique to its type.

parentinteger

The ID for the parent of the resource.

descriptionstring

HTML description of the resource.

displaystring

Category archive display type.

One ofdefaultproductssubcategoriesbothDefault "default"

imageobject8 fields
menu_orderinteger

Menu order, used to custom sort the resource.

countinteger

Number of published products for the resource.

json
{
  "create": [
    {
      "name": "string",
      "id": 0,
      "slug": "string",
      "parent": 0,
      "description": "string",
      "display": "default",
      "image": {
        "id": 0,
        "date_created": "2025-01-01T00:00:00Z",
        "date_created_gmt": "2025-01-01T00:00:00Z",
        "date_modified": "2025-01-01T00:00:00Z",
        "date_modified_gmt": "2025-01-01T00:00:00Z",
        "src": "string",
        "name": "string",
        "alt": "string"
      },
      "menu_order": 0,
      "count": 0
    }
  ],
  "update": [
    {
      "name": "string",
      "id": 0,
      "slug": "string",
      "parent": 0,
      "description": "string",
      "display": "default",
      "image": {
        "id": 0,
        "date_created": "2025-01-01T00:00:00Z",
        "date_created_gmt": "2025-01-01T00:00:00Z",
        "date_modified": "2025-01-01T00:00:00Z",
        "date_modified_gmt": "2025-01-01T00:00:00Z",
        "src": "string",
        "name": "string",
        "alt": "string"
      },
      "menu_order": 0,
      "count": 0
    }
  ],
  "delete": [
    {
      "name": "string",
      "id": 0,
      "slug": "string",
      "parent": 0,
      "description": "string",
      "display": "default",
      "image": {
        "id": 0,
        "date_created": "2025-01-01T00:00:00Z",
        "date_created_gmt": "2025-01-01T00:00:00Z",
        "date_modified": "2025-01-01T00:00:00Z",
        "date_modified_gmt": "2025-01-01T00:00:00Z",
        "src": "string",
        "name": "string",
        "alt": "string"
      },
      "menu_order": 0,
      "count": 0
    }
  ]
}

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