Queries
product— Fetch a single product by its id.productCustomsUpdateJob(Experimental) — Fetch a job started byproductCustomsUpdate. Null when no job of this store has the id.productFamilies— List product families.productFamily— Fetch a single product family by its id.products— List products, optionally filtered by product family.
Mutations
createProductFamily— Create a new product family.deleteProduct— Delete a product. Returns true if an owned product was deleted, false if none matched. Throws a 409 CONFLICT error (with an extension code of PRODUCT_SOURCE_MANAGED, PRODUCT_HAS_LISTING, or PRODUCT_HAS_INVENTORY) if the product is ineligible for deletion.deleteProductFamily— Delete a product family and all of its products. Returns true if an owned product family was deleted, false if none matched. Throws a 409 CONFLICT error (with an extension code of PRODUCT_SOURCE_MANAGED, PRODUCT_HAS_LISTING, or PRODUCT_HAS_INVENTORY) if the family or any product is ineligible for deletion.productCustomsUpdate(Experimental) — Save customs details (HS code, country of origin, customs description, material, weight, dimensions, manufacturer) on product variants, the same job as the customs CSV upload in the merchant app. Each row names variants bysourceIdorskuand carries only the fields to change. Rows are validated first; the ones that are ready are saved by a background job, whichproductCustomsUpdateJobreports. WithdryRun, nothing is saved and the result only says what each row would do. A variant of another store is never found. Throws a 400 error with an extension code of NO_PRODUCT_CUSTOMS_ROWS_READY when no row is ready to save, or BAD_USER_INPUT whenrowsis empty or has more than 500 rows.syncSalesChannelVariants— Resolve sales channel variant ids to products here, syncing any that do not exist yet. Returns one entry per requested variant id, in the order given; a variant the sales channel does not have resolves to NOT_FOUND rather than failing the request. By default, variants already present are returned without calling the sales channel; with mode UPSERT, every requested variant’s product is re-synced. Throws a 400 error when a variant id is not in the sales channel’s id format (for Shopify, gid://shopify/ProductVariant/<numeric id>), and a 400 error (with an extension code of SALES_CHANNEL_NOT_CONNECTED) when the sales channel is not connected.
Objects
Attribute— A typed attribute defined by the merchant and attached to a product, product family or the account.Dimensions— A product’s length, width, and height expressed in a single shared unit.Manufacturer— A company that makes products, as declared on customs paperwork.Product— A specific sellable product (a variant under a product family).ProductCustomsRowPreview(Experimental) — What saving one row of a customs update does.ProductCustomsUpdate(Experimental) — The outcome of a product customs update: the job saving the ready rows, and what each row does.ProductCustomsUpdateJob(Experimental) — The background jobproductCustomsUpdatestarts to save the ready rows.ProductFamily— A merchant catalog item — a group of related products (variants).ProductFamilyImage— An image attached to a product family.ProductFamilyOption— A variant option (e.g. Size, Color) for a product family, with its allowed values.ProductImage— An image attached to a specific product (variant).ProductOptionValue— A variant’s selected value for one of its family’s options (e.g. Size: M).SyncedVariant— The result of resolving one sales channel variant to a product here.Weight— A weight as a{ value, unit }pair, e.g.{ value: 1.5, unit: KILOGRAM }.
Input objects
CreateProductFamilyInput— The input for creating a new product family.CreateProductInput— A product (variant) to create under the new family.DimensionInput— A length as a{ value, unit }pair.ProductCustomsDimensionsInput(Experimental) — A package’s length, width, and height, all in one unit. All four fields are required together.ProductCustomsManufacturerInput(Experimental) — The manufacturer to set on a product. Give amid, or a street address with city and country. Matching manufacturer details are reused, not duplicated.ProductCustomsRowInput(Experimental) — The customs details to save on the product variants a row names. Leave out what is not changing: a field left out keeps its saved value, and no field can be cleared.ProductFamilyOptionInput— An option (e.g. Size) to create on the new family.ProductOptionValueInput— A variant’s selected value for one of the family’s options (e.g. Size: M).SyncSalesChannelVariantsInput— The sales channel variants to resolve to products, syncing any that are missing.WeightInput— A weight as a{ value, unit }pair.
Enums
AttributeType— The data type of a merchant-defined attribute. Determines the JSON shape of the attribute’svalue(documented on each enum value).DimensionUnit— A unit of length used to express a product’s dimensions.ProductCustomsRowStatus(Experimental) — What saving a row would do.ProductCustomsUpdateJobState(Experimental) — Where a product customs update job is.ProductCustomsUpdateRowOutcome(Experimental) — What became of one row of a product customs update job.ProductFamilySortKey— A field this list can be ordered by; pass to the list’sorderByargument and pair withreverseto flip direction.ProductSortKey— A field this list can be ordered by; pass to the list’sorderByargument and pair withreverseto flip direction.SalesChannel— An external sales channel a product can be synced from on demand.SalesChannelSyncMode— Which requested variants a sales channel sync fetches.VariantSyncOutcome— What happened to one requested sales channel variant.WeightUnit— A unit of mass used to express a product’s weight.