Skip to main content

Device aisles

Applies to: API integrators with third-party API access.

Use Content-Type: application/json and optionally X-Locale: en. The third-api-token header is required. See common headers and error handling.

Brief Description

  • Query aisle hierarchy information for a single device (cabinets / layers / aisles)
  • deviceCode is required; only one device can be queried per request
  • Data scope follows the user identity and groupId associated with the Token; the device must be within the current permission scope

Request URL

  • https://{GATEWAY_HOST}/third-center-web/openapi/v1/phamboxDevice/deviceInfo

Request Method

  • POST
Parameter NameRequiredTypeDescription
third-api-tokenYesstringAccess token obtained from the login interface

Parameters

Request Body:

Parameter NameRequiredTypeDescription
deviceCodeYesstringDevice code (single device only)

Response Example

{
"code": 200,
"msg": "success",
"enMsg": null,
"data": [
{
"deviceId": "dev-001",
"deviceCode": "KIOSK-001",
"deviceName": "Lobby Kiosk A",
"cabinetTotal": 1,
"layerTotal": 5,
"aisleTotal": 40,
"cabinets": [],
"cabinetAttrList": []
}
]
}

Response Parameter Description

Response data: An array on success, normally containing zero or one device. An empty result is [].

Errors: data may be null, a string or an array of messages. Check the HTTP status and code before reading success data. See error handling.

Response (data is an array; normally 0 or 1 item for a single-device query):

Parameter NameTypeDescription
deviceIdstringDevice ID
deviceCodestringDevice code
deviceNamestringDevice name
cabinetTotalintNumber of cabinets
layerTotalintTotal number of layers across cabinets
aisleTotalintTotal number of aisles
cabinetsarrayCabinet hierarchy details; see the nested fields below
cabinetAttrListarray / nullModel-specific cabinet attributes; see the extension-data note below

Cabinet and layer fields

The following paths are relative to one device in data[].

FieldTypeDescription
cabinets[].codeintZero-based cabinet number
cabinets[].layerCountintNumber of layers in this cabinet
cabinets[].doorStatusint / null1 open / 0 closed when populated; null when unavailable. Use Device profile for door telemetry
cabinets[].layersarrayLayers belonging to the cabinet
cabinets[].layers[].layerstringLayer label, such as A
cabinets[].layers[].aisleCountintNumber of aisles in the layer
cabinets[].layers[].aislesarrayAisle objects, described below

Aisle fields

These fields belong to each data[].cabinets[].layers[].aisles[] object. Optional product metadata, settings and extension values can be null or absent; the types below describe non-null values. Handle fields independently rather than requiring every field for every device model.

FieldTypeDescription
idstringAisle record ID
cabinetintZero-based cabinet number
layerstringLayer label
codestringFull aisle code, such as 0-A0
showNamestringAisle display name
shippingModeintDevice shipment-mode code; values depend on the supported model
ctrlBoardintController-board number
ctrlCmdintController command value; informational in this query API
measurementintMeasurement code: 0 pieces, 1 weight in grams; preserve other codes and confirm their unit
priceintActual selling price in the product currency's minor units
showPriceintDisplay price in minor units
maxStockintCapacity in the configured measurement unit
currStockintAvailable stock after subtracting cached stock reservations; may differ from a raw inventory total
orderintConfigured sort value; do not assume the returned arrays are sorted by it
statusintAisle status; 1 indicates normal
remarkstringAisle remark
isHotintHot-item flag as stored by the device configuration
isCombineintCombined aisle flag: 0 no / 1 yes
isEnablebooleanWhether the aisle is enabled; JSON boolean, not an integer flag
isBrokenbooleanWhether the aisle is marked faulty; JSON boolean
goodsIdstringAssigned product ID
goodsNamestringProduct name
goodsCodestringProduct code
goodsCustomCodestringCustom product code
barcodestringProduct barcode / SKU
currencystringProduct currency code used for aisle prices
imgUrlstringProduct image URL
thumbnailUrlstringProduct thumbnail URL
weightintProduct weight in its configured measurement convention
recognitionWeightintWeight-recognition value, when calculated; do not assume it equals stock
packTypestringPackaging type
expirationTimestamplongProduct expiration timestamp in milliseconds
warningDayintExpiration warning lead time in days
goodsDescriptionstringProduct description
goodsRemarkstringProduct remark
goodsTypeListarrayProduct categories; each item contains string fields id, code and name
goodsExtendObjectobjectProduct-specific extension data; keys depend on product configuration

Model-specific extension data

cabinetAttrList contains JSON values configured on the device model, passed through without a fixed OpenAPI item schema. It can be empty or null. goodsExtendObject likewise has configuration-specific keys. Preserve or ignore unrecognized keys; obtain the intended model's field and unit definitions from the platform operator before depending on an extension. These extensions are not a replacement for the cabinet/layer/aisle fields above.

Notes

  • If deviceCode is missing or blank, the API returns a business error.
  • If the device is not within the current Token group permission scope, the API returns a business error (phambox.scope.deviceNotInScope).