Square Inventory API

The Inventory API from Square — 13 operation(s) for inventory.

Documentation

📖
Documentation
https://developer.squareup.com/docs/payments-overview
📖
APIReference
https://developer.squareup.com/reference/square/payments-api
📖
Documentation
https://developer.squareup.com/docs/orders-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/orders-api
📖
Documentation
https://developer.squareup.com/docs/catalog-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/catalog-api
📖
Documentation
https://developer.squareup.com/docs/inventory-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/inventory-api
📖
Documentation
https://developer.squareup.com/docs/customers
📖
APIReference
https://developer.squareup.com/reference/square/customers-api
📖
Documentation
https://developer.squareup.com/docs/locations-api
📖
APIReference
https://developer.squareup.com/reference/square/locations-api
📖
Documentation
https://developer.squareup.com/docs/team/overview
📖
APIReference
https://developer.squareup.com/reference/square/team-api
📖
Documentation
https://developer.squareup.com/docs/labor-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/labor-api
📖
Documentation
https://developer.squareup.com/docs/bookings-api/what-it-is
📖
APIReference
https://developer.squareup.com/reference/square/bookings-api
📖
Documentation
https://developer.squareup.com/docs/loyalty-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/loyalty-api
📖
Documentation
https://developer.squareup.com/docs/gift-cards/using-gift-cards-api
📖
APIReference
https://developer.squareup.com/reference/square/gift-cards-api
📖
Documentation
https://developer.squareup.com/docs/invoices-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/invoices-api
📖
Documentation
https://developer.squareup.com/docs/subscriptions-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/subscriptions-api
📖
Documentation
https://developer.squareup.com/docs/checkout-api
📖
APIReference
https://developer.squareup.com/reference/square/checkout-api
📖
Documentation
https://developer.squareup.com/docs/terminal-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/terminal-api
📖
Documentation
https://developer.squareup.com/docs/payments-refunds
📖
APIReference
https://developer.squareup.com/reference/square/refunds-api
📖
Documentation
https://developer.squareup.com/docs/disputes-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/disputes-api
📖
Documentation
https://developer.squareup.com/docs/merchants-api
📖
APIReference
https://developer.squareup.com/reference/square/merchants-api
📖
Documentation
https://developer.squareup.com/docs/cards-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/cards-api
📖
Documentation
https://developer.squareup.com/docs/vendors-api/manage-vendors-in-apps
📖
APIReference
https://developer.squareup.com/reference/square/vendors-api
📖
Documentation
https://developer.squareup.com/docs/cashdrawershift-api/reporting
📖
APIReference
https://developer.squareup.com/reference/square/cash-drawers-api
📖
Documentation
https://developer.squareup.com/docs/bank-accounts-api
📖
APIReference
https://developer.squareup.com/reference/square/bank-accounts-api
📖
Documentation
https://developer.squareup.com/docs/payouts-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/payouts-api
📖
Documentation
https://developer.squareup.com/docs/web-payments/apple-pay
📖
APIReference
https://developer.squareup.com/reference/square/apple-pay-api
📖
Documentation
https://developer.squareup.com/docs/sites-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/sites-api
📖
Documentation
https://developer.squareup.com/docs/snippets-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/snippets-api
📖
Documentation
https://developer.squareup.com/docs/oauth-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/oauth-api
📖
Documentation
https://developer.squareup.com/docs/webhooks/overview
📖
APIReference
https://developer.squareup.com/reference/square/webhook-subscriptions-api
📖
Documentation
https://developer.squareup.com/docs/events-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/events-api
📖
Documentation
https://developer.squareup.com/docs/devices-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/devices-api
📖
Documentation
https://developer.squareup.com/docs/customer-groups-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/customer-groups-api
📖
Documentation
https://developer.squareup.com/docs/customer-segments-api/what-it-does
📖
APIReference
https://developer.squareup.com/reference/square/customer-segments-api
📖
Documentation
https://developer.squareup.com/docs/gift-cards/using-gift-card-activities-api
📖
APIReference
https://developer.squareup.com/reference/square/gift-card-activities-api
📖
Documentation
https://developer.squareup.com/docs/customer-custom-attributes-api/overview
📖
APIReference
https://developer.squareup.com/reference/square/customer-custom-attributes-api

Specifications

Other Resources

OpenAPI Specification

square-inventory-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  version: '2.0'
  title: Square ApplePay Inventory API
  description: 'Supercharge Square for sellers of every size. Our entire connected commerce platform  from elegant hardware to a rich suite of Square APIs  is yours to build with. Whether youre developing an app or composing a bespoke solution, this is the place to make it happen. '
  termsOfService: https://connect.squareup.com/tos
  contact:
    name: Square Developer Platform
    email: developers@squareup.com
    url: https://squareup.com/developers
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  externalDocs:
    description: 'Read the official documentation here:'
    url: https://docs.connect.squareup.com/
  x-server-configuration:
    default-environment: production
    default-server: default
    environments:
    - name: production
      servers:
      - name: default
        url: https://connect.squareup.com
    - name: sandbox
      servers:
      - name: default
        url: https://connect.squareupsandbox.com
    - name: custom
      servers:
      - name: default
        url: '{custom_url}'
    parameters:
    - name: custom_url
      description: Sets the base URL requests are made to. Defaults to `https://connect.squareup.com`
      type: string
      example: https://connect.squareup.com
  x-square-generic-error-codes:
  - ACCESS_TOKEN_EXPIRED
  - ACCESS_TOKEN_REVOKED
  - API_VERSION_INCOMPATIBLE
  - APPLICATION_DISABLED
  - ARRAY_EMPTY
  - ARRAY_LENGTH_TOO_LONG
  - ARRAY_LENGTH_TOO_SHORT
  - BAD_CERTIFICATE
  - BAD_GATEWAY
  - BAD_REQUEST
  - CONFLICT
  - CONFLICTING_PARAMETERS
  - CURRENCY_MISMATCH
  - EXPECTED_ARRAY
  - EXPECTED_BASE64_ENCODED_BYTE_ARRAY
  - EXPECTED_BOOLEAN
  - EXPECTED_FLOAT
  - EXPECTED_INTEGER
  - EXPECTED_JSON_BODY
  - EXPECTED_MAP
  - EXPECTED_OBJECT
  - EXPECTED_STRING
  - FORBIDDEN
  - GATEWAY_TIMEOUT
  - GONE
  - IDEMPOTENCY_KEY_REUSED
  - INCORRECT_TYPE
  - INSUFFICIENT_SCOPES
  - INTERNAL_SERVER_ERROR
  - INVALID_ARRAY_VALUE
  - INVALID_CONTENT_TYPE
  - INVALID_CURSOR
  - INVALID_ENUM_VALUE
  - INVALID_FORM_VALUE
  - INVALID_SORT_ORDER
  - INVALID_SQUARE_VERSION_FORMAT
  - INVALID_TIME
  - INVALID_TIME_RANGE
  - INVALID_VALUE
  - LOCATION_MISMATCH
  - MAP_KEY_LENGTH_TOO_LONG
  - MAP_KEY_LENGTH_TOO_SHORT
  - MERCHANT_SUBSCRIPTION_NOT_FOUND
  - METHOD_NOT_ALLOWED
  - MISSING_REQUIRED_PARAMETER
  - NOT_ACCEPTABLE
  - NOT_FOUND
  - NOT_IMPLEMENTED
  - NO_FIELDS_SET
  - RATE_LIMITED
  - REQUEST_ENTITY_TOO_LARGE
  - REQUEST_TIMEOUT
  - SANDBOX_NOT_SUPPORTED
  - SERVICE_UNAVAILABLE
  - TOO_MANY_MAP_ENTRIES
  - UNAUTHORIZED
  - UNEXPECTED_VALUE
  - UNKNOWN_BODY_PARAMETER
  - UNKNOWN_QUERY_PARAMETER
  - UNPROCESSABLE_ENTITY
  - UNSUPPORTED_MEDIA_TYPE
  - V1_ACCESS_TOKEN
  - V1_APPLICATION
  - VALUE_EMPTY
  - VALUE_REGEX_MISMATCH
  - VALUE_TOO_HIGH
  - VALUE_TOO_LONG
  - VALUE_TOO_LOW
  - VALUE_TOO_SHORT
servers:
- url: https://connect.squareup.com
  variables: {}
tags:
- name: Inventory
paths:
  /v2/inventory/adjustment/{adjustment_id}:
    get:
      tags:
      - Inventory
      summary: Square Deprecated Retrieve Inventory Adjustment
      operationId: DeprecatedRetrieveInventoryAdjustment
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Deprecated version of [RetrieveInventoryAdjustment](api-endpoint:Inventory-RetrieveInventoryAdjustment) after the endpoint URL

        is updated to conform to the standard convention.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: RetrieveInventoryAdjustment
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: adjustment_id
        description: ID of the [InventoryAdjustment](entity:InventoryAdjustment) to retrieve.
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryAdjustmentResponse'
  /v2/inventory/adjustments/{adjustment_id}:
    get:
      tags:
      - Inventory
      summary: Square Retrieve Inventory Adjustment
      operationId: RetrieveInventoryAdjustment
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns the [InventoryAdjustment](entity:InventoryAdjustment) object

        with the provided `adjustment_id`.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: adjustment_id
        description: ID of the [InventoryAdjustment](entity:InventoryAdjustment) to retrieve.
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryAdjustmentResponse'
  /v2/inventory/batch-change:
    post:
      tags:
      - Inventory
      summary: Square Deprecated Batch Change Inventory
      operationId: DeprecatedBatchChangeInventory
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Deprecated version of [BatchChangeInventory](api-endpoint:Inventory-BatchChangeInventory) after the endpoint URL

        is updated to conform to the standard convention.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: BatchChangeInventory
      security:
      - oauth2:
        - INVENTORY_WRITE
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchChangeInventoryRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchChangeInventoryResponse'
  /v2/inventory/batch-retrieve-changes:
    post:
      tags:
      - Inventory
      summary: Square Deprecated Batch Retrieve Inventory Changes
      operationId: DeprecatedBatchRetrieveInventoryChanges
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Deprecated version of [BatchRetrieveInventoryChanges](api-endpoint:Inventory-BatchRetrieveInventoryChanges) after the endpoint URL

        is updated to conform to the standard convention.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: BatchRetrieveInventoryChanges
      security:
      - oauth2:
        - INVENTORY_READ
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchRetrieveInventoryChangesRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchRetrieveInventoryChangesResponse'
  /v2/inventory/batch-retrieve-counts:
    post:
      tags:
      - Inventory
      summary: Square Deprecated Batch Retrieve Inventory Counts
      operationId: DeprecatedBatchRetrieveInventoryCounts
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Deprecated version of [BatchRetrieveInventoryCounts](api-endpoint:Inventory-BatchRetrieveInventoryCounts) after the endpoint URL

        is updated to conform to the standard convention.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: BatchRetrieveInventoryCounts
      security:
      - oauth2:
        - INVENTORY_READ
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchRetrieveInventoryCountsRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchRetrieveInventoryCountsResponse'
  /v2/inventory/changes/batch-create:
    post:
      tags:
      - Inventory
      summary: Square Batch Change Inventory
      operationId: BatchChangeInventory
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Applies adjustments and counts to the provided item quantities.


        On success: returns the current calculated counts for all objects

        referenced in the request.

        On failure: returns a list of related errors.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_WRITE
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchChangeInventoryRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchChangeInventoryResponse'
  /v2/inventory/changes/batch-retrieve:
    post:
      tags:
      - Inventory
      summary: Square Batch Retrieve Inventory Changes
      operationId: BatchRetrieveInventoryChanges
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns historical physical counts and adjustments based on the

        provided filter criteria.


        Results are paginated and sorted in ascending order according their

        `occurred_at` timestamp (oldest first).


        BatchRetrieveInventoryChanges is a catch-all query endpoint for queries

        that cannot be handled by other, simpler endpoints.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_READ
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchRetrieveInventoryChangesRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchRetrieveInventoryChangesResponse'
  /v2/inventory/counts/batch-retrieve:
    post:
      tags:
      - Inventory
      summary: Square Batch Retrieve Inventory Counts
      operationId: BatchRetrieveInventoryCounts
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns current counts for the provided

        [CatalogObject](entity:CatalogObject)s at the requested

        [Location](entity:Location)s.


        Results are paginated and sorted in descending order according to their

        `calculated_at` timestamp (newest first).


        When `updated_after` is specified, only counts that have changed since that

        time (based on the server timestamp for the most recent change) are

        returned. This allows clients to perform a "sync" operation, for example

        in response to receiving a Webhook notification.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_READ
      parameters: []
      requestBody:
        required: true
        description: 'An object containing the fields to POST for the request.


          See the corresponding object definition for field details.'
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchRetrieveInventoryCountsRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchRetrieveInventoryCountsResponse'
  /v2/inventory/physical-count/{physical_count_id}:
    get:
      tags:
      - Inventory
      summary: Square Deprecated Retrieve Inventory Physical Count
      operationId: DeprecatedRetrieveInventoryPhysicalCount
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Deprecated version of [RetrieveInventoryPhysicalCount](api-endpoint:Inventory-RetrieveInventoryPhysicalCount) after the endpoint URL

        is updated to conform to the standard convention.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: RetrieveInventoryPhysicalCount
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: physical_count_id
        description: 'ID of the

          [InventoryPhysicalCount](entity:InventoryPhysicalCount) to retrieve.'
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryPhysicalCountResponse'
  /v2/inventory/physical-counts/{physical_count_id}:
    get:
      tags:
      - Inventory
      summary: Square Retrieve Inventory Physical Count
      operationId: RetrieveInventoryPhysicalCount
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns the [InventoryPhysicalCount](entity:InventoryPhysicalCount)

        object with the provided `physical_count_id`.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: physical_count_id
        description: 'ID of the

          [InventoryPhysicalCount](entity:InventoryPhysicalCount) to retrieve.'
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryPhysicalCountResponse'
  /v2/inventory/transfers/{transfer_id}:
    get:
      tags:
      - Inventory
      summary: Square Retrieve Inventory Transfer
      operationId: RetrieveInventoryTransfer
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns the [InventoryTransfer](entity:InventoryTransfer) object

        with the provided `transfer_id`.'
      x-release-status: BETA
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: transfer_id
        description: ID of the [InventoryTransfer](entity:InventoryTransfer) to retrieve.
        schema:
          type: string
        in: path
        required: true
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryTransferResponse'
  /v2/inventory/{catalog_object_id}:
    get:
      tags:
      - Inventory
      summary: Square Retrieve Inventory Count
      operationId: RetrieveInventoryCount
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Retrieves the current calculated stock count for a given

        [CatalogObject](entity:CatalogObject) at a given set of

        [Location](entity:Location)s. Responses are paginated and unsorted.

        For more sophisticated queries, use a batch endpoint.'
      x-release-status: PUBLIC
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: catalog_object_id
        description: ID of the [CatalogObject](entity:CatalogObject) to retrieve.
        schema:
          type: string
        in: path
        required: true
      - name: location_ids
        description: 'The [Location](entity:Location) IDs to look up as a comma-separated

          list. An empty list queries all locations.'
        schema:
          type: string
        in: query
        required: false
      - name: cursor
        description: 'A pagination cursor returned by a previous call to this endpoint.

          Provide this to retrieve the next set of results for the original query.


          See the [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination) guide for more information.'
        schema:
          type: string
        in: query
        required: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryCountResponse'
  /v2/inventory/{catalog_object_id}/changes:
    get:
      tags:
      - Inventory
      summary: Square Retrieve Inventory Changes
      operationId: RetrieveInventoryChanges
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
      description: 'Returns a set of physical counts and inventory adjustments for the

        provided [CatalogObject](entity:CatalogObject) at the requested

        [Location](entity:Location)s.


        You can achieve the same result by calling [BatchRetrieveInventoryChanges](api-endpoint:Inventory-BatchRetrieveInventoryChanges)

        and having the `catalog_object_ids` list contain a single element of the `CatalogObject` ID.


        Results are paginated and sorted in descending order according to their

        `occurred_at` timestamp (newest first).


        There are no limits on how far back the caller can page. This endpoint can be

        used to display recent changes for a specific item. For more

        sophisticated queries, use a batch endpoint.'
      x-release-status: DEPRECATED
      deprecated: true
      x-deprecation:
        deprecationDate: '2021-06-16'
        retirementDate: '2023-11-15'
        replacedBy: BatchRetrieveInventoryChanges
      security:
      - oauth2:
        - INVENTORY_READ
      parameters:
      - name: catalog_object_id
        description: ID of the [CatalogObject](entity:CatalogObject) to retrieve.
        schema:
          type: string
        in: path
        required: true
      - name: location_ids
        description: 'The [Location](entity:Location) IDs to look up as a comma-separated

          list. An empty list queries all locations.'
        schema:
          type: string
        in: query
        required: false
      - name: cursor
        description: 'A pagination cursor returned by a previous call to this endpoint.

          Provide this to retrieve the next set of results for the original query.


          See the [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination) guide for more information.'
        schema:
          type: string
        in: query
        required: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveInventoryChangesResponse'
components:
  schemas:
    MeasurementUnitVolume:
      type: string
      enum:
      - GENERIC_FLUID_OUNCE
      - GENERIC_SHOT
      - GENERIC_CUP
      - GENERIC_PINT
      - GENERIC_QUART
      - GENERIC_GALLON
      - IMPERIAL_CUBIC_INCH
      - IMPERIAL_CUBIC_FOOT
      - IMPERIAL_CUBIC_YARD
      - METRIC_MILLILITER
      - METRIC_LITER
      x-enum-elements:
      - name: GENERIC_FLUID_OUNCE
        description: The volume is measured in ounces.
      - name: GENERIC_SHOT
        description: The volume is measured in shots.
      - name: GENERIC_CUP
        description: The volume is measured in cups.
      - name: GENERIC_PINT
        description: The volume is measured in pints.
      - name: GENERIC_QUART
        description: The volume is measured in quarts.
      - name: GENERIC_GALLON
        description: The volume is measured in gallons.
      - name: IMPERIAL_CUBIC_INCH
        description: The volume is measured in cubic inches.
      - name: IMPERIAL_CUBIC_FOOT
        description: The volume is measured in cubic feet.
      - name: IMPERIAL_CUBIC_YARD
        description: The volume is measured in cubic yards.
      - name: METRIC_MILLILITER
        description: The volume is measured in metric milliliters.
      - name: METRIC_LITER
        description: The volume is measured in metric liters.
      description: The unit of volume used to measure a quantity.
      x-release-status: PUBLIC
    InventoryAdjustment:
      type: object
      description: 'Represents a change in state or quantity of product inventory at a

        particular time and location.'
      x-release-status: PUBLIC
      properties:
        id:
          type: string
          description: 'A unique ID generated by Square for the

            `InventoryAdjustment`.'
          maxLength: 100
        reference_id:
          type: string
          description: 'An optional ID provided by the application to tie the

            `InventoryAdjustment` to an external

            system.'
          maxLength: 255
          nullable: true
        from_state:
          $ref: '#/components/schemas/InventoryState'
          description: 'The [inventory state](entity:InventoryState) of the related quantity

            of items before the adjustment.

            See [InventoryState](#type-inventorystate) for possible values'
          nullable: true
        to_state:
          $ref: '#/components/schemas/InventoryState'
          description: 'The [inventory state](entity:InventoryState) of the related quantity

            of items after the adjustment.

            See [InventoryState](#type-inventorystate) for possible values'
          nullable: true
        location_id:
          type: string
          description: 'The Square-generated ID of the [Location](entity:Location) where the related

            quantity of items is being tracked.'
          maxLength: 100
          nullable: true
        catalog_object_id:
          type: string
          description: 'The Square-generated ID of the

            [CatalogObject](entity:CatalogObject) being tracked.'
          maxLength: 100
          nullable: true
        catalog_object_type:
          type: string
          description: "The [type](entity:CatalogObjectType) of the [CatalogObject](entity:CatalogObject) being tracked. \n\nThe Inventory API supports setting and reading the `\"catalog_object_type\": \"ITEM_VARIATION\"` field value. \nIn addition, it can also read the `\"catalog_object_type\": \"ITEM\"` field value that is set by the Square Restaurants app."
          maxLength: 14
          nullable: true
        quantity:
          type: string
          description: 'The number of items affected by the adjustment as a decimal string.

            Can support up to 5 digits after the decimal point.'
          maxLength: 26
          nullable: true
        total_price_money:
          $ref: '#/components/schemas/Money'
          description: 'The total price paid for goods associated with the

            adjustment. Present if and only if `to_state` is `SOLD`. Always

            non-negative.'
          readOnly: true
        occurred_at:
          type: string
          description: 'A client-generated RFC 3339-formatted timestamp that indicates when

            the inventory adjustment took place. For inventory adjustment updates, the `occurred_at`

            timestamp cannot be older than 24 hours or in the future relative to the

            time of the request.'
          maxLength: 34
          nullable: true
        created_at:
          type: string
          description: An RFC 3339-formatted timestamp that indicates when the inventory adjustment is received.
          maxLength: 34
          readOnly: true
        source:
          $ref: '#/components/schemas/SourceApplication'
          description: 'Information about the application that caused the

            inventory adjustment.'
          readOnly: true
        employee_id:
          type: string
          description: 'The Square-generated ID of the [Employee](entity:Employee) responsible for the

            inventory adjustment.'
          maxLength: 100
          nullable: true
        team_member_id:
          type: string
          description: 'The Square-generated ID of the [Team Member](entity:TeamMember) responsible for the

            inventory adjustment.'
          maxLength: 100
          nullable: true
        transaction_id:
          type: string
          description: 'The Square-generated ID of the [Transaction](entity:Transaction) that

            caused the adjustment. Only relevant for payment-related state

            transitions.'
          maxLength: 255
          readOnly: true
        refund_id:
          type: string
          description: 'The Square-generated ID of the [Refund](entity:Refund) that

            caused the adjustment. Only relevant for refund-related state

            transitions.'
          maxLength: 255
          readOnly: true
        purchase_order_id:
          type: string
          description: 'The Square-generated ID of the purchase order that caused the

            adjustment. Only relevant for state transitions from the Square for Retail

            app.'
          maxLength: 100
          readOnly: true
        goods_receipt_id:
          type: string
          description: 'The Square-generated ID of the goods receipt that caused the

            adjustment. Only relevant for state transitions from the Square for Retail

            app.'
          maxLength: 100
          readOnly: true
        adjustment_group:
          $ref: '#/components/schemas/InventoryAdjustmentGroup'
          description: An adjustment group bundling the related adjustments of item variations through stock conversions in a single inventory event.
          readOnly: true
          x-release-status: BETA
    ErrorCategory:
      type: string
      enum:
      - API_ERROR
      - AUTHENTICATION_ERROR
      - INVALID_REQUEST_ERROR
      - RATE_LIMIT_ERROR
      - PAYMENT_METHOD_ERROR
      - REFUND_ERROR
      - MERCHANT_SUBSCRIPTION_ERROR
      - EXTERNAL_VENDOR_ERROR
      x-enum-elements:
      - name: API_ERROR
        description: An error occurred with the Connect API itself.
      - name: AUTHENTICATION_ERROR
        description: 'An authentication error occurred. Most commonly, the request had

          a missing, malformed, or otherwise invalid `Authorization` header.'
      - name: INVALID_REQUEST_ERROR
        description: 'The request was invalid. Most commonly, a required parameter was

          missing, or a provided parameter had an invalid value.'
      - name: RATE_LIMIT_ERROR
        description: 'Your application reached the Square API rate limit. You might receive this error if your application sends a high number of requests

          to Square APIs in a short period of time.


          Your application should monitor responses for `429 RATE_LIMITED` errors and use a retry mechanism with an [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff)

          schedule to resend the requests at an increasingly slower rate. It is also a good practice to use a randomized delay (jitter) in your retry schedule.'
      - name: PAYMENT_METHOD_ERROR
        description: 'An error occurred while processing a payment method. Most commonly,

          the details of the payment method were invalid (such as a card''s CVV

          or expiration date).'
      - name: REFUND_ERROR
        description: An error occurred while attempting to process a refund.
      - name: MERCHANT_SUBSCRIPTION_ERROR
        description: An error occurred when checking a merchant subscription status
      - name: EXTERNAL_VENDOR_ERROR
        description: An error that is returned from an external vendor's API
      description: 'Indicates which high-level category of error has occurred during a

        request to the Connect API.'
      x-release-status: PUBLIC
    ErrorCode:
      type: string
      enum:
      - INTERNAL_SERVER_ERROR
      - UNAUTHORIZED
      - ACCESS_TOKEN_EXPIRED
      - ACCESS_TOKEN_REVOKED
      - CLIENT_DISABLED
      - FORBIDDEN
      - INSUFFICIENT_SCOPES
      - APPLICATION_DISABLED
      - V1_APPLICATION
      - V1_ACCESS_TOKEN
      - CARD_PROCESSING_NOT_ENABLED
      - MERCHANT_SUBSCRIPTION_NOT_FOUND
      - BAD_REQUEST
      - MISSING_REQUIRED_PARAMETER
      - INCORRECT_TYPE
      - INVALID_TIME
      - INVALID_TIME_RANGE
      - INVALID_VALUE
      - INVALID_CURSOR
      - UNKNOWN_QUERY_PARAMETER
      - CONFLICTING_PARAMETERS
      - EXPECTED_JSON_BODY
      - INVALID_SORT_ORDER
      - VALUE_REGEX_MISMATCH
      - VALUE_TOO_SHORT
      - VALUE_TOO_LONG
      - VALUE_TOO_LOW
      - VALUE_TOO_HIGH
      - VALUE_EMPTY
      - ARRAY_LENGTH_TOO_LONG
      - ARRAY_LENGTH_TOO_SHORT
      - ARRAY_EMPTY
      - EXPECTED_BOOLEAN
      - EXPECTED_INTEGER
      - EXPECTED_FLOAT
      - EXPECTED_STRING
      - EXPECTED_OBJECT
      - EXPECTED_ARRAY
      - EXPECTED_MAP
      - EXPECTED_BASE64_ENCODED_BYTE_ARRAY
      - INVALID_ARRAY_VALUE
      - INVALID_ENUM_VALUE
      - INVALID_CONTENT_TYPE
      - INVALID_FORM_VALUE
      - CUSTOMER_NOT_FOUND
      - ONE_INSTRUMENT_EXPECTED
      - NO_FIELDS_SET
      - TOO_MANY_MAP_ENTRIES
      - MAP_KEY_LENGTH_TOO_SHORT
      - MAP_KEY_LENGTH_TOO_LONG
      - CUSTOMER_MISSING_NAME
      - CUSTOMER_MISSING_EMAIL
      - INVALID_PAUSE_LENGTH
      - INVALID_DATE
      - UNSUPPORTED_COUNTRY
      - UNSUPPORTED_CURRENCY
      - APPLE_TTP_PIN_TOKEN
      - CARD_EXPIRED
      - INVALID_EXPIRATION
      - INVALID_EXPIRATION_YEAR
      - INVALID_EXPIRATION_DATE
      - UNSUPPORTED_CARD_BRAND
      - UNSUPPORTED_ENTRY_METHOD
      - INVALID_ENCRYPTED_CARD
      - INVALID_CARD
      - PAYMENT_AMOUNT_MISMATCH
      - GENERIC_DECLINE
      - CVV_FAILURE
      - ADDRESS_VERIFICATION_FAILURE
      - INVALID_ACCOUNT
      - CURRENCY_MISMATCH
      - INSUFFICIENT_FUNDS
      - INSUFFICIENT_PERMISSIONS
      - CARDHOLDER_INSUFFICIENT_PERMISSIONS
      - INVALID_LOCATION
      - TRANSACTION_LIMIT
      - VOICE_FAILURE
      - PAN_FAILURE
      - EXPIRATION_FAILURE
      - CARD_NOT_SUPPORTED
      - INVALID_PIN
      - MISSING_PIN
      - MISSING_ACCOUNT_TYPE
      - INVALID_POSTAL_CODE
      - INVALID_FEES
      - MANUALLY_ENTERED_PAYMENT_NOT_SUPPORTED
      - PAYMENT_LIMIT_EXCEEDED
      - GIFT_CARD_AVAILABLE_AMOUNT
      - ACCOUNT_UNUSABLE
      - BUYER_REFUSED_PAYMENT
      - DELAYED_TRANSACTION_EXPIRED
      - DELAYED_TRANSACTION_CANCELED
      - DELAYED_TRANSACTION_CAPTURED
      - DELAYED_TRANSACTION_FAILED
      - CARD_TOKEN_EXPIRED
      - CARD_TOKEN_USED
      - AMOUNT_TOO_HIGH
      - UNSUPPORTED_INSTRUMENT_TYPE
      - REFUND_AMOUNT_INVALID
      - REFUND_ALREADY_PENDING
      - PAYMENT_NOT_REFUNDABLE
      - PAYMENT_NOT_REFUNDABLE_DUE_TO_DISPUTE
      - REFUND_DECLINED
      - INSUFFICIENT_PERMISSIONS_FOR_REFUND
      - INVALID_CARD_DATA
      - SOURCE_USED
      - SOURCE_EXPIRED
      - UNSUPPORTED_LOYALTY_REWARD_TIER
      - LOCATION_MISMATCH
      - IDEMPOTENCY_KEY_REUSED
      - UNEXPECTED_VALUE
      - SANDBOX_NOT_SUPPORTED
      - INVALID_EMAIL_ADDRESS
      - INVALID_PHONE_NUMBER
      - CHECKOUT_EXPIRED
      - BAD_CERTIFICATE
      - INVALID_SQUARE_VERSION_FORMAT
      - API_VERSION_INCOMPATIBLE
      - CARD_PRESENCE_REQUIRED
      - UNSUPPORTED_SOURCE_TYPE
      - CARD_MISMATCH
      - PLAID_ERROR
      - PLAID_ERROR_ITEM_LOGIN_REQUIRED
      - PLAID_ERROR_RATE_LIMIT
      - CARD_DECLINED
      - VERIFY_CVV_FAILURE
      - VERIFY_AVS_FAILURE
      - CARD_DECLINED_CALL_ISSUER
      - CARD_DECLIN

# --- truncated at 32 KB (131 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/square/refs/heads/main/openapi/square-inventory-api-openapi.yml