Search price tiers

distru-search-price-tiersRead

Searches the price tiers of the company: discounts that lower the unit price of sales order items.

Inputs

Every tool also takes the common inputs.

FieldTypeRequiredDescription
limitintegerNoDefault: 10
cursorstringNonextCursor of the previous call; keep the other arguments unchanged.
idsstring[]NoPrice tier IDs.
searchstringNoCase-insensitive substring of name or externalName.
customerIdsstring[]NoMatches oneOfCompanies. Resolve via distru-search-companies.
customerGroupIdsstring[]NoMatches oneOfCompanyGroups. Resolve via distru-search-lookups (type COMPANY_GROUP).
productIdsstring[]NoMatches oneOfProducts. Not tiers reaching a product only via its category, brand, group or tag. Resolve via distru-search-products.
productTagIdsstring[]NoMatches oneOfProductTags. Resolve via distru-search-lookups (type PRODUCT_TAG).
productCategoryIdsstring[]NoMatches oneOfProductCategories. Resolve via distru-search-lookups (type PRODUCT_CATEGORY).
productSubcategoryIdsstring[]NoMatches oneOfProductSubcategories. Resolve via distru-search-lookups (type PRODUCT_CATEGORY, each row's subcategories).
productGroupIdsstring[]NoMatches oneOfProductGroups. Resolve via distru-search-lookups (type PRODUCT_GROUP).
brandIdsstring[]NoMatches oneOfProductBrands. Resolve via distru-search-products (each row's brand) or distru-search-companies.
menuIdsstring[]NoTiers shown on any of these active menus: menuMode ALL, or SPECIFIC with the menu in menus. Resolve via distru-search-menus.
validAtstringNoTiers active at this moment: validFrom <= it (or null), validUntil > it (or null). Without it, expired and future tiers are listed too. ISO 8601 with a UTC offset, e.g. "2026-09-01T00:00:00-07:00"; the company timezone is on distru-get-me.
pricingTypeenum
AMOUNT_OFFFLAT_PRICEPERCENT_OFF
No
ownerIdsstring[]NoResolve via distru-search-users.
includeDeletedbooleanNoAlso list deleted tiers, with deletedAt set.
sortByobjectNoDefault: most recently updated first.
sortBy.directionenum
ASCDESC
Yes
sortBy.fieldenum
INSERTED_ATNAMEUPDATED_AT
YesNAME = internal name, not externalName.

Output

Presence on a nested field assumes its parent exists.

FieldTypePresence
hasMorebooleanAlways
nextCursorstringCan be absent
totalCountintegerCan be absent
itemsobject[]Always
items[].idstringAlways
items[].namestringAlways
items[].externalNamestringNull or absent
items[].pricingobjectAlways
items[].pricing.typeenum
AMOUNT_OFFFLAT_PRICEPERCENT_OFF
Always
items[].pricing.valuestringNull or absent
items[].validFromstringNull or absent
items[].validUntilstringNull or absent
items[].deletedAtstringCan be null
items[].menuModeenum
ALLNONESPECIFIC
Always
items[].menusobject[]Can be absent
items[].menus[].idstringAlways
items[].menus[].namestringAlways
items[].ownerobjectNull or absent
items[].owner.idstringAlways
items[].owner.fullNamestringNull or absent
items[].conditionsobjectAlways
items[].conditions.oneOfProductsobject[]Can be absent
items[].conditions.oneOfProducts[].idstringAlways
items[].conditions.oneOfProducts[].namestringAlways
items[].conditions.notOneOfProductsobject[]Can be absent
items[].conditions.notOneOfProducts[].idstringAlways
items[].conditions.notOneOfProducts[].namestringAlways
items[].conditions.oneOfProductCategoriesobject[]Can be absent
items[].conditions.oneOfProductCategories[].idstringAlways
items[].conditions.oneOfProductCategories[].namestringAlways
items[].conditions.notOneOfProductCategoriesobject[]Can be absent
items[].conditions.notOneOfProductCategories[].idstringAlways
items[].conditions.notOneOfProductCategories[].namestringAlways
items[].conditions.oneOfProductSubcategoriesobject[]Can be absent
items[].conditions.oneOfProductSubcategories[].idstringAlways
items[].conditions.oneOfProductSubcategories[].namestringAlways
items[].conditions.notOneOfProductSubcategoriesobject[]Can be absent
items[].conditions.notOneOfProductSubcategories[].idstringAlways
items[].conditions.notOneOfProductSubcategories[].namestringAlways
items[].conditions.oneOfProductGroupsobject[]Can be absent
items[].conditions.oneOfProductGroups[].idstringAlways
items[].conditions.oneOfProductGroups[].namestringAlways
items[].conditions.notOneOfProductGroupsobject[]Can be absent
items[].conditions.notOneOfProductGroups[].idstringAlways
items[].conditions.notOneOfProductGroups[].namestringAlways
items[].conditions.oneOfProductTagsobject[]Can be absent
items[].conditions.oneOfProductTags[].idstringAlways
items[].conditions.oneOfProductTags[].namestringAlways
items[].conditions.notOneOfProductTagsobject[]Can be absent
items[].conditions.notOneOfProductTags[].idstringAlways
items[].conditions.notOneOfProductTags[].namestringAlways
items[].conditions.oneOfCompanyGroupsobject[]Can be absent
items[].conditions.oneOfCompanyGroups[].idstringAlways
items[].conditions.oneOfCompanyGroups[].namestringAlways
items[].conditions.notOneOfCompanyGroupsobject[]Can be absent
items[].conditions.notOneOfCompanyGroups[].idstringAlways
items[].conditions.notOneOfCompanyGroups[].namestringAlways
items[].conditions.oneOfProductBrandsobject[]Can be absent
items[].conditions.oneOfProductBrands[].idstringAlways
items[].conditions.oneOfProductBrands[].namestringNull or absent
items[].conditions.notOneOfProductBrandsobject[]Can be absent
items[].conditions.notOneOfProductBrands[].idstringAlways
items[].conditions.notOneOfProductBrands[].namestringNull or absent
items[].conditions.oneOfCompaniesobject[]Can be absent
items[].conditions.oneOfCompanies[].idstringAlways
items[].conditions.oneOfCompanies[].namestringNull or absent
items[].conditions.notOneOfCompaniesobject[]Can be absent
items[].conditions.notOneOfCompanies[].idstringAlways
items[].conditions.notOneOfCompanies[].namestringNull or absent
items[].conditions.minQuantityobjectNull or absent
items[].conditions.minQuantity.quantitystringAlways
items[].conditions.minQuantity.unitTypeobjectNull or absent
items[].conditions.minQuantity.unitType.idstringAlways
items[].conditions.minQuantity.unitType.namestringAlways
items[].conditions.totalThcPercentageRangeobjectNull or absent
items[].conditions.totalThcPercentageRange.minstringNull or absent
items[].conditions.totalThcPercentageRange.maxstringNull or absent
What the AI reads

Searches the price tiers of the company: discounts that lower the unit price of sales order items. One row per tier with its pricing, active window, menus, owner and conditions. For which tiers priced which orders and the discounts given, deleted tiers included, use distru-report-sales-orders with rowsPer LINE_ITEM. externalName is the name buyers see; null means they see name. pricing.type PERCENT_OFF takes value percent off the unit price, AMOUNT_OFF subtracts value from it, FLAT_PRICE replaces it with value; the price never goes below 0, and when flat and other tiers both apply to an item, flat tiers win. A tier applies to an order item only when every condition is met: the item matches an entry of each oneOf* list and none of any notOneOf* list, reaches minQuantity (in its unitType when set), and has a total THC percentage within totalThcPercentageRange (null bounds are open). A missing condition key means no condition of that kind. menus is present only when menuMode is SPECIFIC; ALL means every active menu and NONE no menu. validFrom and validUntil bound the active window; null means no limit on that side. Tiers the caller's team restrictions hide are omitted. List filters match any value. Condition filters (Matches oneOf*) skip tiers without that condition or that only exclude the values.