Last Updated: Jan 22, 2026

Open workflow in n8n


Executive Summary

This flow synchronizes the master product catalog from Plytix PIM to Google Sheets. It fetches all product attributes (including dimensions, costs, and lifecycle status), resolves category IDs into readable names, filters for active “ML” products, and performs a complete refresh of the destination sheet.

INFO

Plytix PIM n8n Google Sheets
Trigger: Every Monday at 02:00


Data Source

Source: Plytix PIM

Overview

The data is sourced from the Plytix PIM API via standard HTTP requests. The flow utilizes two specific endpoints to gather product data and metadata.

Data Sources

Where data is sourced from

  • POST /api/v1/categories/product/search
    • Purpose: Fetches a complete list of categories to create a lookup map for ID-to-Name conversion.
  • POST /api/v1/products/search
    • Purpose: Fetches the primary product dataset.

Results Output

Key attributes output from the API

  • sku
  • attributes.master (Master MPN)
  • attributes.ml_cost (FOB Cost)
  • categories (List of IDs)
  • attributes.cbm & attributes.cbm_box_2 (Dimensions)
  • attributes.product_family_
  • attributes.lifecycle_status_
  • attributes.msrp
  • attributes.map_price

Pagination Strategy

How the system handles large datasets

  • The Get Products node uses a cursor-based pagination strategy.
  • Batch Size: 100 records per request.
  • Loop Condition: The node continues fetching pages until the response contains fewer than 100 items, ensuring the entire catalog is retrieved.

Data Manipulation (n8n Workflow)

Overview

This workflow authenticates with Plytix, performs a “Reference Data” fetch for categories, extracts the full product catalog, and then processes the data linearly. The destination sheet is completely cleared before the new dataset is loaded (“Truncate and Load” strategy).

Trigger: Every Monday at 02:00

Logic Flow

The workflow runs on a Weekly Schedule to refresh the “Plytix Data” tab in the Master Summary sheet.

  1. Authentication: The flow requests a Bearer Token from auth.plytix.com.
  2. Metadata Fetch: The flow requests all product categories immediately to build a reference object in memory.
  3. Extraction: The flow iterates through the Get Products endpoint to download the full catalog.
  4. Transformation:
    • Mapping: The list of products is split into individual items.
    • Enrichment: Category IDs on the product are matched against the “Metadata” fetch to resolve readable names (e.g., converting ID:123 to "Stool").
    • Filtering: The dataset is reduced to relevant items only.
    • Sorting: The final list is sorted by SKU (Ascending).
  5. Loading:
    • The destination sheet is Cleared (all rows deleted).
    • The transformed and sorted data is Appended to the sheet.

Transformation Rules

The Code and Edit Fields nodes perform specific cleaning and business logic.

  • Category Resolution (Lookup Logic)
    • Plytix returns categories as an array of IDs.
    • The workflow filters the previously fetched “Categories” list to find matches and joins the names into a single comma-separated string (e.g., "Living Room, Chairs").
  • SKU Filtering
    • Condition: SKU starts with ML
    • Purpose: Strictly enforces that only Maven Lane products are synced, excluding virtual bundles or other vendor prefixes.
  • Type Casting
    • Costs (ml_cost), Dimensions (cbm), and Prices (map_price) are explicitly cast to Numbers to ensure Google Sheets treats them as calculable values rather than text.

Data Destination

Destination: Google Sheets

Overview

The destination is the Master PO Summary Tool spreadsheet. Specifically, the data is written to the Plytix Data tab. This tab serves as a raw data ingestion point for other lookups in the workbook.