Skip to main content

CreateCategoryInput

Input for creating a new product category.

Defines all the required and optional fields for creating a category in the system. Supports multilingual content, SEO metadata, and hierarchical organization. Validates input constraints and ensures data integrity.

input CreateCategoryInput {
name: [LocalizedStringInput!]!
description: [LocalizedStringInput!]!
shortDescription: [LocalizedStringInput!]!
parent: Int
defaultLanguage: String!
metadataTitles: [LocalizedStringInput!]
metadataDescriptions: [LocalizedStringInput!]
metadataKeywords: [LocalizedStringInput!]
metadataCanonicalUrls: [LocalizedStringInput!]
hidden: YesNo!
}

Fields

CreateCategoryInput.name ● [LocalizedStringInput!]! non-null input

Localized category names for display in different languages.

Collection of category names in various supported languages for international markets and multilingual storefronts. Falls back to the category's default language when specific language is not available.

CreateCategoryInput.description ● [LocalizedStringInput!]! non-null input

Detailed category description with rich content support.

Comprehensive category information including features, purpose, and context. Supports HTML formatting for rich content display and can be translated for multilingual catalogs. Used for category pages and detailed product organization.

CreateCategoryInput.shortDescription ● [LocalizedStringInput!]! non-null input

Brief category summary for listings and previews.

Concise category description suitable for navigation menus, category cards, and overview displays where space is limited. Supports HTML formatting and multilingual translation for consistent user experience.

CreateCategoryInput.parent ● Int scalar

Parent category in the hierarchical structure.

Reference to the immediate parent category in the category tree, enabling hierarchical navigation and breadcrumb generation. Null for root-level categories.

CreateCategoryInput.defaultLanguage ● String! non-null scalar

Primary language for category content.

The default language code used when localized content is not available in the requested language. Determines fallback behavior for multilingual category display.

CreateCategoryInput.metadataTitles ● [LocalizedStringInput!] list input

SEO-optimized page titles for search engines.

Localized title tag content used for search engine optimization and browser tab display. Should be concise, descriptive, and include relevant keywords for better search visibility. Recommended length: 50-60 characters.

CreateCategoryInput.metadataDescriptions ● [LocalizedStringInput!] list input

SEO meta descriptions for search engine results.

Localized meta description tag content that appears in search engine results pages. Should be compelling, informative, and within recommended character limits to improve click-through rates. Recommended length: 150-160 characters.

CreateCategoryInput.metadataKeywords ● [LocalizedStringInput!] list input

SEO keywords for search engine optimization.

Localized meta keywords relevant to the category content. Used by search engines to understand category context and improve discoverability for relevant search queries. Comma-separated list of relevant keywords.

CreateCategoryInput.metadataCanonicalUrls ● [LocalizedStringInput!] list input

Canonical URLs for duplicate content management.

Localized canonical URLs that tell search engines which version of the category page is the authoritative source. Prevents duplicate content issues and consolidates SEO value.

CreateCategoryInput.hidden ● YesNo! non-null enum

Visibility status of the category.

Controls whether the category is visible to customers in navigation and search results. Hidden categories are only accessible to administrators and can be used for draft content or temporary organization. Values: Y (hidden) or N (visible). Defaults to N (visible).

Member Of

categoryCreate mutation