Schema Documentation
productCategory
Description
A 0bject
Response
Returns a
ProductCategory
Arguments
Name | Description |
---|---|
id -
ID! | The globally unique identifier of the object. |
idType -
ProductCategoryIdType | Type of unique identifier to fetch by. Default is Global ID |
Example
Query
query productCategory(
$id: ID!,
$idType: ProductCategoryIdType
){
productCategory(
id: $id,
idType: $idType
){
ancestors {
...ProductCategoryToAncestorsProductCategoryConnectionFragment
}children {
...ProductCategoryToProductCategoryConnectionFragment
}contentNodes {
...ProductCategoryToContentNodeConnectionFragment
}countdatabaseIddescriptiondisplayenqueuedScripts {
...TermNodeToEnqueuedScriptConnectionFragment
}enqueuedStylesheets {
...TermNodeToEnqueuedStylesheetConnectionFragment
}idimage {
...MediaItemFragment
}isContentNodeisRestrictedisTermNodelinkmenuOrdernameparent {
...ProductCategoryToParentProductCategoryConnectionEdgeFragment
}parentDatabaseIdparentIdproductCategoryIdproducts {
...ProductCategoryToProductConnectionFragment
}seo {
...TaxonomySEOFragment
}slugtaxonomy {
...ProductCategoryToTaxonomyConnectionEdgeFragment
}taxonomyNametermGroupIdtermTaxonomyIduri
}
}
Variables
{"id":"4","idType":"DATABASE_ID"}
Response
{"data":{"productCategory":{"ancestors":ProductCategoryToAncestorsProductCategoryConnection,"children":ProductCategoryToProductCategoryConnection,"contentNodes":ProductCategoryToContentNodeConnection,"count":123,"databaseId":987,"description":"xyz789","display":"BOTH","enqueuedScripts":TermNodeToEnqueuedScriptConnection,"enqueuedStylesheets":TermNodeToEnqueuedStylesheetConnection,"id":"4","image":MediaItem,"isContentNode":true,"isRestricted":false,"isTermNode":true,"link":"xyz789","menuOrder":123,"name":"xyz789","parent":ProductCategoryToParentProductCategoryConnectionEdge,"parentDatabaseId":987,"parentId":"4","productCategoryId":987,"products":ProductCategoryToProductConnection,"seo":TaxonomySEO,"slug":"xyz789","taxonomy":ProductCategoryToTaxonomyConnectionEdge,"taxonomyName":"abc123","termGroupId":987,"termTaxonomyId":123,"uri":"abc123"}}}