Skip to main content

attributeValueCreate Mutation

Creates a value for an attribute.

Requires one of the following permissions, depending on the attribute type: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES for `PRODUCT_TYPE` attributesMANAGE_PAGE_TYPES_AND_ATTRIBUTES for `PAGE_TYPE` attributesMANAGE_CUSTOMER_TYPES_AND_ATTRIBUTES for `CUSTOMER_TYPE` attributes

Triggers the following webhook events:

  • ATTRIBUTE_VALUE_CREATED (async): An attribute value was created.
  • ATTRIBUTE_UPDATED (async): An attribute was updated.
attributeValueCreate(
attribute: ID!
input: AttributeValueCreateInput!
): AttributeValueCreate
Details
type AttributeValueCreate {
attribute: Attribute
attributeErrors: [AttributeError!]! @deprecated
errors: [AttributeError!]!
attributeValue: AttributeValue
}

Arguments

attribute ● ID!

Attribute to which value will be assigned.

input ● AttributeValueCreateInput!

Fields required to create an AttributeValue.

Type

AttributeValueCreate

Creates a value for an attribute.

Requires one of the following permissions, depending on the attribute type: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES for `PRODUCT_TYPE` attributesMANAGE_PAGE_TYPES_AND_ATTRIBUTES for `PAGE_TYPE` attributesMANAGE_CUSTOMER_TYPES_AND_ATTRIBUTES for `CUSTOMER_TYPE` attributes

Triggers the following webhook events:

  • ATTRIBUTE_VALUE_CREATED (async): An attribute value was created.
  • ATTRIBUTE_UPDATED (async): An attribute was updated.