Movement orders
Movement orders represent stock movements that are processed in CAS for special procedure or tax warehouse stock management. They allow you to track goods entering, leaving, or moving within your warehouse authorizations.
Create a movement order
Use the Create movement order endpoint to ingest a new movement order:
POST https://api-<env>.customs4trade.com/v1/movementorders
The request body follows the MovementIngest model. Refer to the API specification or the MovementIngest XSD for the full schema.
Like other ingestion endpoints, this operates asynchronously. The response is 202 Accepted with a reference ID:
{
"referenceId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
}
Scope: create:wms
This endpoint replaces the deprecated POST /v1/movements endpoint.
Write-off rules and customs destination
For release for free circulation (RFFC) and negative stock adjustment (ADJN) movement orders, you can optionally provide a customs destination and a set of write-off rules. These fields are optional and only applicable to the RFFC and ADJN movement types.
The customsDestination indicates how the goods are released:
| Value | Description |
|---|---|
HomeUse |
Simultaneous release for free circulation and home use of goods (procedure 40 in the H1 declaration) |
PartialHomeUse |
Release of goods for free circulation and partial entry for home use (procedure 45 in the H1 declaration) |
The writeOffRules array describes which stock should be selected for release, based on origin and customs status. Stock is released until the requested quantities are satisfied, in the order the rules are provided. Each rule has the following fields, all optional:
| Field | Type | Description |
|---|---|---|
| customsStatus | string | Customs status of the stock to select: Free or Bonded |
| isOfPreferentialOrigin | boolean | Optional. true selects stock of preferential origin; false selects stock that is not of preferential origin. When omitted, the rule does not constrain selection by preferential origin. |
| preferentialOriginCountry | string | Country of preferential origin to select stock for (ISO 3166-1 alpha-2) |
| nonPreferentialOriginCountry | string | Country of non-preferential origin to select stock for (ISO 3166-1 alpha-2) |
| inboundDocRefNum | string | MRN of the inbound declaration the stock is written off from |
| inboundFunctionRefNum | string | LRN of the inbound declaration the stock is written off from (use only when the inbound declaration was an EIDR and has no MRN) |
Example movement with a customs destination and write-off rules:
{
"version": "1.0",
"movements": [
{
"timestamp": "2026-01-02T00:00:00.0000000+01:00",
"externalReference": "MO-0001",
"movementType": "RFFC",
"customsDestination": "HomeUse",
"writeOffRules": [
{
"customsStatus": "Bonded",
"isOfPreferentialOrigin": true,
"preferentialOriginCountry": "BE",
"inboundDocRefNum": "23BE000000000000A1"
},
{
"isOfPreferentialOrigin": false,
"nonPreferentialOriginCountry": "CN",
"inboundFunctionRefNum": "LRN0000000001"
}
],
"movementLines": [
{
"itemId": "MATERIAL001",
"direction": "Out",
"quantity": 7.3,
"uom": "NAR",
"storageLocationReference": "STORAGEB"
}
]
}
]
}
Retrieve a movement order
Use the Get movement order endpoint to retrieve the full details of an existing movement order:
GET https://api-<env>.customs4trade.com/v1/movementorders/{id}
This is particularly useful when you need to:
- Check the current status of a movement order
- Retrieve validation errors to understand why a movement order could not be processed
- Read back all movement order data as stored in CAS
Returns 200 OK with the movement order details, or 404 Not Found if the movement order does not exist.
Scope: read:wms
Movement order model
MovementOrder
| Field | Type | Description |
|---|---|---|
| timestamp | timestamp | Date of the movement order |
| documentReference | string | Reference to the document that triggered the creation |
| externalReference | string | Your unique external reference for the movement order |
| type | string | CAS movement order type (see Movement types below) |
| externalMovementType | string | Movement type as known by your inventory or warehouse management system |
| status | string | Current status (see Movement order statuses below) |
| category | string | Excise register column category (see Movement categories below) |
| remark | string | Remark shown in the excise register (for tax warehouse stock corrections) |
| customsDestination | string | Customs destination, for RFFC and ADJN movement orders: HomeUse or PartialHomeUse (see Write-off rules and customs destination) |
| adjustmentData | object | Stock adjustment data for tax warehouse (see below) |
| lines | array | Item-level data of the movement order (up to 9999 lines) |
| writeOffRules | array | Write-off rules that were provided for an RFFC or ADJN movement order (see below) |
| validationErrors | array | Current validation errors (only present when status is Invalid, ProcessingError, or InvalidationRejected) |
MovementOrderAdjustmentData
Provided for positive or negative stock adjustments related to a tax warehouse:
| Field | Type | Description |
|---|---|---|
| administrativeReferenceCode | string | ARC of an e-AD, for corrections related to an e-AD |
| arcSequenceNumber | int | Sequence number of the e-AD |
| docRefNum | string | MRN of a related export declaration |
MovementOrderWriteOffRule
Returned for RFFC and ADJN movement orders, reflecting the write-off rules that were provided when the movement order was created (see Write-off rules and customs destination):
| Field | Type | Description |
|---|---|---|
| customsStatus | string | Customs status of the selected stock: Free or Bonded |
| isOfPreferentialOrigin | boolean | Whether stock of preferential origin |
| preferentialOriginCountry | string | Country of preferential origin |
| nonPreferentialOriginCountry | string | Country of non-preferential origin |
| inboundDocRefNum | string | MRN of the inbound declaration |
| inboundFunctionRefNum | string | LRN of the inbound declaration |
MovementOrderLine
| Field | Type | Description |
|---|---|---|
| itemId | string | Unique identifier of the item/material as defined in master data |
| itemDescription | string | Description of the item |
| direction | string | Direction: In, Out, or Transfer |
| serialBatchReference | string | Unique serial or batch number |
| quantity | decimal | Quantity in the base unit of measure as defined in master data |
| uom | string | Unit of measure (e.g. KGM, LTR, LPA, HLT, DTN) |
| exciseProductCode | string | Excise Product Code (e.g. B000 for beer, S300 for ethyl alcohol) |
| asv | decimal | Alcohol % by volume (ABV) |
| storageLocationReference | string | Storage location reference as known in CAS |
| authorizationId | string | The special procedure or tax warehouse authorization |
| receivingStorageLocationReference | string | Receiving storage location (for TRFA and TRFR transfers) |
| receivingAuthorizationId | string | Receiving authorization (for TRFA and TRFR transfers) |
| preferentialOriginCountry | string | Preferential origin country code (ISO 3166-1 alpha-2) |
| nonPreferentialOriginCountry | string | Non-preferential origin country code (ISO 3166-1 alpha-2) |
| blendResult | object | Result data for TRFB (transfer + blend) movement orders |
| quantities | array | Additional quantities in other units of measure |
MovementOrderValidationError
| Field | Type | Description |
|---|---|---|
| errorCode | string | Error code identifying the type of validation failure |
| errorMessage | string | Human-readable description of the validation error |
Movement types
| Type | Description |
|---|---|
PROC |
Production -- creation of a product in a TXW or SP (e.g. blend of energy products, registration of alcohol production) |
UFOH |
Usual form of handling -- typically in a customs warehouse |
ADJP |
Positive stock adjustment |
ADJN |
Negative stock adjustment |
TRFA |
Transfer from one authorization to another |
TRFR |
Transfer between storage locations within the same authorization |
TRFB |
Transfer + blend -- transfer to another storage location and blend at destination |
RFFC |
Release for free circulation |
DCSV |
Removal by destruction under customs supervision |
Movement order statuses
| Status | Description |
|---|---|
Valid |
Validated, no errors found |
Invalid |
Validated, validation errors found (check validationErrors) |
Submitted |
Submitted and being processed |
Processed |
Processed successfully |
ProcessingError |
Processed with errors (check validationErrors) |
Invalidating |
Invalidation is in progress |
Invalidated |
Successfully invalidated |
InvalidationRejected |
Invalidation was rejected (check validationErrors) |
MissingDensity |
Energy product with missing density information (weight or litres at 15 degrees is known, but not both) |
Movement categories
Used for ADJP and ADJN movement types when the movement applies to a tax warehouse:
| Category | Excise register column |
|---|---|
DepartureUnderSuspension |
5. Dispatch under a suspension |
Export |
6. Export |
ArrivalUnderSuspension |
3b. Received duty suspension |
Production |
3a. Production |
OtherArrival |
3c. Fictive Arrival |
For HTTP status codes and error response formats, see Error handling.