Woocommerce Rest Api Product Variation Structure
A variation of a variable product with its own pricing and stock.
ProductVariation is a JSON Structure definition published by WooCommerce, describing 13 properties. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.
Properties
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-rest-api-product-variation-structure.json",
"name": "ProductVariation",
"description": "A variation of a variable product with its own pricing and stock.",
"type": "object",
"properties": {
"id": {
"type": "int32",
"description": "Variation unique identifier.",
"example": 1
},
"sku": {
"type": "string",
"description": "Stock-keeping unit for this variation.",
"example": "string-value"
},
"price": {
"type": "string",
"description": "Current price as a decimal string.",
"example": "string-value"
},
"regular_price": {
"type": "string",
"description": "Regular price as a decimal string.",
"example": "string-value"
},
"sale_price": {
"type": "string",
"description": "Sale price as a decimal string.",
"example": "string-value"
},
"on_sale": {
"type": "boolean",
"description": "Whether the variation is on sale.",
"example": true
},
"status": {
"type": "string",
"description": "Variation status.",
"enum": [
"draft",
"pending",
"private",
"publish"
],
"example": "draft"
},
"manage_stock": {
"type": "boolean",
"description": "Whether stock is managed for this variation.",
"example": true
},
"stock_quantity": {
"type": "int32",
"description": "Stock quantity for this variation.",
"nullable": true,
"example": 1
},
"stock_status": {
"type": "string",
"description": "Stock status.",
"enum": [
"instock",
"outofstock",
"onbackorder"
],
"example": "instock"
},
"image": {
"type": "object",
"description": "An image associated with a product.",
"properties": {
"id": {
"type": "int32",
"description": "Image unique identifier.",
"example": 1
},
"src": {
"type": "uri",
"description": "Image URL.",
"example": "https://example.com/path"
},
"name": {
"type": "string",
"description": "Image name.",
"example": "Example Name"
},
"alt": {
"type": "string",
"description": "Image alternative text.",
"example": "string-value"
}
}
},
"attributes": {
"type": "array",
"description": "Specific attribute values that define this variation.",
"items": {
"type": "object",
"properties": {
"id": {
"type": "int32",
"description": "Attribute ID."
},
"name": {
"type": "string",
"description": "Attribute name."
},
"option": {
"type": "string",
"description": "Selected option value for this variation."
}
}
},
"example": [
{
"id": 1,
"name": "Example Name",
"option": "string-value"
}
]
},
"meta_data": {
"type": "array",
"description": "Custom metadata for this variation.",
"items": {
"type": "object",
"description": "Custom metadata key-value entry.",
"properties": {
"id": {
"type": "int32",
"description": "Metadata unique identifier.",
"example": 1
},
"key": {
"type": "string",
"description": "Metadata key.",
"example": "string-value"
},
"value": {
"type": "string",
"description": "Metadata value.",
"example": "string-value"
}
}
},
"example": [
"string-value"
]
}
}
}
Work with this as data
Every JSON Structure here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for json structure
4 MCP tools reach this
find_json_structuresBrowse and filter every JSON Structure in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
curl "https://apis.io/api/v1/json-structures/woocommerce-rest-api-product-variation-structure"
curl "https://apis.io/api/v1/json-structures?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.