Ask another location for stock
Raise the request, submit it to the sending location, let them accept — reserving the stock and starting the transfer — or decline it; open a regular lane between two locations that move stock often.
Warehouse · a play in 3 steps.
The steps
- Raise the request and submit it — the pull request reaches the sending location. — createTransferRequest, submitTransferRequest
- The sender accepts — the stock reserves and the transfer paperwork starts — or declines. — acceptTransferRequest, rejectTransferRequest
- Open a regular lane — a named sender-to-receiver route — and see which lanes serve a move best. — createTransferLane, transferLaneRanking
The calls
Every operation this use case runs, in the order it first appears, with the request and the response its reference page shows.
createTransferRequest
createTransferRequest — mutation · Create a new stock-transfer request between your locations at your organization.
Example request
mutation ExampleCreateTransferRequest($input: CreateTransferRequestInput!) {
createTransferRequest(input: $input) {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
requestingOrganizationId
targetLogicalFacilityId
neededBy
priority
}
}
Variables:
{
"input": {
"caption": "Blue jeans",
"requestingLogicalFacilityId": "01900000-0000-7000-8000-9b4a35b10000",
"lines": [
{
"variantId": "01900000-0000-7000-8000-8415e73b0000",
"quantity": "2",
"orderLineRef": {
"orderId": "01900000-0000-7000-8000-f6d8263a0000",
"orderLineNo": 1
}
}
]
}
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"createTransferRequest": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "TR-EXMP-0000-000F",
"type": "TransferRequest",
"caption": "Blue jeans",
"status": "draft",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"requestingOrganizationId": "01900000-0000-7000-8000-93bd40d40000",
"targetLogicalFacilityId": "01900000-0000-7000-8000-2938ce830000",
"neededBy": "<needed by>",
"priority": "low"
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
submitTransferRequest
submitTransferRequest — mutation · Ask another of your locations for stock — the pull request.
Example request
mutation ExampleSubmitTransferRequest($id: ID!, $revision: ID!, $reason: String) {
submitTransferRequest(id: $id, revision: $revision, reason: $reason) {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
requestingOrganizationId
targetLogicalFacilityId
neededBy
priority
}
}
Variables:
{
"id": "01900000-0000-7000-8000-37386ae00000",
"revision": "01900000-0000-7000-8000-b7960e180000",
"reason": "Correcting a miscount."
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"submitTransferRequest": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "TR-EXMP-0000-000F",
"type": "TransferRequest",
"caption": "Blue jeans",
"status": "draft",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"requestingOrganizationId": "01900000-0000-7000-8000-93bd40d40000",
"targetLogicalFacilityId": "01900000-0000-7000-8000-2938ce830000",
"neededBy": "<needed by>",
"priority": "low"
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
acceptTransferRequest
acceptTransferRequest — mutation · Approve another location’s request to move stock — the sending side saying “yes, take it”.
Example request
mutation ExampleAcceptTransferRequest($input: AcceptTransferRequestInput!, $revision: ID!, $reason: String) {
acceptTransferRequest(input: $input, revision: $revision, reason: $reason) {
transferRequest {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
requestingOrganizationId
targetLogicalFacilityId
neededBy
priority
}
}
}
Variables:
{
"input": {
"transferRequestId": "01900000-0000-7000-8000-7d4929a60000",
"sourceLogicalFacilityId": "01900000-0000-7000-8000-4971feb30000",
"caption": "Blue jeans",
"lines": [
{
"lineNo": 1,
"quantity": "2"
}
]
},
"revision": "01900000-0000-7000-8000-b7960e180000",
"reason": "Correcting a miscount."
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"acceptTransferRequest": {
"transferRequest": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "TR-EXMP-0000-000F",
"type": "TransferRequest",
"caption": "Blue jeans",
"status": "draft",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"requestingOrganizationId": "01900000-0000-7000-8000-93bd40d40000",
"targetLogicalFacilityId": "01900000-0000-7000-8000-2938ce830000",
"neededBy": "<needed by>",
"priority": "low"
}
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
rejectTransferRequest
rejectTransferRequest — mutation · Decline another location’s stock request.
Example request
mutation ExampleRejectTransferRequest($input: RejectTransferRequestInput!, $revision: ID!, $reason: String) {
rejectTransferRequest(input: $input, revision: $revision, reason: $reason) {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
requestingOrganizationId
targetLogicalFacilityId
neededBy
priority
}
}
Variables:
{
"input": {
"transferRequestId": "01900000-0000-7000-8000-7d4929a60000",
"sourceLogicalFacilityId": "01900000-0000-7000-8000-4971feb30000",
"lines": [
{
"lineNo": 1,
"reason": "Correcting a miscount."
}
]
},
"revision": "01900000-0000-7000-8000-b7960e180000",
"reason": "Correcting a miscount."
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"rejectTransferRequest": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "TR-EXMP-0000-000F",
"type": "TransferRequest",
"caption": "Blue jeans",
"status": "draft",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"requestingOrganizationId": "01900000-0000-7000-8000-93bd40d40000",
"targetLogicalFacilityId": "01900000-0000-7000-8000-2938ce830000",
"neededBy": "<needed by>",
"priority": "low"
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
createTransferLane
createTransferLane — mutation · Create a new transfer lane — a named sender→receiver route stock moves along at your organization.
Example request
mutation ExampleCreateTransferLane($input: NewTransferLaneInput!) {
createTransferLane(input: $input) {
id
sysId
type
caption
status
parentId
rootId
createdAt
updatedAt
revisionNum
revision
sourceLfId
destinationLfId
mode
rank
typicalLeadTimeDays
weightClass
}
}
Variables:
{
"input": {
"caption": "Blue jeans",
"sourceLfId": "01900000-0000-7000-8000-366bfb930000",
"destinationLfId": "01900000-0000-7000-8000-7bd4ce680000",
"mode": "never"
}
}
Send it with the envelope naming the version: "extensions": {"at": {"version": {"name":"genesis","number":0}}}.
Example response
{
"data": {
"createTransferLane": {
"id": "01900000-0000-7000-8000-37386ae00000",
"sysId": "TL-EXMP-0000-000F",
"type": "TransferLane",
"caption": "Blue jeans",
"status": "active",
"parentId": "01900000-0000-7000-8000-065235280000",
"rootId": "01900000-0000-7000-8000-a093dd800000",
"createdAt": "2027-01-31T00:00:00.000Z",
"updatedAt": "2027-01-31T00:00:00.000Z",
"revisionNum": 1,
"revision": "01900000-0000-7000-8000-b7960e180000",
"sourceLfId": "01900000-0000-7000-8000-366bfb930000",
"destinationLfId": "01900000-0000-7000-8000-7bd4ce680000",
"mode": "never",
"rank": 1,
"typicalLeadTimeDays": 1,
"weightClass": "light"
}
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": {
"name": "genesis",
"number": 0
},
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
transferLaneRanking
transferLaneRanking — query · Which transfer lanes (location pairs) serve a move best, ranked.
Example request
query ExampleTransferLaneRanking($destinationLogicalFacilityId: ID!) {
transferLaneRanking(destinationLogicalFacilityId: $destinationLogicalFacilityId) {
destinationLfId
sourceLfId
basis
rank
laneId
weightClass
distanceKm
samePfl
noGeo
position
}
}
Variables:
{
"destinationLogicalFacilityId": "01900000-0000-7000-8000-3885245e0000"
}
Example response
{
"data": {
"transferLaneRanking": [
{
"destinationLfId": "01900000-0000-7000-8000-7bd4ce680000",
"sourceLfId": "01900000-0000-7000-8000-366bfb930000",
"basis": "<basis>",
"rank": 1,
"laneId": "01900000-0000-7000-8000-15be5b420000",
"weightClass": "light",
"distanceKm": 1.5,
"samePfl": true,
"noGeo": true,
"position": 1
}
]
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": null,
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}