Skip to main content

Container Management API

Version 1.0 — April 2026

Authentication: All requests require an IdToken from the Login API. See Authentication to obtain one and Errors for authorization errors.

Types​

Container​

All mutations and queries that return a container use this type.

PropertyTypeDescription
idStringUnique identifier for the container
nameStringDisplay name of the container
descriptionStringDescription of the container
trackerSerialStringRFID tag associated with the container
typeContainerTypeThe container type (see ContainerType)
commentsStringComments or remarks for the container
images[String]List of image URLs associated with the container
locationLocationCurrent assigned location (see Location)
lastDetectedAtLocationLocationLast location where the container was detected (see Location)
creationDateAWSTimestampTimestamp when the container was created
lastUpdatedDateAWSTimestampTimestamp when the container was last updated
assetIds[String]IDs of assets inside the container
childContainerIds[String]IDs of child containers nested inside this container
inventoryIds[String]IDs of inventory items inside the container
packageIds[String]IDs of packages inside the container
parentContainerIdStringID of the parent container (if nested)
customPropertiesAWSJSONAdditional custom properties for the container

ContainerType​

PropertyTypeDescription
idStringContainer type identifier
nameStringContainer type name
descriptionStringContainer type description
customPropertiesAWSJSONAdditional properties for the type

Location​

PropertyTypeDescription
idStringLocation identifier
nameStringLocation name

Create Container API​

Create Container API allows you to create a container with optional contents (assets, inventory items, packages, or child containers). A tracker serial (RFID tag) can be optionally assigned.

When adding contents, you can:

  • Use existing records: provide the existing id for an Asset / Inventory item / Package to associate it with the container.
  • Create a new item as part of the workflow — provide the inputs you would use in the regular Asset / Inventory / Package create flows so the item is created and associated to the container in the same request.

Endpoint Details​

  • URL: https://api.xemelgo.com/graphql
  • Method: POST

Properties​

PropertyTypeDescriptionRequired
idStringUnique identifier for the containerYes
typeIdStringThe Container Type identifier to associate with this containerNo
trackerSerialStringRFID tag associated with the container for trackingNo
reuseTrackerSerialBooleanWhether to reuse the tracker serial if it already existsNo
nameStringDisplay name for the containerNo
descriptionStringDescription of the containerNo
commentsStringAny comments or remarks for the containerNo
locationIdStringThe location to associate with the containerNo
customPropertiesAWSJSONAdditional custom properties for the containerNo
assets[Asset Input]Assets to place inside the container (see table below)No
childContainerIds[String]IDs of existing containers to nest inside this containerNo
inventory[Inventory Input]Inventory to place inside the container (see table below)No
packages[Package Input]Packages to place inside the container (see table below)No

Asset Input​

PropertyTypeDescriptionRequired
idStringExisting Asset ID to add to the containerYes
typeIdStringAsset type identifierNo
locationIdStringLocation identifier for the assetNo
trackerSerialStringRFID tag for the assetNo
reuseTrackerSerialBooleanWhether to reuse the tracker serialNo
nameStringAsset nameNo
descriptionStringAsset descriptionNo
dueDateAWSTimestampDue date for maintenance or calibrationNo
images[String]List of image URLs for the assetNo
commentsStringComments or remarks for the assetNo
customPropertiesAWSJSONAdditional custom properties for the assetNo

Inventory Input​

PropertyTypeDescriptionRequired
idStringExisting Inventory item ID to add to the containerYes
partIdStringPart identifierNo
locationIdStringLocation identifier for the inventory itemNo
trackerSerialStringRFID tag for the inventory itemNo
reuseTrackerSerialBooleanWhether to reuse the tracker serialNo
nameStringInventory item nameNo
descriptionStringInventory item descriptionNo
commentsStringComments or remarksNo
expirationDateAWSTimestampExpiration date for the inventory itemNo
images[String]List of image URLsNo
lotNumberStringLot number for the inventory itemNo
quantityFloatQuantity of the inventory itemNo
customPropertiesAWSJSONAdditional custom propertiesNo

Package Input​

PropertyTypeDescriptionRequired
idStringExisting Package ID to add to the containerYes
trackerSerialStringRFID tag for the packageNo
reuseTrackerSerialBooleanWhether to reuse the tracker serialNo
nameStringPackage nameNo
descriptionStringPackage descriptionNo
commentsStringComments or remarksNo
locationIdStringLocation identifier for the packageNo
customPropertiesAWSJSONAdditional custom properties for the packageNo

Headers​

Authorization – $idToken

Response Properties​

Returns a Container object.

Request Body​

mutation {
createContainer(
input: {
id: "CONTAINER-001"
typeId: "Bin"
trackerSerial: "20240801000001"
locationId: "Warehouse A"
name: "Container 001"
description: "Main storage bin"
comments: "Handle with care"
assets: [
{
id: "ASSET-001"
typeId: "Handheld"
trackerSerial: "20240801000002"
locationId: "Warehouse A"
}
]
inventory: [
{
id: "INV-001"
partId: "PART-123"
quantity: 10
lotNumber: "LOT-2024-01"
}
]
}
) {
container {
id
name
trackerSerial
type {
id
name
}
location {
id
name
}
assetIds
inventoryIds
}
}
}

Status Code - 200

Response Body​

{
"data": {
"createContainer": {
"container": {
"id": "CONTAINER-001",
"name": "Container 001",
"trackerSerial": "20240801000001",
"type": {
"id": "Bin",
"name": "Bin"
},
"location": {
"id": "Warehouse A",
"name": "Warehouse A"
},
"assetIds": ["ASSET-001"],
"inventoryIds": ["INV-001"]
}
}
}
}

Errors​

See authorization errors.


Update Container API​

Update Container API allows you to update a container's properties, reassign its tracker serial, move it to a new location, and add or remove contents (assets, inventory items, packages, or child containers).

Endpoint Details​

  • URL: https://api.xemelgo.com/graphql
  • Method: POST

Properties​

The id field identifies the container to update. All fields inside updates are optional.

PropertyTypeDescriptionRequired/Updatable
idStringUnique identifier for the container to updateYes / No
updates.idStringNew identifier for the container (rename)No / Yes
updates.typeIdStringNew Container Type identifierNo / Yes
updates.trackerSerialStringNew RFID tag to assign to the containerNo / Yes
updates.reuseTrackerSerialBooleanWhether to reuse the tracker serial if it already existsNo / Yes
updates.nameStringNew display nameNo / Yes
updates.descriptionStringNew descriptionNo / Yes
updates.commentsStringNew comments or remarksNo / Yes
updates.locationIdStringNew location for the containerNo / Yes
updates.customPropertiesAWSJSONUpdated custom propertiesNo / Yes
updates.addAssets[Asset Input]Assets to add to the containerNo / Yes
updates.addChildContainerIds[String]IDs of containers to nest inside this containerNo / Yes
updates.addInventory[Inventory Input]Inventory items to add to the containerNo / Yes
updates.addPackages[Package Input]Packages to add to the containerNo / Yes
updates.removeAssetIds[String]IDs of assets to remove from the containerNo / Yes
updates.removeChildContainerIds[String]IDs of child containers to remove from this containerNo / Yes
updates.removeInventoryIds[String]IDs of inventory items to remove from the containerNo / Yes
updates.removePackageIds[String]IDs of packages to remove from the containerNo / Yes

Headers​

Authorization – $idToken

Response Properties​

Returns a Container object.

Request Body​

mutation {
updateContainer(
input: {
id: "CONTAINER-001"
updates: {
locationId: "Warehouse B"
comments: "Moved to Warehouse B"
addAssets: [
{
id: "ASSET-002"
typeId: "Mounted"
trackerSerial: "20240801000003"
}
]
removeInventoryIds: ["INV-001"]
}
}
) {
container {
id
name
trackerSerial
location {
id
name
}
assetIds
inventoryIds
lastUpdatedDate
}
}
}

Status Code - 200

Response Body​

{
"data": {
"updateContainer": {
"container": {
"id": "CONTAINER-001",
"name": "Container 001",
"trackerSerial": "20240801000001",
"location": {
"id": "Warehouse B",
"name": "Warehouse B"
},
"assetIds": ["ASSET-001", "ASSET-002"],
"inventoryIds": [],
"lastUpdatedDate": 1722369539000
}
}
}
}

Errors​

See authorization errors.

Additional Errors​

Error
Container not found

Container Not Found​

{
"data": {
"updateContainer": null
},
"errors": [
{
"path": ["updateContainer"],
"data": null,
"errorType": "ResourceNotFoundError",
"errorInfo": null,
"locations": [{ "line": 2, "column": 3, "sourceName": null }],
"message": "Container not found: CONTAINER-001"
}
]
}

Delete Container API​

Delete Container API allows you to permanently delete a container record from the system.

Note: A container can only be deleted if it is empty — it must have no assets, inventory items, packages, or child containers associated with it.

Endpoint Details​

  • URL: https://api.xemelgo.com/graphql
  • Method: POST

Properties​

PropertyTypeDescriptionRequired
containerIdStringUnique identifier of the container to deleteYes

Headers​

Authorization – $idToken

Response Properties​

Returns a Container object.

Request Body​

mutation deleteContainer {
deleteContainer(input: { containerId: "CONTAINER-001" }) {
container {
id
name
}
}
}

Status Code - 200

Response Body​

{
"data": {
"deleteContainer": {
"container": {
"id": "CONTAINER-001",
"name": "Container 001"
}
}
}
}

Errors​

See authorization errors.


List Containers API​

List Containers API allows you to retrieve all containers and view their statuses and contents. Results can be filtered and paginated.

Endpoint Details​

  • URL: https://api.xemelgo.com/graphql
  • Method: POST

Input Properties​

PropertyTypeDescriptionRequired
filterStringFilter expression for container propertiesNo
nextTokenStringPagination token for the next pageNo

Response Properties​

PropertyTypeDescription
containers[Container]List of containers (see Container)
nextTokenStringToken for retrieving the next page

Headers​

Authorization – $idToken

Request Body​

query containers($filter: String, $nextToken: String) {
containers(input: { filter: $filter, nextToken: $nextToken }) {
nextToken
containers {
id
name
description
trackerSerial
comments
images
creationDate
lastUpdatedDate
assetIds
childContainerIds
inventoryIds
packageIds
parentContainerId
customProperties
type {
id
name
description
customProperties
}
location {
id
name
}
lastDetectedAtLocation {
id
name
}
}
}
}

Filter variable example:

{
"filter": "lastUpdatedDate > 1716621117144"
}

Status Code - 200

Response Body​

{
"data": {
"containers": {
"nextToken": null,
"containers": [
{
"id": "CONTAINER-001",
"name": "Container 001",
"description": "Main storage bin",
"trackerSerial": "20240801000001",
"comments": "Moved to Warehouse B",
"images": [],
"creationDate": 1722300000000,
"lastUpdatedDate": 1722369539000,
"assetIds": ["ASSET-001", "ASSET-002"],
"childContainerIds": [],
"inventoryIds": [],
"packageIds": [],
"parentContainerId": null,
"customProperties": {},
"type": {
"id": "Bin",
"name": "Bin",
"description": "Standard storage bin",
"customProperties": {}
},
"location": {
"id": "Warehouse B",
"name": "Warehouse B"
},
"lastDetectedAtLocation": {
"id": "Warehouse B",
"name": "Warehouse B"
}
}
]
}
}
}

Errors​

See authorization errors.