Update tills in bulk

Update up to 50 tills in a single request.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Update tills in bulk

Update up to 50 tills in a single request. Each row is validated and persisted independently — a failure in one item does not block the others. The response reflects the outcome of each item individually, and the HTTP status reflects the overall result: 200 if all items succeeded, 207 if some failed, or 400 if all failed.

Each row identifies the till to update using identifierName and identifierValue. All other fields are optional and use patch semantics: fields absent from the request JSON are left unchanged. Null and patch semantics vary per field — see the body parameters table for the exact behavior of each field.

Example request

curl -X PUT "https://{host}/v2/locations/tills" \
  -H "Authorization: Basic {base64-encoded-credentials}" \
  -H "X-CAP-API-AUTH-ORG-ID: {orgId}" \
  -H "Content-Type: application/json" \
  -d '[
    {
      "identifierName": "CODE",
      "identifierValue": "till-north-01",
      "name": "North Till Primary",
      "externalIds": {
        "erpId": "ERP-TILL-001"
      },
      "customFields": {
        "till_cf1": "value1"
      }
    }
  ]'

Prerequisites

  • Authenticate using Basic authentication (Base64-encoded username:password).

Body parameters

Pass a JSON array of till update objects. Maximum 50 items per request.

Note: The Updatable column indicates whether the field can be changed after creation. identifierName and identifierValue identify the target till and are never updated themselves.

FieldTypeRequiredDescriptionUpdatable
identifierNamestringRequiredHow the target till is identified. Must be one of: ID (internal system ID), CODE (till code), EXTERNAL_ID (external identifier value). Case-insensitive.No
identifierValuestringRequiredThe identifier value matching identifierName.No
namestringOptionalDisplay name for the till. Cannot be set to null or empty. Max 100 characters. Accepts letters, digits, underscores, and spaces.Yes
descriptionstringOptionalFree-text description. Set to null to clear the stored value.Yes
isAdminbooleanOptionalWhether the till has admin access.Yes
isActivebooleanOptionalWhether the till is active. Activation fails if the parent store is inactive. Deactivation fails if the till has active child entities.Yes
storeParentCodestringOptionalCode of the parent store. Cannot be set to null. Provide a valid store code to change the parent store.Yes
externalIdsobjectOptionalKey-value map of external identifiers ({"typeName": "value"}). Omit to preserve existing values. Pass null to clear all external identifiers. Pass {} to make no change. Set a key's value to null to remove that specific key. Maximum five entries. Keys and values must not exceed 200 characters each.Yes
customFieldsobjectOptionalKey-value map of custom field values. Omit to preserve existing values. Pass null to clear all custom field values. Pass {} to make no change. Set a key's value to null to remove that specific key. Keys must match custom fields configured for the org.Yes

Example response

{
  "response": [
    {
      "entityId": 76500001,
      "result": {
        "identifierName": "CODE",
        "identifierValue": "till-north-01",
        "name": "North Till Primary",
        "externalIds": {
          "erpId": "ERP-TILL-001"
        },
        "customFields": {
          "till_cf1": "value1"
        }
      },
      "errors": [],
      "warnings": []
    }
  ],
  "totalCount": 1,
  "failureCount": 0
}

Partial failure example (HTTP 207):

{
  "response": [
    {
      "entityId": 76500001,
      "result": {
        "identifierName": "CODE",
        "identifierValue": "till-north-01",
        "name": "North Till Primary"
      },
      "errors": [],
      "warnings": []
    },
    {
      "result": {
        "identifierName": "CODE",
        "identifierValue": "till-does-not-exist"
      },
      "errors": [
        {
          "status": false,
          "code": 1260,
          "message": "till not found for passed identifiers"
        }
      ],
      "warnings": []
    }
  ],
  "totalCount": 2,
  "failureCount": 1
}

Response parameters

FieldTypeDescription
responsearrayOne entry per input item, in the same order as the request.
.entityIdintegerSystem-assigned ID of the updated till. Present when the till was identified, regardless of whether the update succeeded. Absent when the till could not be identified, or when an unexpected error occurs.
.resultobjectObject containing the fields submitted for this till, echoed from the request. Present for all items regardless of success or failure.
.errorsarrayErrors for this item. Empty when the item succeeded.
..codeintegerNumeric error code.
..messagestringError message.
..statusbooleanStatus flag for the error entry.
.warningsarrayNon-fatal warnings for this item. The till update may still succeed even when warnings are present.
..codeintegerNumeric warning code.
..messagestringWarning message.
..statusbooleanStatus flag for the warning entry.
totalCountintegerTotal number of items in the request.
failureCountintegerNumber of items that failed to update.

Error & warning codes

CodeError numberTypeDescription
BULK_REQUEST_LIMIT_EXCEEDED1246ErrorThe request contains more than 50 items. Maximum allowed is 50. HTTP 400.
IDENTIFIER_REQUIRED1249ErroridentifierName or identifierValue is missing or blank. HTTP 400.
INVALID_IDENTIFIER_TYPE1250ErroridentifierName must be ID, CODE, or EXTERNAL_ID. HTTP 400.
IDENTIFIER_VALUE_INVALID1251ErroridentifierValue is not a valid integer when identifierName is ID. HTTP 400.
TILL_NAME_NOT_FOUND1260ErrorTill not found for the given ID, CODE, or EXTERNAL_ID. HTTP 400.
DUPLICATE_ENTITY_IN_REQUEST1253ErrorTwo or more rows in the request resolve to the same till. HTTP 207 (first wins — the first occurrence in the batch is updated; later duplicates are rejected).
NAME_ALREADY_EXISTS_ORG1206ErrorA name in the request matches another till in the org, or two rows in the batch share the same name. HTTP 207 (first wins).
NAME_CANNOT_BE_NULL1252Errorname is set to null or an empty string. HTTP 400.
REGEX_MATCH_FAILED1219Errorname contains characters that are not letters, digits, underscores, or spaces. HTTP 400.
NAME_LENGTH_EXCEEDS_LIMIT1264Errorname exceeds 100 characters. HTTP 400.
PARAM_TYPE_IS_NOT_VALID1217ErrorstoreParentCode does not match an active store in the org; or a customFields key does not match a configured custom field for the org; or adding external identifiers would exceed the five-entry limit. HTTP 400.
GLOBAL_ERR_MISSING_MANDATORY_FIELD403ErrorThe parent store referenced by storeParentCode is missing a required locale (timezone, language, or currency); or an externalIds key or value is blank. HTTP 400.
PARENT_NOT_ACTIVE1258ErrorisActive is set to true but the parent store is inactive. HTTP 400.
CHILDREN_STILL_ACTIVE1259ErrorisActive is set to false but the till has active child entities. HTTP 400.
DUPLICATE_EXTERNAL_ID_IN_REQUEST1248ErrorDuplicate values in externalIds within the same request. HTTP 400.
EXTERNAL_ID_ALREADY_EXISTS_ORG1245ErrorOne or more externalIds values are already assigned to another entity in the org. HTTP 400.
EXTERNAL_ID_KEY_TOO_LONG1261ErrorAn externalIds key exceeds 200 characters. HTTP 400.
EXTERNAL_ID_VALUE_TOO_LONG1262ErrorAn externalIds value exceeds 200 characters. HTTP 400.
Body Params
Responses

Language
Credentials
Basic
base64
:
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json