Home
WooCommerce
Woocommerce Store Api Store Product Category Structure
Woocommerce Store Api Store Product Category Structure
A product category for storefront display.
Type: object
Properties: 8
eCommerce Open Source Orders Products WordPress
StoreProductCategory is a JSON Structure definition published by WooCommerce, describing 8 properties. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.
Properties
id
name
slug
description
parent
count
link
image
Meta-schema: https://json-structure.org/meta/core/v0/#
JSON Structure
{
"$schema": "https://json-structure.org/meta/core/v0/#",
"$id": "https://raw.githubusercontent.com/api-evangelist/woocommerce/refs/heads/main/json-structure/woocommerce-store-api-store-product-category-structure.json",
"name": "StoreProductCategory",
"description": "A product category for storefront display.",
"type": "object",
"properties": {
"id": {
"type": "int32",
"description": "Category unique identifier.",
"example": 1
},
"name": {
"type": "string",
"description": "Category display name.",
"example": "Example Name"
},
"slug": {
"type": "string",
"description": "URL-friendly category slug.",
"example": "string-value"
},
"description": {
"type": "string",
"description": "Category description.",
"example": "A sample description"
},
"parent": {
"type": "int32",
"description": "Parent category ID (0 for root categories).",
"example": 1
},
"count": {
"type": "int32",
"description": "Number of products in this category.",
"example": 1
},
"link": {
"type": "uri",
"description": "Category archive URL.",
"example": "https://example.com/path"
},
"image": {
"type": "object",
"description": "Product image with thumbnail variants.",
"properties": {
"id": {
"type": "int32",
"description": "Image attachment ID.",
"example": 1
},
"src": {
"type": "uri",
"description": "Full-size image URL.",
"example": "https://example.com/path"
},
"thumbnail": {
"type": "uri",
"description": "Thumbnail image URL.",
"example": "https://example.com/path"
},
"srcset": {
"type": "string",
"description": "Responsive image srcset attribute value.",
"example": "string-value"
},
"sizes": {
"type": "string",
"description": "Responsive image sizes attribute value.",
"example": "string-value"
},
"name": {
"type": "string",
"description": "Image file name.",
"example": "Example Name"
},
"alt": {
"type": "string",
"description": "Image alternative text.",
"example": "string-value"
}
}
}
}
}