/home/desid573/public_html/gcdriver/square/docs/Api
NameSizeModeActions
ApplePayApi.md23380644editdlrm
CatalogApi.md254980644editdlrm
CheckoutApi.md23130644editdlrm
CustomersApi.md160930644editdlrm
EmployeesApi.md38230644editdlrm
InventoryApi.md161220644editdlrm
LaborApi.md256430644editdlrm
LocationsApi.md16080644editdlrm
MobileAuthorizationApi.md26320644editdlrm
OAuthApi.md78200644editdlrm
OrdersApi.md125380644editdlrm
PaymentsApi.md135700644editdlrm
RefundsApi.md77010644editdlrm
ReportingApi.md81090644editdlrm
TransactionsApi.md186570644editdlrm
V1EmployeesApi.md367270644editdlrm
V1ItemsApi.md763510644editdlrm
V1LocationsApi.md25830644editdlrm
V1TransactionsApi.md299370644editdlrm
Edit: /home/desid573/public_html/gcdriver/square/docs/Api/CatalogApi.md (25498B)
# SquareConnect\CatalogApi All URIs are relative to *https://connect.squareup.com* Method | HTTP request | Description ------------- | ------------- | ------------- [**batchDeleteCatalogObjects**](CatalogApi.md#batchDeleteCatalogObjects) | **POST** /v2/catalog/batch-delete | BatchDeleteCatalogObjects [**batchRetrieveCatalogObjects**](CatalogApi.md#batchRetrieveCatalogObjects) | **POST** /v2/catalog/batch-retrieve | BatchRetrieveCatalogObjects [**batchUpsertCatalogObjects**](CatalogApi.md#batchUpsertCatalogObjects) | **POST** /v2/catalog/batch-upsert | BatchUpsertCatalogObjects [**catalogInfo**](CatalogApi.md#catalogInfo) | **GET** /v2/catalog/info | CatalogInfo [**deleteCatalogObject**](CatalogApi.md#deleteCatalogObject) | **DELETE** /v2/catalog/object/{object_id} | DeleteCatalogObject [**listCatalog**](CatalogApi.md#listCatalog) | **GET** /v2/catalog/list | ListCatalog [**retrieveCatalogObject**](CatalogApi.md#retrieveCatalogObject) | **GET** /v2/catalog/object/{object_id} | RetrieveCatalogObject [**searchCatalogObjects**](CatalogApi.md#searchCatalogObjects) | **POST** /v2/catalog/search | SearchCatalogObjects [**updateItemModifierLists**](CatalogApi.md#updateItemModifierLists) | **POST** /v2/catalog/update-item-modifier-lists | UpdateItemModifierLists [**updateItemTaxes**](CatalogApi.md#updateItemTaxes) | **POST** /v2/catalog/update-item-taxes | UpdateItemTaxes [**upsertCatalogObject**](CatalogApi.md#upsertCatalogObject) | **POST** /v2/catalog/object | UpsertCatalogObject # **batchDeleteCatalogObjects** > \SquareConnect\Model\BatchDeleteCatalogObjectsResponse batchDeleteCatalogObjects($body) BatchDeleteCatalogObjects Deletes a set of [CatalogItem](#type-catalogitem)s based on the provided list of target IDs and returns a set of successfully deleted IDs in the response. Deletion is a cascading event such that all children of the targeted object are also deleted. For example, deleting a CatalogItem will also delete all of its [CatalogItemVariation](#type-catalogitemvariation) children. `BatchDeleteCatalogObjects` succeeds even if only a portion of the targeted IDs can be deleted. The response will only include IDs that were actually deleted. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\BatchDeleteCatalogObjectsRequest(); // \SquareConnect\Model\BatchDeleteCatalogObjectsRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->batchDeleteCatalogObjects($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->batchDeleteCatalogObjects: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\BatchDeleteCatalogObjectsRequest**](../Model/BatchDeleteCatalogObjectsRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\BatchDeleteCatalogObjectsResponse**](../Model/BatchDeleteCatalogObjectsResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **batchRetrieveCatalogObjects** > \SquareConnect\Model\BatchRetrieveCatalogObjectsResponse batchRetrieveCatalogObjects($body) BatchRetrieveCatalogObjects Returns a set of objects based on the provided ID. Each [CatalogItem](#type-catalogitem) returned in the set includes all of its child information including: all of its [CatalogItemVariation](#type-catalogitemvariation) objects, references to its [CatalogModifierList](#type-catalogmodifierlist) objects, and the ids of any [CatalogTax](#type-catalogtax) objects that apply to it. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\BatchRetrieveCatalogObjectsRequest(); // \SquareConnect\Model\BatchRetrieveCatalogObjectsRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->batchRetrieveCatalogObjects($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->batchRetrieveCatalogObjects: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\BatchRetrieveCatalogObjectsRequest**](../Model/BatchRetrieveCatalogObjectsRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\BatchRetrieveCatalogObjectsResponse**](../Model/BatchRetrieveCatalogObjectsResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **batchUpsertCatalogObjects** > \SquareConnect\Model\BatchUpsertCatalogObjectsResponse batchUpsertCatalogObjects($body) BatchUpsertCatalogObjects Creates or updates up to 10,000 target objects based on the provided list of objects. The target objects are grouped into batches and each batch is inserted/updated in an all-or-nothing manner. If an object within a batch is malformed in some way, or violates a database constraint, the entire batch containing that item will be disregarded. However, other batches in the same request may still succeed. Each batch may contain up to 1,000 objects, and batches will be processed in order as long as the total object count for the request (items, variations, modifier lists, discounts, and taxes) is no more than 10,000. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\BatchUpsertCatalogObjectsRequest(); // \SquareConnect\Model\BatchUpsertCatalogObjectsRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->batchUpsertCatalogObjects($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->batchUpsertCatalogObjects: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\BatchUpsertCatalogObjectsRequest**](../Model/BatchUpsertCatalogObjectsRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\BatchUpsertCatalogObjectsResponse**](../Model/BatchUpsertCatalogObjectsResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **catalogInfo** > \SquareConnect\Model\CatalogInfoResponse catalogInfo() CatalogInfo Returns information about the Square Catalog API, such as batch size limits for `BatchUpsertCatalogObjects`. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); try { $result = $apiInstance->catalogInfo(); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->catalogInfo: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters This endpoint does not need any parameter. ### Return type [**\SquareConnect\Model\CatalogInfoResponse**](../Model/CatalogInfoResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **deleteCatalogObject** > \SquareConnect\Model\DeleteCatalogObjectResponse deleteCatalogObject($object_id) DeleteCatalogObject Deletes a single [CatalogObject](#type-catalogobject) based on the provided ID and returns the set of successfully deleted IDs in the response. Deletion is a cascading event such that all children of the targeted object are also deleted. For example, deleting a [CatalogItem](#type-catalogitem) will also delete all of its [CatalogItemVariation](#type-catalogitemvariation) children. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $object_id = "object_id_example"; // string | The ID of the [CatalogObject](#type-catalogobject) to be deleted. When an object is deleted, other objects in the graph that depend on that object will be deleted as well (for example, deleting a [CatalogItem](#type-catalogitem) will delete its [CatalogItemVariation](#type-catalogitemvariation)s). try { $result = $apiInstance->deleteCatalogObject($object_id); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->deleteCatalogObject: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **object_id** | **string**| The ID of the [CatalogObject](#type-catalogobject) to be deleted. When an object is deleted, other objects in the graph that depend on that object will be deleted as well (for example, deleting a [CatalogItem](#type-catalogitem) will delete its [CatalogItemVariation](#type-catalogitemvariation)s). | ### Return type [**\SquareConnect\Model\DeleteCatalogObjectResponse**](../Model/DeleteCatalogObjectResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **listCatalog** > \SquareConnect\Model\ListCatalogResponse listCatalog($cursor, $types) ListCatalog Returns a list of [CatalogObject](#type-catalogobject)s that includes all objects of a set of desired types (for example, all [CatalogItem](#type-catalogitem) and [CatalogTax](#type-catalogtax) objects) in the catalog. The `types` parameter is specified as a comma-separated list of valid [CatalogObject](#type-catalogobject) types: `ITEM`, `ITEM_VARIATION`, `MODIFIER`, `MODIFIER_LIST`, `CATEGORY`, `DISCOUNT`, `TAX`. __Important:__ ListCatalog does not return deleted catalog items. To retrieve deleted catalog items, use SearchCatalogObjects and set `include_deleted_objects` to `true`. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $cursor = "cursor_example"; // string | The pagination cursor returned in the previous response. Leave unset for an initial request. See [Pagination](/basics/api101/pagination) for more information. $types = "types_example"; // string | An optional case-insensitive, comma-separated list of object types to retrieve, for example `ITEM,ITEM_VARIATION,CATEGORY,IMAGE`. The legal values are taken from the [CatalogObjectType](#type-catalogobjecttype) enumeration, namely `ITEM`, `ITEM_VARIATION`, `CATEGORY`, `DISCOUNT`, `TAX`, `MODIFIER`, `MODIFIER_LIST`, or `IMAGE`. try { $result = $apiInstance->listCatalog($cursor, $types); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->listCatalog: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **cursor** | **string**| The pagination cursor returned in the previous response. Leave unset for an initial request. See [Pagination](/basics/api101/pagination) for more information. | [optional] **types** | **string**| An optional case-insensitive, comma-separated list of object types to retrieve, for example `ITEM,ITEM_VARIATION,CATEGORY,IMAGE`. The legal values are taken from the [CatalogObjectType](#type-catalogobjecttype) enumeration, namely `ITEM`, `ITEM_VARIATION`, `CATEGORY`, `DISCOUNT`, `TAX`, `MODIFIER`, `MODIFIER_LIST`, or `IMAGE`. | [optional] ### Return type [**\SquareConnect\Model\ListCatalogResponse**](../Model/ListCatalogResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **retrieveCatalogObject** > \SquareConnect\Model\RetrieveCatalogObjectResponse retrieveCatalogObject($object_id, $include_related_objects) RetrieveCatalogObject Returns a single [CatalogItem](#type-catalogitem) as a [CatalogObject](#type-catalogobject) based on the provided ID. The returned object includes all of the relevant [CatalogItem](#type-catalogitem) information including: [CatalogItemVariation](#type-catalogitemvariation) children, references to its [CatalogModifierList](#type-catalogmodifierlist) objects, and the ids of any [CatalogTax](#type-catalogtax) objects that apply to it. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $object_id = "object_id_example"; // string | The object ID of any type of [CatalogObject](#type-catalogobject)s to be retrieved. $include_related_objects = true; // bool | If `true`, the response will include additional objects that are related to the requested object, as follows: If the `object` field of the response contains a [CatalogItem](#type-catalogitem), its associated [CatalogCategory](#type-catalogcategory), [CatalogTax](#type-catalogtax)es, [CatalogImage](#type-catalogimage)s and [CatalogModifierList](#type-catalogmodifierlist)s will be returned in the `related_objects` field of the response. If the `object` field of the response contains a [CatalogItemVariation](#type-catalogitemvariation), its parent [CatalogItem](#type-catalogitem) will be returned in the `related_objects` field of the response. Default value: `false` try { $result = $apiInstance->retrieveCatalogObject($object_id, $include_related_objects); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->retrieveCatalogObject: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **object_id** | **string**| The object ID of any type of [CatalogObject](#type-catalogobject)s to be retrieved. | **include_related_objects** | **bool**| If `true`, the response will include additional objects that are related to the requested object, as follows: If the `object` field of the response contains a [CatalogItem](#type-catalogitem), its associated [CatalogCategory](#type-catalogcategory), [CatalogTax](#type-catalogtax)es, [CatalogImage](#type-catalogimage)s and [CatalogModifierList](#type-catalogmodifierlist)s will be returned in the `related_objects` field of the response. If the `object` field of the response contains a [CatalogItemVariation](#type-catalogitemvariation), its parent [CatalogItem](#type-catalogitem) will be returned in the `related_objects` field of the response. Default value: `false` | [optional] ### Return type [**\SquareConnect\Model\RetrieveCatalogObjectResponse**](../Model/RetrieveCatalogObjectResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **searchCatalogObjects** > \SquareConnect\Model\SearchCatalogObjectsResponse searchCatalogObjects($body) SearchCatalogObjects Queries the targeted catalog using a variety of query types: [CatalogQuerySortedAttribute](#type-catalogquerysortedattribute), [CatalogQueryExact](#type-catalogqueryexact), [CatalogQueryRange](#type-catalogqueryrange), [CatalogQueryText](#type-catalogquerytext), [CatalogQueryItemsForTax](#type-catalogqueryitemsfortax), and [CatalogQueryItemsForModifierList](#type-catalogqueryitemsformodifierlist). ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\SearchCatalogObjectsRequest(); // \SquareConnect\Model\SearchCatalogObjectsRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->searchCatalogObjects($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->searchCatalogObjects: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\SearchCatalogObjectsRequest**](../Model/SearchCatalogObjectsRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\SearchCatalogObjectsResponse**](../Model/SearchCatalogObjectsResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **updateItemModifierLists** > \SquareConnect\Model\UpdateItemModifierListsResponse updateItemModifierLists($body) UpdateItemModifierLists Updates the [CatalogModifierList](#type-catalogmodifierlist) objects that apply to the targeted [CatalogItem](#type-catalogitem) without having to perform an upsert on the entire item. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\UpdateItemModifierListsRequest(); // \SquareConnect\Model\UpdateItemModifierListsRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->updateItemModifierLists($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->updateItemModifierLists: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\UpdateItemModifierListsRequest**](../Model/UpdateItemModifierListsRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\UpdateItemModifierListsResponse**](../Model/UpdateItemModifierListsResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **updateItemTaxes** > \SquareConnect\Model\UpdateItemTaxesResponse updateItemTaxes($body) UpdateItemTaxes Updates the [CatalogTax](#type-catalogtax) objects that apply to the targeted [CatalogItem](#type-catalogitem) without having to perform an upsert on the entire item. ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\UpdateItemTaxesRequest(); // \SquareConnect\Model\UpdateItemTaxesRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->updateItemTaxes($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->updateItemTaxes: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\UpdateItemTaxesRequest**](../Model/UpdateItemTaxesRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\UpdateItemTaxesResponse**](../Model/UpdateItemTaxesResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md) # **upsertCatalogObject** > \SquareConnect\Model\UpsertCatalogObjectResponse upsertCatalogObject($body) UpsertCatalogObject Creates or updates the target [CatalogObject](#type-catalogobject). ### Example ```php setAccessToken('YOUR_ACCESS_TOKEN'); $apiInstance = new SquareConnect\Api\CatalogApi(); $body = new \SquareConnect\Model\UpsertCatalogObjectRequest(); // \SquareConnect\Model\UpsertCatalogObjectRequest | An object containing the fields to POST for the request. See the corresponding object definition for field details. try { $result = $apiInstance->upsertCatalogObject($body); print_r($result); } catch (Exception $e) { echo 'Exception when calling CatalogApi->upsertCatalogObject: ', $e->getMessage(), PHP_EOL; } ?> ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**\SquareConnect\Model\UpsertCatalogObjectRequest**](../Model/UpsertCatalogObjectRequest.md)| An object containing the fields to POST for the request. See the corresponding object definition for field details. | ### Return type [**\SquareConnect\Model\UpsertCatalogObjectResponse**](../Model/UpsertCatalogObjectResponse.md) ### Authorization [oauth2](../../README.md#oauth2) ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)