CatalogQuery

November 20, 2019 ยท View on GitHub

Description

A query to be applied to a SearchCatalogObjectsRequest. Only one query field may be present. Where an attribute name is required, it should be specified as the name of any field marked "searchable" from the structured data types for the desired result object type(s) (CatalogItem, CatalogItemVariation, CatalogCategory, CatalogTax, CatalogDiscount, CatalogModifierList, CatalogModifier). For example, a query that should return Items may specify attribute names from any of the searchable fields of the CatalogItem data type, namely \"name\", \"description\", and \"abbreviation\".

Properties

NameGetterSetterTypeDescriptionNotes
sorted_attribute_querygetSortedAttributeQuery()setSortedAttributeQuery($value)\SquareConnect\Model\CatalogQuerySortedAttributeA query that returns all objects, sorted by the given attribute.[optional]
exact_querygetExactQuery()setExactQuery($value)\SquareConnect\Model\CatalogQueryExactA query that returns only objects for which the given (string-valued) attribute has the given case-insensitive value.[optional]
prefix_querygetPrefixQuery()setPrefixQuery($value)\SquareConnect\Model\CatalogQueryPrefixA query that returns only objects for which the given (string-valued) attribute has the given case-insensitive prefix.[optional]
range_querygetRangeQuery()setRangeQuery($value)\SquareConnect\Model\CatalogQueryRangeA query that returns only objects for which the given (integer-valued) attribute lies in the given range.[optional]
text_querygetTextQuery()setTextQuery($value)\SquareConnect\Model\CatalogQueryTextA query that returns only objects whose searchable attributes contain all of the given keywords as prefixes. For example, if a `CatalogItem` contains attributes `{"name": "t-shirt"}` and `{"description": "Small, Purple"}`, it will be matched by the query `{"keywords": ["shirt", "sma", "purp"]}`.[optional]
items_for_tax_querygetItemsForTaxQuery()setItemsForTaxQuery($value)\SquareConnect\Model\CatalogQueryItemsForTaxA query that returns all `CatalogItem`s that have any of the given `CatalogTax`es enabled.[optional]
items_for_modifier_list_querygetItemsForModifierListQuery()setItemsForModifierListQuery($value)\SquareConnect\Model\CatalogQueryItemsForModifierListA query that returns all `CatalogItem`s that have any of the given `CatalogModifierList`s enabled.[optional]
items_for_item_options_querygetItemsForItemOptionsQuery()setItemsForItemOptionsQuery($value)\SquareConnect\Model\CatalogQueryItemsForItemOptionsA query that returns all `CatalogItem`s that have all of the given `CatalogItemOption`s.[optional]
item_variations_for_item_option_values_querygetItemVariationsForItemOptionValuesQuery()setItemVariationsForItemOptionValuesQuery($value)\SquareConnect\Model\CatalogQueryItemVariationsForItemOptionValuesA query that returns all `CatalogItemVariation`s that have all of the given `CatalogItemOption` values.[optional]

Note: All properties are protected and only accessed via getters and setters.

[Back to Model list] [Back to API list] [Back to README]