Collections guide

collectionCreate ruleSet is deprecated: how to use sources and conditions

Generate either format

How rules map to conditions

  • TAG equals → productTag TAGGED_WITH (and NOT_TAGGED_WITH for is not).
  • TITLE, TYPE, VENDOR, VARIANT_TITLE → productTitle, productType, productVendor, variantTitle; NOT_CONTAINS becomes DOES_NOT_CONTAIN.
  • VARIANT_PRICE, VARIANT_COMPARE_AT_PRICE → variantPrice, variantCompareAtPrice with a money value (amount and currency code).
  • VARIANT_WEIGHT → variantWeight with a weight value (value and unit). VARIANT_INVENTORY → variantInventory with a whole number.
  • appliedDisjunctively true/false → the source’s matchType ANY/ALL.

Old format

Still accepted, but marked deprecated in the API docs:

Deprecated: input + ruleSet
mutation {
  collectionCreate(input: {
    title: "Nike or Adidas",
    ruleSet: {
      appliedDisjunctively: true,
      rules: [
        { column: VENDOR, relation: EQUALS, condition: "Nike" },
        { column: VENDOR, relation: EQUALS, condition: "Adidas" }
      ]
    }
  }) {
    collection { id handle }
    userErrors { field message }
  }
}

New format

Current: collection + sources
mutation CreateCollectionsBatch1 {
  c2: collectionCreate(collection: {
    title: "Summer Sale",
    handle: "summer-sale",
    sortOrder: BEST_SELLING,
    sources: [{
      source: {
        title: "Summer Sale conditions",
        inclusion: {
          matchType: ALL,
          conditions: [
            { productTag: { relation: TAGGED_WITH, values: ["summer-sale"], matchType: ANY } },
            { variantPrice: { relation: LESS_THAN, value: { amount: "100.01", currencyCode: USD } } }
          ]
        }
      }
    }]
  }) {
    collection { id handle title }
    userErrors { field message }
  }
}

Which should I use?

Use the current format unless a tool or script you rely on still expects ruleSet. Price and weight conditions in the current format need your store currency and weight unit, which the builder asks for.

More collection guides

Based on Shopify’s collectionCreate docs (Admin API 2026-10) and the Help Center page on collection conditions. Not affiliated with, endorsed by, or sponsored by Shopify Inc. Shopify is a trademark of Shopify Inc.