Create Product Option Value
Create Product Option Value
Creates a new value for an existing product option (like "Small", "Medium", "Large" for a Size option).
Usage​
This mutation must be called after creating a product option and before creating a product that uses this option value. The option value ID returned should be referenced when creating product variants.
Required Fields​
name: The display name of the option value (e.g., "Small", "Red", "Cotton")optionId: The ID of the parent option (from CreateProductOption)locale: The locale for the option value namestoreId: The store ID
Optional Fields​
handle: URL-friendly identifier (auto-generated if not provided)id: For updating existing option values
Example Workflow​
- Create option:
CreateProductOption(e.g., "Size") - Create option values:
CreateProductOptionValue(e.g., "Small", "Medium", "Large") - Create product with variants using these option values
GraphQL Endpoint​
https://graphql.wuilt.com
Operation: CreateProductOptionValue​
Try It Out​
Query​
Query Variables
1
2
3
4
5
6
7
8
Note: Make sure to change the storeId with your store ID. For guidance on how to get your store ID, reference the Store ID guide.
Authentication​
To use this query, you will need an API key. Click the "API Key" button in the navigation bar to enter your credentials.