Index | Conventions

api/v1/stocktransfercreate/locationtransfer

Path: api/v1/stocktransfercreate/locationtransfer

This endpoint supports the following methods:
POST

Summary: Creates a new Stock Location Transfer

Query Parameters

ParameterOptionalDescription
QueueSet to true, 1, or t to queue the request via the Jim2 eBusiness Queue. If specified the response will be 202 Accepted and the B2B request number will be returned.
Leave out, or set to false, 0, or f to process the request immediately.
SubmitRefIdA unique reference ID for the request. This is used to prevent duplicate requests when the Queue parameter is also passed. If a SubmitRefId is passed via this query parameter and within the request content (see submitRefId in JSON content) then the two values must be the same. A check for duplication due to re-processing on the B2B queue is NOT performed unless the SubmitRefId is included in the request body (ie not passing the SubmitRefId in the message body allows an item on the B2B queue to be reprocessed and potentially creating a duplicate object).
The Queue parameter must also be specified if SubmitRefId is specified.
Note that the SubmitRefId must be unique to Jim2, so if multiple systems are making calls care must be taken to avoid clashes in SubmitRefIds between systems.

Request content

AttributeTypeRequiredDescription
branchstringThe branch code. Branches must be enabled.
commentsarray of objectSee the comments section below.
customanyA free-form JSON object carrying additional data for custom processing. Used where custom processing is required and additional data must be passed to that custom processing.
dateDuestringThe date due for the new Stock Transfer. Must be in ISO date format - eg "2020-01-31".
fromLocationstringThe location code where the stock is transferred from.
notesstringAny notes relating to the Stock Transfer
statusstringThe status for the Stock Transfer. This status must be valid per workflow from Booked, and cannot be Transfer or FINISH. If omitted the Status will be 'Booked'.
stockLinesarray of objectThe stock lines to transfer. At least one is required.
See the stockLines section below.
submitRefIDstringA unique reference for the create request. This reference must be unique for each object and can be used to ensure duplicate objects are not created when re-trying API calls. Note this reference must be unique in Jim2, so if multiple systems are creating objects care must be taken to avoid clashes between the different system's submit ref id. Refer also to the SubmitRefId url query parameter for relevant endpoints.
toLocationstringThe location code where the stock is transferred to.

comments

Attributes of each element in the comments array.

AttributeTypeRequiredDescription
commentstringThe comment text.

stockLines

Attributes of each element in the stockLines array.

AttributeTypeRequiredDescription
qtynumberHow many units of the stock should be transferred.
stockCodestringThe Jim2 stock code (the Jim2 stock the user is transferring).
stockDescriptionstringThe stock description. Only required if the default stock description needs to be overrridden. It is recommended this be set for special stock.
unitQtynumberThe number of items inside the Unit. If omitted the qty will be set to 1. Eg, 12 (BOX containing 12 items)'.

Response content

AttributeTypeDescription
transferNointegerThe number of the created stock transfer.

Example POST

Path: api/v1/stocktransfercreate/locationtransfer

Request:

{
    "submitRefID": "XFER-REQ-0001",
    "objectSource": "Jim2Commerce",
    "fromLocation": "ACT",
    "toLocation": "MAIN",
    "dateDue": "2026-07-15",
    "status": "Booked",
    "notes": "Replenishment transfer.",
    "branch": "SYD",
    "comments": [
        {
            "comment": "Initial transfer note."
        }
    ],
    "stockLines": [
        {
            "stockCode": "WIDGET-1",
            "stockDescription": "Widget assembly (special)",
            "unitQty": 1,
            "qty": 10
        }
    ],
    "custom": {
        "externalRef": "EXT-12345"
    }
}

Response:

This example shows the maximum set of fields the endpoint can return, all populated. A real response only contains the data that applies to that record, so fields that are empty or not relevant are omitted — do not assume every field shown here will be present in every response.

{
    "transferNo": 1
}