{
  "schemes": [
    "https"
  ],
  "swagger": "2.0",
  "info": {
    "description": "Products, variants, families, and catalog models.",
    "title": "Product API",
    "contact": {},
    "version": "1.0.0"
  },
  "host": "api.catazenta.com",
  "basePath": "/v1",
  "paths": {
    "/product-families": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get a paginated list of product families with optional filters",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "List product families",
        "parameters": [
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 10,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Filter by code (exact match)",
            "name": "code",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Filter by name (partial match)",
            "name": "name",
            "in": "query"
          },
          {
            "enum": [
              "enabled",
              "disabled"
            ],
            "type": "string",
            "description": "Filter by status",
            "name": "status",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Search across code and name",
            "name": "search",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Product families retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyListDataResponse"
            }
          },
          "400": {
            "description": "Invalid parameters",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Create a new product family with the provided details",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "Create a new product family",
        "parameters": [
          {
            "description": "Product family details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/CreateProductFamilyRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Product family created successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "409": {
            "description": "Product family with same code already exists",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{id}": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get details of a specific product family by ID",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "Get product family details",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Product family retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyDataResponse"
            }
          },
          "400": {
            "description": "Invalid ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Delete a product family by ID",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "Delete a product family",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Product family deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Update an existing product family's details",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "Update a product family",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Updated product family details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UpdateProductFamilyRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Product family updated successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{id}/status": {
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Change the status of a product family (active/inactive)",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Families"
        ],
        "summary": "Change product family status",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Status change request",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/ChangeProductFamilyStatusRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Product family status changed successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{id}/translations": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Retrieve all localized translations for a specific product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Translations"
        ],
        "summary": "Get all translations for a product family",
        "parameters": [
          {
            "type": "string",
            "example": "1",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "List of product family translations",
            "schema": {
              "$ref": "#/definitions/ProductFamilyTranslationListDataResponse"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal Server Error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "PATCH: Update multiple translations for a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Translations"
        ],
        "summary": "Update product family translations",
        "parameters": [
          {
            "type": "string",
            "example": "1",
            "description": "Product Family ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Translations data",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UpdateProductFamilyTranslationsRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Translations updated successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyTranslationListDataResponse"
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Not Found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal Server Error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{productFamilyId}/attributes": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get attributes for a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Attributes"
        ],
        "summary": "List product family attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 20,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Search by attribute name",
            "name": "search",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Attributes retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductFamilyAttributeListDataResponse"
            }
          },
          "400": {
            "description": "Invalid product family ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Bulk create attributes for a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Attributes"
        ],
        "summary": "Create product family attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "description": "Attributes to create",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/BulkProductFamilyAttributeRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Attributes created successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Partially update attributes for a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Attributes"
        ],
        "summary": "Partially update product family attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "description": "Attributes to partially update",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/BulkProductFamilyAttributeRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Attributes partially updated successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{productFamilyId}/attributes/{attributeId}": {
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Remove a specific attribute from a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Family Attributes"
        ],
        "summary": "Delete a product family attribute",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Attribute ID",
            "name": "attributeId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Attribute deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Attribute not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{productFamilyId}/variant-families": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get all variant families for a specific product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Families"
        ],
        "summary": "List variant families",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Variant families retrieved successfully",
            "schema": {
              "$ref": "#/definitions/VariantFamilyListDataResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Create a new variant family for a product family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Families"
        ],
        "summary": "Create a variant family",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "description": "Variant family data",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/CreateVariantFamilyRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Variant family created successfully",
            "schema": {
              "$ref": "#/definitions/VariantFamilyDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "409": {
            "description": "Variant family already exists",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{productFamilyId}/variant-families/{variantFamilyId}": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get detailed information about a specific variant family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Families"
        ],
        "summary": "Get variant family by ID",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant Family ID",
            "name": "variantFamilyId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Variant family retrieved successfully",
            "schema": {
              "$ref": "#/definitions/VariantFamilyDataResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Soft delete a variant family by ID",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Families"
        ],
        "summary": "Delete a variant family",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant Family ID",
            "name": "variantFamilyId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Variant family deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/product-families/{productFamilyId}/variant-families/{variantFamilyId}/translations": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Retrieve all localized translations for a specific variant family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Family Translations"
        ],
        "summary": "Get all translations for a variant family",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant Family ID",
            "name": "variantFamilyId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "List of variant family translations",
            "schema": {
              "$ref": "#/definitions/VariantFamilyTranslationListDataResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "PATCH: Create or update multiple translations for a variant family",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Family Translations"
        ],
        "summary": "Update variant family translations",
        "parameters": [
          {
            "type": "string",
            "description": "Product Family ID",
            "name": "productFamilyId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant Family ID",
            "name": "variantFamilyId",
            "in": "path",
            "required": true
          },
          {
            "description": "Translations data",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UpdateVariantFamilyTranslationsRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Translations updated successfully",
            "schema": {
              "$ref": "#/definitions/VariantFamilyTranslationListDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant family not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get a paginated list of products with optional filters",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "List products",
        "parameters": [
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 10,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Filter by code (partial match)",
            "name": "code",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Filter by name (partial match)",
            "name": "name",
            "in": "query"
          },
          {
            "enum": [
              "enabled",
              "disabled"
            ],
            "type": "string",
            "description": "Filter by status",
            "name": "status",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Filter by product family ID",
            "name": "product_family_id",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Search across code and name",
            "name": "search",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Products retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductListDataResponse"
            }
          },
          "400": {
            "description": "Invalid parameters",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Create a new product with the provided details",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Create a new product",
        "parameters": [
          {
            "description": "Product details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/CreateProductRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Product created successfully",
            "schema": {
              "$ref": "#/definitions/ProductDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "409": {
            "description": "Product with same code already exists",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get detailed information about a specific product",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Get product by ID",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Product retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductDataResponse"
            }
          },
          "400": {
            "description": "Invalid product ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Delete a product by ID",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Delete a product",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Product deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Update an existing product's details",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Update a product",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Updated product details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UpdateProductRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Product updated successfully",
            "schema": {
              "$ref": "#/definitions/ProductDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/clone": {
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Clone a product with a new code, copying product data except variants and variant attributes",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Clone a product",
        "parameters": [
          {
            "type": "string",
            "description": "Source Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Clone payload",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/CloneProductRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Product cloned successfully",
            "schema": {
              "$ref": "#/definitions/ProductDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Source product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "409": {
            "description": "Product with same code already exists",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/revisions": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Paginated version history for a product (newest first)",
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Revisions"
        ],
        "summary": "List product revisions",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 20,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Product revisions retrieved successfully",
            "schema": {
              "$ref": "#/definitions/RevisionListDataResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/revisions/current": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Full snapshot for the product's latest revision via latest_revision_id pointer",
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Revisions"
        ],
        "summary": "Get current product revision",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Current product revision retrieved successfully",
            "schema": {
              "$ref": "#/definitions/RevisionDataResponse"
            }
          },
          "404": {
            "description": "Product not found or no revisions yet",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/revisions/{revisionId}": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Full snapshot for a single revision",
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Revisions"
        ],
        "summary": "Get product revision",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Revision ID",
            "name": "revisionId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Product revision retrieved successfully",
            "schema": {
              "$ref": "#/definitions/RevisionDataResponse"
            }
          },
          "404": {
            "description": "Product or revision not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/revisions/{revisionId}/restore": {
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Restore catalog state from a revision; creates a new revision with change_source revert",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Revisions"
        ],
        "summary": "Restore product revision",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Revision ID",
            "name": "revisionId",
            "in": "path",
            "required": true
          },
          {
            "description": "Optional optimistic lock and comment",
            "name": "body",
            "in": "body",
            "schema": {
              "$ref": "#/definitions/RestoreRevisionRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Product restored successfully",
            "schema": {
              "$ref": "#/definitions/RevisionDataResponse"
            }
          },
          "409": {
            "description": "Stale revision (product changed since read)",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{id}/status": {
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Change the status of a product (draft/in_review/approved/archived) with variant cascade",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Products"
        ],
        "summary": "Change product status",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Status change request",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/ChangeProductStatusRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Product status changed successfully",
            "schema": {
              "$ref": "#/definitions/ProductDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/attributes": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get all attributes for a specific product with attribute metadata",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Attributes"
        ],
        "summary": "List product attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 20,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Product attributes retrieved successfully",
            "schema": {
              "$ref": "#/definitions/ProductAttributeListDataResponse"
            }
          },
          "400": {
            "description": "Invalid product ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Bulk create or update attributes for a product. Each value uses the standardized payload:\ntext/number/boolean: {\"value\": \"some text\"}  |  select: {\"value\": \"option_code\"}",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Attributes"
        ],
        "summary": "Create or update product attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "description": "Product attributes",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/CreateProductAttributeRequest"
              }
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Attributes created/updated successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Update specific fields of product attributes without replacing entire attribute set.\nEach value uses the standardized payload: text/number/boolean: {\"value\": \"some text\"}  |  select: {\"value\": \"option_code\"}",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Attributes"
        ],
        "summary": "Partially update product attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "description": "Product attributes to partially update",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/UpdateProductAttributeRequest"
              }
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Attributes partially updated successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/attributes/{id}": {
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Delete a specific attribute from a product",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Product Attributes"
        ],
        "summary": "Delete a product attribute",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Product Attribute ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Attribute deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Attribute not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/variants": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get all variants for a specific product",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "List product variants",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Variants retrieved successfully",
            "schema": {
              "$ref": "#/definitions/VariantListDataResponse"
            }
          },
          "400": {
            "description": "Invalid product ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Create a new variant for a product with attributes",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "Create a new variant",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "description": "Variant details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/CreateVariantRequest"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Variant created successfully",
            "schema": {
              "$ref": "#/definitions/VariantDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Product not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/variants/{id}": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get detailed information about a specific variant",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "Get variant by ID",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Variant retrieved successfully",
            "schema": {
              "$ref": "#/definitions/VariantDataResponse"
            }
          },
          "400": {
            "description": "Invalid variant ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Delete a variant by ID",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "Delete a variant",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Variant deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Update an existing variant's details",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "Update a variant",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Updated variant details",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/UpdateVariantRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Variant updated successfully",
            "schema": {
              "$ref": "#/definitions/VariantDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/variants/{id}/status": {
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Change the status of a variant (draft/in_review/approved/archived)",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variants"
        ],
        "summary": "Change variant status",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "description": "Status change request",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "$ref": "#/definitions/ChangeVariantStatusRequest"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Variant status changed successfully",
            "schema": {
              "$ref": "#/definitions/VariantDataResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/variants/{variantId}/attributes": {
      "get": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Get all attributes for a specific variant with attribute metadata",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Attributes"
        ],
        "summary": "List variant attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "variantId",
            "in": "path",
            "required": true
          },
          {
            "minimum": 1,
            "type": "integer",
            "default": 1,
            "description": "Page number",
            "name": "page",
            "in": "query"
          },
          {
            "maximum": 100,
            "minimum": 1,
            "type": "integer",
            "default": 20,
            "description": "Items per page",
            "name": "page_size",
            "in": "query"
          },
          {
            "type": "string",
            "description": "Search by attribute name",
            "name": "search",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Variant attributes retrieved successfully",
            "schema": {
              "$ref": "#/definitions/VariantAttributeListDataResponse"
            }
          },
          "400": {
            "description": "Invalid variant ID",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "post": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Bulk create or update attributes for a variant. Each value uses the standardized payload:\ntext/number/boolean: {\"value\": \"some text\"}  |  select: {\"value\": \"option_code\"}",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Attributes"
        ],
        "summary": "Create variant attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "variantId",
            "in": "path",
            "required": true
          },
          {
            "description": "Variant attributes",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/CreateVariantAttributeRequest"
              }
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Attributes created successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      },
      "patch": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Bulk update or create attributes for a variant (PATCH semantics - only modifies provided attributes).\nEach value uses the standardized payload: text/number/boolean: {\"value\": \"some text\"}  |  select: {\"value\": \"option_code\"}",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Attributes"
        ],
        "summary": "Update variant attributes",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "variantId",
            "in": "path",
            "required": true
          },
          {
            "description": "Variant attributes to update",
            "name": "request",
            "in": "body",
            "required": true,
            "schema": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/CreateVariantAttributeRequest"
              }
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Attributes updated successfully",
            "schema": {
              "$ref": "#/definitions/response.SuccessResponse"
            }
          },
          "400": {
            "description": "Invalid request body or validation error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Variant not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    },
    "/products/{productId}/variants/{variantId}/attributes/{id}": {
      "delete": {
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "description": "Delete a specific attribute from a variant",
        "consumes": [
          "application/json"
        ],
        "produces": [
          "application/json"
        ],
        "tags": [
          "Variant Attributes"
        ],
        "summary": "Delete a variant attribute",
        "parameters": [
          {
            "type": "string",
            "description": "Product ID",
            "name": "productId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant ID",
            "name": "variantId",
            "in": "path",
            "required": true
          },
          {
            "type": "string",
            "description": "Variant Attribute ID",
            "name": "id",
            "in": "path",
            "required": true
          }
        ],
        "responses": {
          "204": {
            "description": "Attribute deleted successfully"
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "404": {
            "description": "Attribute not found",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": {
              "$ref": "#/definitions/response.ErrorResponse"
            }
          }
        }
      }
    }
  },
  "definitions": {
    "response.Error": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string"
        },
        "field": {
          "type": "string"
        },
        "message": {
          "type": "string"
        }
      }
    },
    "response.ErrorResponse": {
      "type": "object",
      "properties": {
        "errors": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/response.Error"
          }
        },
        "message": {
          "type": "string"
        },
        "success": {
          "type": "boolean"
        }
      }
    },
    "response.PaginationInfo": {
      "type": "object",
      "properties": {
        "has_next": {
          "type": "boolean"
        },
        "page": {
          "type": "integer"
        },
        "page_size": {
          "type": "integer"
        },
        "total_items": {
          "type": "integer"
        },
        "total_pages": {
          "type": "integer"
        }
      }
    },
    "response.SuccessResponse": {
      "type": "object",
      "properties": {
        "data": {},
        "success": {
          "type": "boolean"
        }
      }
    },
    "ProductAttributeSnapshot": {
      "type": "object",
      "properties": {
        "attribute_id": {
          "type": "string"
        },
        "uniqueness_hash": {
          "type": "integer"
        },
        "value": {
          "type": "array",
          "items": {
            "type": "integer"
          }
        }
      }
    },
    "ProductCoreSnapshot": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string"
        },
        "product_family_id": {
          "type": "string"
        },
        "product_type": {
          "type": "string"
        },
        "product_variant_family_id": {
          "type": "string"
        },
        "status": {
          "type": "string"
        }
      }
    },
    "ProductSnapshot": {
      "type": "object",
      "properties": {
        "category_ids": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "product": {
          "$ref": "#/definitions/ProductCoreSnapshot"
        },
        "product_attributes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductAttributeSnapshot"
          }
        },
        "variants": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantSnapshot"
          }
        },
        "version": {
          "type": "integer"
        }
      }
    },
    "VariantAttributeSnapshot": {
      "type": "object",
      "properties": {
        "attribute_id": {
          "type": "string"
        },
        "uniqueness_hash": {
          "type": "integer"
        },
        "value": {
          "type": "array",
          "items": {
            "type": "integer"
          }
        }
      }
    },
    "VariantSnapshot": {
      "type": "object",
      "properties": {
        "attributes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantAttributeSnapshot"
          }
        },
        "code": {
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "is_default": {
          "type": "boolean"
        },
        "status": {
          "type": "string"
        }
      }
    },
    "ActorSummary": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "ActorSummary2": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "CategorySummary": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "mens-clothing"
        },
        "id": {
          "type": "string",
          "example": "10"
        },
        "name": {
          "type": "string",
          "example": "Men's Clothing"
        }
      }
    },
    "ChangeProductStatusRequest": {
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "type": "string",
          "enum": [
            "draft",
            "in_review",
            "approved",
            "archived"
          ],
          "example": "approved"
        }
      }
    },
    "CloneProductRequest": {
      "type": "object",
      "required": [
        "code"
      ],
      "properties": {
        "code": {
          "type": "string",
          "maxLength": 128,
          "example": "TSHIRT-BLU-001-COPY"
        }
      }
    },
    "CreateProductRequest": {
      "type": "object",
      "required": [
        "code",
        "product_family_id"
      ],
      "properties": {
        "category_ids": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "example": [
            "10",
            "25",
            "42"
          ]
        },
        "code": {
          "type": "string",
          "maxLength": 128,
          "example": "TSHIRT-BLU-001"
        },
        "product_family_id": {
          "type": "string",
          "example": "5"
        },
        "product_type": {
          "type": "string",
          "maxLength": 50,
          "example": "configurable"
        },
        "variant_family_id": {
          "type": "string",
          "example": "7"
        }
      }
    },
    "DisplayAttributeInfo": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "name"
        },
        "id": {
          "type": "string",
          "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
        },
        "name": {
          "type": "string",
          "example": "Product Name"
        }
      }
    },
    "DisplayAttributes": {
      "type": "object",
      "properties": {
        "image": {
          "$ref": "#/definitions/DisplayAttributeInfo"
        },
        "name": {
          "$ref": "#/definitions/DisplayAttributeInfo"
        }
      }
    },
    "ProductDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilySummary": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "APPAREL"
        },
        "id": {
          "type": "string",
          "example": "5"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        }
      }
    },
    "ProductListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductListItem": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "TSHIRT-BLU-001"
        },
        "completeness": {
          "type": "number",
          "example": 85
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-15T10:30:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary2"
        },
        "id": {
          "type": "string",
          "example": "1001"
        },
        "media_id": {
          "type": "string",
          "example": "550e8400-e29b-41d4-a716-446655440000"
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T14:45:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary2"
        },
        "name": {
          "type": "string",
          "example": "Blue Cotton T-Shirt"
        },
        "product_family": {
          "$ref": "#/definitions/ProductFamilySummary"
        },
        "product_type": {
          "type": "string",
          "example": "configurable"
        },
        "status": {
          "type": "string",
          "example": "enabled"
        },
        "thumbnail": {
          "type": "string",
          "example": "https://cdn.catazenta.com/images/tshirt-blue.jpg"
        },
        "variant_count": {
          "type": "integer",
          "example": 5
        }
      }
    },
    "ProductListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductListItem"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "ProductResponse": {
      "type": "object",
      "properties": {
        "categories": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/CategorySummary"
          }
        },
        "code": {
          "type": "string",
          "example": "TSHIRT-BLU-001"
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-15T10:30:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary2"
        },
        "display_attributes": {
          "$ref": "#/definitions/DisplayAttributes"
        },
        "id": {
          "type": "string",
          "example": "1001"
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T14:45:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary2"
        },
        "product_family": {
          "$ref": "#/definitions/ProductFamilySummary"
        },
        "product_type": {
          "type": "string",
          "example": "configurable"
        },
        "status": {
          "type": "string",
          "example": "enabled"
        },
        "variant_family": {
          "$ref": "#/definitions/VariantFamilySummary"
        }
      }
    },
    "UpdateProductRequest": {
      "type": "object",
      "properties": {
        "category_ids": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "example": [
            "10",
            "25"
          ]
        }
      }
    },
    "VariantFamilySummary": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "COLOR-SIZE"
        },
        "id": {
          "type": "string",
          "example": "7"
        },
        "name": {
          "type": "string",
          "example": "Color & Size"
        }
      }
    },
    "ActorSummary3": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "AttributeGroupSummary": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "GENERAL"
        },
        "id": {
          "type": "string",
          "example": "3"
        },
        "name": {
          "type": "string",
          "example": "General Information"
        }
      }
    },
    "ChannelSetting": {
      "type": "object",
      "properties": {
        "channel_code": {
          "type": "string",
          "example": "amazon"
        },
        "enabled": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "CreateProductAttributeRequest": {
      "type": "object",
      "required": [
        "attribute_id"
      ],
      "properties": {
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ScopedValue"
          }
        }
      }
    },
    "ProductAttributeListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductAttributeListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductAttributeListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductAttributeResponse"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "ProductAttributeResponse": {
      "type": "object",
      "properties": {
        "attribute_code": {
          "type": "string",
          "example": "color"
        },
        "attribute_config": {
          "type": "object"
        },
        "attribute_group": {
          "$ref": "#/definitions/AttributeGroupSummary"
        },
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "attribute_name": {
          "type": "string",
          "example": "Color"
        },
        "attribute_translations": {
          "type": "object"
        },
        "attribute_type": {
          "type": "string",
          "example": "select"
        },
        "channel_settings": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ChannelSetting"
          }
        },
        "is_custom": {
          "type": "boolean",
          "example": false
        },
        "is_mandatory": {
          "type": "boolean",
          "example": true
        },
        "is_overridable": {
          "type": "boolean",
          "example": true
        },
        "is_unique": {
          "type": "boolean",
          "example": false
        },
        "is_variant_axis": {
          "type": "boolean",
          "example": true
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T14:45:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary3"
        },
        "value_per_channel": {
          "type": "boolean",
          "example": false
        },
        "value_per_locale": {
          "type": "boolean",
          "example": true
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ScopedValue"
          }
        }
      }
    },
    "ScopedValue": {
      "type": "object",
      "properties": {
        "channel": {
          "type": "string",
          "example": "$default"
        },
        "data": {
          "type": "object"
        },
        "locale": {
          "type": "string",
          "example": "$default"
        }
      }
    },
    "UpdateProductAttributeRequest": {
      "type": "object",
      "required": [
        "attribute_id"
      ],
      "properties": {
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ScopedValue"
          }
        }
      }
    },
    "ActorSummary4": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "ChangeProductFamilyStatusRequest": {
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "type": "string",
          "enum": [
            "active",
            "inactive"
          ],
          "example": "inactive"
        }
      }
    },
    "CreateProductFamilyRequest": {
      "type": "object",
      "required": [
        "code",
        "name"
      ],
      "properties": {
        "code": {
          "type": "string",
          "example": "APPAREL"
        },
        "description": {
          "type": "string",
          "example": "Clothing and fashion products including shirts, pants, dresses"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        }
      }
    },
    "DisplayAttributeInfo2": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "name"
        },
        "id": {
          "type": "string",
          "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
        },
        "name": {
          "type": "string",
          "example": "Product Name"
        }
      }
    },
    "DisplayAttributesResponse": {
      "type": "object",
      "properties": {
        "image": {
          "$ref": "#/definitions/DisplayAttributeInfo2"
        },
        "name": {
          "$ref": "#/definitions/DisplayAttributeInfo2"
        }
      }
    },
    "ProductFamilyDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductFamilyResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductFamilyListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyListItemResponse": {
      "type": "object",
      "properties": {
        "attribute_count": {
          "type": "integer",
          "example": 15
        },
        "code": {
          "type": "string",
          "example": "APPAREL"
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-10T09:00:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary4"
        },
        "id": {
          "type": "string",
          "example": "5"
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-15T11:30:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary4"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        },
        "product_count": {
          "type": "integer",
          "example": 156
        },
        "status": {
          "type": "string",
          "example": "active"
        }
      }
    },
    "ProductFamilyListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductFamilyListItemResponse"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "ProductFamilyResponse": {
      "type": "object",
      "properties": {
        "attribute_count": {
          "type": "integer",
          "example": 15
        },
        "code": {
          "type": "string",
          "example": "APPAREL"
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-10T09:00:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary4"
        },
        "description": {
          "type": "string",
          "example": "Clothing and fashion products"
        },
        "display_attributes": {
          "$ref": "#/definitions/DisplayAttributesResponse"
        },
        "id": {
          "type": "string",
          "example": "5"
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-15T11:30:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary4"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        },
        "product_count": {
          "type": "integer",
          "example": 156
        },
        "status": {
          "type": "string",
          "example": "active"
        }
      }
    },
    "ProductFamilyTranslationInput": {
      "type": "object",
      "required": [
        "locale",
        "name"
      ],
      "properties": {
        "locale": {
          "type": "string",
          "maxLength": 10,
          "minLength": 2,
          "example": "en_US"
        },
        "name": {
          "type": "string",
          "maxLength": 255,
          "minLength": 1,
          "example": "Apparel"
        }
      }
    },
    "ProductFamilyTranslationListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductFamilyTranslationListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyTranslationListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductFamilyTranslationResponse"
          }
        }
      }
    },
    "ProductFamilyTranslationResponse": {
      "type": "object",
      "properties": {
        "created_at": {
          "type": "string",
          "example": "2026-01-18T10:30:00Z"
        },
        "locale": {
          "type": "string",
          "example": "en_US"
        },
        "modified_at": {
          "type": "string",
          "example": "2026-01-18T15:45:00Z"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        }
      }
    },
    "UpdateDisplayAttributes": {
      "type": "object",
      "properties": {
        "image_attribute_id": {
          "type": "string",
          "example": "b2c3d4e5-f6a7-8901-bcde-f12345678901"
        },
        "name_attribute_id": {
          "type": "string",
          "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
        }
      }
    },
    "UpdateProductFamilyRequest": {
      "type": "object",
      "properties": {
        "description": {
          "type": "string",
          "example": "Updated description for clothing category"
        },
        "display_attributes": {
          "$ref": "#/definitions/UpdateDisplayAttributes"
        },
        "name": {
          "type": "string",
          "example": "Clothing & Accessories"
        }
      }
    },
    "UpdateProductFamilyTranslationsRequest": {
      "type": "object",
      "required": [
        "translations"
      ],
      "properties": {
        "translations": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductFamilyTranslationInput"
          }
        }
      }
    },
    "ActorSummary5": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "AttributeGroupSummary2": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "GENERAL"
        },
        "id": {
          "type": "string",
          "example": "5"
        },
        "name": {
          "type": "string",
          "example": "General Information"
        }
      }
    },
    "BulkProductFamilyAttributeRequest": {
      "type": "object",
      "required": [
        "attributes"
      ],
      "properties": {
        "attributes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/CreateProductFamilyAttributeRequest"
          }
        }
      }
    },
    "ChannelBasicInfo": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "WEB"
        },
        "id": {
          "type": "string",
          "example": "1"
        },
        "name": {
          "type": "string",
          "example": "Web Store"
        }
      }
    },
    "CreateProductFamilyAttributeRequest": {
      "type": "object",
      "required": [
        "attribute_id"
      ],
      "properties": {
        "attribute_id": {
          "type": "string",
          "minLength": 1,
          "example": "15"
        },
        "channel_ids": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "example": [
            "1",
            "2",
            "5"
          ]
        },
        "is_mandatory": {
          "type": "boolean",
          "example": false
        },
        "is_overridable": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyAttributeListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/ProductFamilyAttributeListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyAttributeListItem": {
      "type": "object",
      "properties": {
        "attribute_code": {
          "type": "string",
          "example": "size"
        },
        "attribute_group": {
          "$ref": "#/definitions/AttributeGroupSummary2"
        },
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "attribute_name": {
          "type": "string",
          "example": "Size"
        },
        "attribute_type": {
          "type": "string",
          "example": "select"
        },
        "channels": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ChannelBasicInfo"
          }
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-15T10:00:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary5"
        },
        "is_mandatory": {
          "type": "boolean",
          "example": true
        },
        "is_overridable": {
          "type": "boolean",
          "example": true
        },
        "is_unique": {
          "type": "boolean",
          "example": false
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T15:30:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary5"
        },
        "value_per_channel": {
          "type": "boolean",
          "example": false
        },
        "value_per_locale": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "ProductFamilyAttributeListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ProductFamilyAttributeListItem"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "RestoreRevisionRequest": {
      "type": "object",
      "properties": {
        "comment": {
          "type": "string"
        },
        "expected_revision": {
          "type": "integer"
        }
      }
    },
    "RevisionDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/RevisionDetail"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "RevisionDetail": {
      "type": "object",
      "properties": {
        "change_source": {
          "type": "string"
        },
        "change_summary": {
          "type": "array",
          "items": {
            "type": "integer"
          }
        },
        "created_at": {
          "type": "string"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary"
        },
        "id": {
          "type": "string"
        },
        "restored_from_revision_id": {
          "type": "string"
        },
        "revision_number": {
          "type": "integer"
        },
        "snapshot": {
          "$ref": "#/definitions/ProductSnapshot"
        },
        "snapshot_schema_version": {
          "type": "integer"
        }
      }
    },
    "RevisionListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/RevisionListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "RevisionListItem": {
      "type": "object",
      "properties": {
        "change_source": {
          "type": "string"
        },
        "change_summary": {
          "type": "array",
          "items": {
            "type": "integer"
          }
        },
        "created_at": {
          "type": "string"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary"
        },
        "id": {
          "type": "string"
        },
        "restored_from_revision_id": {
          "type": "string"
        },
        "revision_number": {
          "type": "integer"
        }
      }
    },
    "RevisionListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/RevisionListItem"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "ActorSummary6": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "AxisValueInput": {
      "type": "object",
      "required": [
        "axis_code",
        "option_code"
      ],
      "properties": {
        "axis_code": {
          "type": "string",
          "example": "color"
        },
        "option_code": {
          "type": "string",
          "example": "blue"
        }
      }
    },
    "AxisValueOutput": {
      "type": "object",
      "properties": {
        "axis_code": {
          "type": "string",
          "example": "color"
        },
        "option_code": {
          "type": "string",
          "example": "blue"
        },
        "option_label": {
          "type": "string",
          "example": "Blue"
        }
      }
    },
    "CategorySummary2": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "mens-clothing"
        },
        "id": {
          "type": "string",
          "example": "10"
        },
        "name": {
          "type": "string",
          "example": "Men's Clothing"
        }
      }
    },
    "ChangeVariantStatusRequest": {
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "type": "string",
          "enum": [
            "draft",
            "in_review",
            "approved",
            "archived"
          ],
          "example": "approved"
        }
      }
    },
    "CreateVariantRequest": {
      "type": "object",
      "required": [
        "axis_values",
        "sku"
      ],
      "properties": {
        "axis_values": {
          "type": "array",
          "minItems": 1,
          "items": {
            "$ref": "#/definitions/AxisValueInput"
          }
        },
        "is_default": {
          "type": "boolean",
          "example": false
        },
        "sku": {
          "type": "string",
          "maxLength": 128,
          "example": "TSHIRT-BLU-S"
        }
      }
    },
    "DisplayAttributeInfo3": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "name"
        },
        "id": {
          "type": "string",
          "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
        },
        "name": {
          "type": "string",
          "example": "Product Name"
        }
      }
    },
    "DisplayAttributes2": {
      "type": "object",
      "properties": {
        "image": {
          "$ref": "#/definitions/DisplayAttributeInfo3"
        },
        "name": {
          "$ref": "#/definitions/DisplayAttributeInfo3"
        }
      }
    },
    "ProductFamilySummary2": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "APPAREL"
        },
        "id": {
          "type": "string",
          "example": "5"
        },
        "name": {
          "type": "string",
          "example": "Apparel"
        }
      }
    },
    "ProductSummary": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "example": "1001"
        },
        "name": {
          "type": "string",
          "example": "Blue Cotton T-Shirt"
        }
      }
    },
    "UpdateVariantRequest": {
      "type": "object",
      "properties": {
        "is_default": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantAxisValue": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "color"
        },
        "level": {
          "type": "integer",
          "example": 1
        },
        "name": {
          "type": "string",
          "example": "Color"
        },
        "value": {
          "type": "object"
        }
      }
    },
    "VariantDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantListItem": {
      "type": "object",
      "properties": {
        "axis_values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AxisValueOutput"
          }
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-15T11:00:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary6"
        },
        "id": {
          "type": "string",
          "example": "3001"
        },
        "is_default": {
          "type": "boolean",
          "example": false
        },
        "media_id": {
          "type": "string",
          "example": "550e8400-e29b-41d4-a716-446655440000"
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T16:30:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary6"
        },
        "name": {
          "type": "string",
          "example": "Blue T-Shirt S"
        },
        "sku": {
          "type": "string",
          "example": "TSHIRT-BLU-S"
        },
        "status": {
          "type": "string",
          "example": "enabled"
        },
        "thumbnail": {
          "type": "string",
          "example": "https://cdn.example.com/img.jpg"
        }
      }
    },
    "VariantListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantListItem"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "VariantResponse": {
      "type": "object",
      "properties": {
        "axis_values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AxisValueOutput"
          }
        },
        "categories": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/CategorySummary2"
          }
        },
        "created_at": {
          "type": "string",
          "example": "2024-01-15T11:00:00Z"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary6"
        },
        "display_attributes": {
          "$ref": "#/definitions/DisplayAttributes2"
        },
        "id": {
          "type": "string",
          "example": "3001"
        },
        "is_default": {
          "type": "boolean",
          "example": false
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T16:30:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary6"
        },
        "product": {
          "$ref": "#/definitions/ProductSummary"
        },
        "product_family": {
          "$ref": "#/definitions/ProductFamilySummary2"
        },
        "sku": {
          "type": "string",
          "example": "TSHIRT-BLU-S"
        },
        "status": {
          "type": "string",
          "example": "enabled"
        },
        "variant_axes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantAxisValue"
          }
        }
      }
    },
    "ActorSummary7": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      }
    },
    "AttributeGroupSummary3": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "example": "GENERAL"
        },
        "id": {
          "type": "string",
          "example": "3"
        },
        "name": {
          "type": "string",
          "example": "General Information"
        }
      }
    },
    "ChannelSetting2": {
      "type": "object",
      "properties": {
        "channel_code": {
          "type": "string",
          "example": "amazon"
        },
        "enabled": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "CreateVariantAttributeRequest": {
      "type": "object",
      "required": [
        "attribute_id"
      ],
      "properties": {
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ScopedValue2"
          }
        }
      }
    },
    "ScopedValue2": {
      "type": "object",
      "properties": {
        "channel": {
          "type": "string",
          "example": "$default"
        },
        "data": {
          "type": "object"
        },
        "locale": {
          "type": "string",
          "example": "$default"
        }
      }
    },
    "VariantAttributeListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantAttributeListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantAttributeListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantAttributeResponse"
          }
        },
        "pagination": {
          "$ref": "#/definitions/response.PaginationInfo"
        }
      }
    },
    "VariantAttributeResponse": {
      "type": "object",
      "properties": {
        "attribute_code": {
          "type": "string",
          "example": "color"
        },
        "attribute_config": {
          "type": "object"
        },
        "attribute_group": {
          "$ref": "#/definitions/AttributeGroupSummary3"
        },
        "attribute_id": {
          "type": "string",
          "example": "10"
        },
        "attribute_name": {
          "type": "string",
          "example": "Color"
        },
        "attribute_translations": {
          "type": "object"
        },
        "attribute_type": {
          "type": "string",
          "example": "select"
        },
        "channel_settings": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ChannelSetting2"
          }
        },
        "is_custom": {
          "type": "boolean",
          "example": false
        },
        "is_inherited": {
          "type": "boolean",
          "example": false
        },
        "is_mandatory": {
          "type": "boolean",
          "example": true
        },
        "is_overridable": {
          "type": "boolean",
          "example": false
        },
        "is_overridden": {
          "type": "boolean",
          "example": true
        },
        "is_unique": {
          "type": "boolean",
          "example": false
        },
        "is_variant_axis": {
          "type": "boolean",
          "example": true
        },
        "modified_at": {
          "type": "string",
          "example": "2024-01-20T17:00:00Z"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary7"
        },
        "value_per_channel": {
          "type": "boolean",
          "example": false
        },
        "value_per_locale": {
          "type": "boolean",
          "example": true
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ScopedValue2"
          }
        }
      }
    },
    "AttributeSummary": {
      "type": "object",
      "properties": {
        "code": {
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      }
    },
    "AxisInput": {
      "type": "object",
      "required": [
        "attribute_id",
        "level",
        "position"
      ],
      "properties": {
        "attribute_id": {
          "type": "string",
          "example": "019cfa6c-1ec5-7f1f-95dc-1fd025ff5c42"
        },
        "level": {
          "type": "integer",
          "maximum": 2,
          "minimum": 1,
          "example": 1
        },
        "position": {
          "type": "integer",
          "minimum": 1,
          "example": 1
        }
      }
    },
    "AxisResponse": {
      "type": "object",
      "properties": {
        "attribute": {
          "$ref": "#/definitions/AttributeSummary"
        },
        "id": {
          "type": "string"
        },
        "level": {
          "type": "integer"
        },
        "position": {
          "type": "integer"
        }
      }
    },
    "CreateVariantFamilyRequest": {
      "type": "object",
      "required": [
        "code",
        "name"
      ],
      "properties": {
        "axes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AxisInput"
          }
        },
        "code": {
          "type": "string",
          "maxLength": 100
        },
        "name": {
          "type": "string",
          "maxLength": 255,
          "minLength": 1
        }
      }
    },
    "UpdateVariantFamilyTranslationsRequest": {
      "type": "object",
      "required": [
        "translations"
      ],
      "properties": {
        "translations": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantFamilyTranslationInput"
          }
        }
      }
    },
    "VariantFamilyDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantFamilyResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantFamilyListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantFamilyListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantFamilyListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantFamilyResponse"
          }
        }
      }
    },
    "VariantFamilyResponse": {
      "type": "object",
      "properties": {
        "axes": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AxisResponse"
          }
        },
        "code": {
          "type": "string"
        },
        "created_at": {
          "type": "string"
        },
        "created_by": {
          "$ref": "#/definitions/ActorSummary"
        },
        "id": {
          "type": "string"
        },
        "modified_at": {
          "type": "string"
        },
        "modified_by": {
          "$ref": "#/definitions/ActorSummary"
        },
        "name": {
          "type": "string"
        },
        "product_family_id": {
          "type": "string"
        }
      }
    },
    "VariantFamilyTranslationInput": {
      "type": "object",
      "required": [
        "locale",
        "name"
      ],
      "properties": {
        "locale": {
          "type": "string",
          "maxLength": 10,
          "minLength": 2
        },
        "name": {
          "type": "string",
          "maxLength": 255,
          "minLength": 1
        }
      }
    },
    "VariantFamilyTranslationListDataResponse": {
      "type": "object",
      "properties": {
        "data": {
          "$ref": "#/definitions/VariantFamilyTranslationListResponse"
        },
        "success": {
          "type": "boolean",
          "example": true
        }
      }
    },
    "VariantFamilyTranslationListResponse": {
      "type": "object",
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/VariantFamilyTranslationResponse"
          }
        }
      }
    },
    "VariantFamilyTranslationResponse": {
      "type": "object",
      "properties": {
        "created_at": {
          "type": "string"
        },
        "locale": {
          "type": "string"
        },
        "modified_at": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      }
    }
  },
  "securityDefinitions": {
    "BearerAuth": {
      "type": "apiKey",
      "name": "Authorization",
      "in": "header"
    }
  }
}