--- title: CartErrorCode - Storefront API description: Possible error codes that can be returned by `CartUserError`. api_version: 2025-07 api_name: storefront type: enum api_type: graphql source_url: html: 'https://shopify.dev/docs/api/storefront/2025-07/enums/CartErrorCode' md: 'https://shopify.dev/docs/api/storefront/2025-07/enums/CartErrorCode.md' --- # Cart​Error​Code enum Possible error codes that can be returned by `CartUserError`. ## Valid values * ADDRESS\_​FIELD\_​CONTAINS\_​EMOJIS The specified address field contains emojis. * ADDRESS\_​FIELD\_​CONTAINS\_​HTML\_​TAGS The specified address field contains HTML tags. * ADDRESS\_​FIELD\_​CONTAINS\_​URL The specified address field contains a URL. * ADDRESS\_​FIELD\_​DOES\_​NOT\_​MATCH\_​EXPECTED\_​PATTERN The specified address field does not match the expected pattern. * ADDRESS\_​FIELD\_​IS\_​REQUIRED The specified address field is required. * ADDRESS\_​FIELD\_​IS\_​TOO\_​LONG The specified address field is too long. * BUYER\_​CANNOT\_​PURCHASE\_​FOR\_​COMPANY\_​LOCATION Buyer cannot purchase for company location. * CART\_​TOO\_​LARGE The cart is too large to save. * INVALID The input value is invalid. * INVALID\_​COMPANY\_​LOCATION Company location not found or not allowed. * INVALID\_​DELIVERY\_​ADDRESS\_​ID The delivery address was not found. * INVALID\_​DELIVERY\_​GROUP Delivery group was not found in cart. * INVALID\_​DELIVERY\_​OPTION Delivery option was not valid. * INVALID\_​INCREMENT The quantity must be a multiple of the specified increment. * INVALID\_​MERCHANDISE\_​LINE Merchandise line was not found in cart. * INVALID\_​METAFIELDS The metafields were not valid. * INVALID\_​ZIP\_​CODE\_​FOR\_​COUNTRY The given zip code is invalid for the provided country. * INVALID\_​ZIP\_​CODE\_​FOR\_​PROVINCE The given zip code is invalid for the provided province. * LESS\_​THAN The input value should be less than the maximum value allowed. * MAXIMUM\_​EXCEEDED The quantity must be below the specified maximum for the item. * MINIMUM\_​NOT\_​MET The quantity must be above the specified minimum for the item. * MISSING\_​CUSTOMER\_​ACCESS\_​TOKEN The customer access token is required when setting a company location. * MISSING\_​DISCOUNT\_​CODE Missing discount code. * MISSING\_​NOTE Missing note. * NOTE\_​TOO\_​LONG The note length must be below the specified maximum. * ONLY\_​ONE\_​DELIVERY\_​ADDRESS\_​CAN\_​BE\_​SELECTED Only one delivery address can be selected. * PENDING\_​DELIVERY\_​GROUPS The delivery group is in a pending state. * PROVINCE\_​NOT\_​FOUND The given province cannot be found. * SELLING\_​PLAN\_​NOT\_​APPLICABLE Selling plan is not applicable. * SERVICE\_​UNAVAILABLE An error occurred while saving the cart. * TOO\_​MANY\_​DELIVERY\_​ADDRESSES Too many delivery addresses on Cart. * UNSPECIFIED\_​ADDRESS\_​ERROR A general error occurred during address validation. * VALIDATION\_​CUSTOM Validation failed. * VARIANT\_​REQUIRES\_​SELLING\_​PLAN Variant can only be purchased with a selling plan. * ZIP\_​CODE\_​NOT\_​SUPPORTED The given zip code is unsupported. *** ## Fields * [Cart​User​Error.code](https://shopify.dev/docs/api/storefront/2025-07/objects/CartUserError#field-CartUserError.fields.code) OBJECT Represents an error that happens during execution of a cart mutation. *** ## Map ### Fields with this enum * <-|[Cart​User​Error.code](https://shopify.dev/docs/api/storefront/2025-07/objects/CartUserError#field-CartUserError.fields.code)