Attribute
Custom attribute of a product. Attributes can be assigned to products and variants at the product type level.
type Attribute implements Node, ObjectWithMetadata {
id: ID!
metadata: [MetadataItem!]!
privateMetadata: [MetadataItem!]!
name: String!
slug: String!
externalId: String
externalSource: String
isLocked: Boolean!
valueRequired: Boolean!
visibleInStorefront: Boolean!
filterableInStorefront: Boolean!
storefrontSearchPosition: Int!
filterableInDashboard: Boolean!
availableInGrid: Boolean!
inputType: AttributeInputTypeEnum!
values(
search: String
first: Int
): [AttributeValue!]!
createdBy: Seller
allProductTypes: [ProductType!]!
productTypes(
before: String
after: String
first: Int
last: Int
): ProductTypeCountableConnection!
productVariantTypes(
before: String
after: String
first: Int
last: Int
): ProductTypeCountableConnection!
warnings: [AttributeWarningMessageItem!]!
}
Show more ↓
Fields
Attribute.id ● ID! non-null scalar
The Globally Unique ID of this object
Attribute.metadata ● [MetadataItem!]! non-null object
List of public metadata items. Can be accessed without permissions.
Attribute.privateMetadata ● [MetadataItem!]! non-null object
List of private metadata items. Requires proper staff permissions to access.
Attribute.name ● String! non-null scalar
Name of the attribute
Attribute.slug ● String! non-null scalar
Slug identifier
Attribute.externalId ● String scalar
External system identifier
Attribute.externalSource ● String scalar
External system source
Attribute.isLocked ● Boolean! non-null scalar
Controls if seller users can create dropdown/multiselect values
Attribute.valueRequired ● Boolean! non-null scalar
Whether a value is required
Attribute.visibleInStorefront ● Boolean! non-null scalar
Visible in storefront
Attribute.filterableInStorefront ● Boolean! non-null scalar
Filterable in storefront
Attribute.storefrontSearchPosition ● Int! non-null scalar
Position in storefront search
Attribute.filterableInDashboard ● Boolean! non-null scalar
Filterable in dashboard
Attribute.availableInGrid ● Boolean! non-null scalar
Available in product grid display
Attribute.inputType ● AttributeInputTypeEnum! non-null enum
The input type to use for entering attribute values in the dashboard.
Attribute.values ● [AttributeValue!]! non-null object
The values available for this attribute
Attribute.values.search ● String scalar
Attribute.values.first ● Int scalar
Attribute.createdBy ● Seller object
Seller who created this attribute, if any