CatalogService class
URL: https://developer.squareup.com/reference/square/catalog-api
Programmatically catalogs a Square seller’s products for sale and services for hire.
The Catalog API allows you to programmatically catalog products or services, including items, variations, categories, discounts, taxes, modifiers, and more.
Constructors
- CatalogService.new({required String baseUrl, required AuthenticationService authenticationService})
Properties
- authenticationService → AuthenticationService
-
final
- baseUrl → String
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
batchDeleteCatalog(
{required List< String> objectIds, String? authToken}) → Future<CatalogDeleteResponse> - Deletes a set of CatalogItems based on the provided list of target IDs and returns a set of successfully deleted IDs in the response.
-
batchRetrieveCatalog(
{required RetrieveCatalogRequest request, String? authToken}) → Future< CatalogResponse> - Returns a set of objects based on the provided ID.
-
batchUpsertCatalog(
{required BatchUpsertCatalogRequest request, String? authToken}) → Future< CatalogResponse> - Creates or updates up to 10,000 target objects based on the provided list of objects.
-
createCatalogImage(
{required CreateCatalogImageRequest request, String? authToken}) → Future< CatalogObject> - Uploads an image file to be represented by a CatalogImage object that can be linked to an existing CatalogObject instance.
-
deleteCatalog(
{required String objectId, String? authToken}) → Future< CatalogDeleteResponse> - Deletes a single CatalogObject based on the provided ID and returns the set of successfully deleted IDs in the response.
-
listCatalog(
{required ListCatalogRequest request, String? authToken}) → Future< CatalogResponse> - Returns a list of all CatalogObjects of the specified types in the catalog.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
readCatalog(
{required String objectId, String? authToken}) → Future< CatalogResponse> - Returns a single CatalogItem as a CatalogObject based on the provided ID.
-
readCatalogInfo(
{required UpdateCatalogImageRequest request, required String imageId, String? authToken}) → Future< CatalogInfoResponse> - Retrieves information about the Square Catalog API, such as batch size limits that can be used by the BatchUpsertCatalogObjects endpoint
-
searchCatalog(
{required String objectId, required CatalogSearchRequest request, String? authToken}) → Future< CatalogResponse> - Searches for CatalogObject of any type by matching supported search attribute values, excluding custom attribute values on items or item variations, against one or more of the specified query filters.
-
searchCatalogItems(
{required String objectId, required CatalogItemsSearchRequest request, String? authToken}) → Future< CatalogItemsResponse> - Searches for catalog items or item variations by matching supported search attribute values, including custom attribute values, against one or more of the specified query filters.
-
toString(
) → String -
A string representation of this object.
inherited
-
updateCatalogImage(
{required UpdateCatalogImageRequest request, required String imageId, String? authToken}) → Future< CatalogObject> - Uploads a new image file to replace the existing one in the specified CatalogImage object.
-
updateCatalogItemsModifiers(
{required String objectId, required UpdateCatalogItemsModifier request, String? authToken}) → Future< String> - Updates the CatalogModifierList objects that apply to the targeted CatalogItem without having to perform an upsert on the entire item.
-
updateCatalogItemsTaxes(
{required String objectId, required UpdateCatalogItemsTaxes request, String? authToken}) → Future< String> - Updates the CatalogTax objects that apply to the targeted CatalogItem without having to perform an upsert on the entire item.
-
upsertCatalog(
{required UpsertCatalogRequest request, String? authToken}) → Future< CatalogResponse> - Creates or updates the target CatalogObject.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited