On this page
expectedReceipts
query · in the family Reading your records
What it does
What is expected to arrive — open purchase-order lines by item and date.
The derived INBOUND view: every receivable PO (issued / acknowledged / partially_received) flattened to its outstanding lines (ordered − received > 0), shaped {po, line, variant, LF, outstandingQty, expectedArrivalAt}. DERIVED at read off the purchase_orders walk — never stored; fully-received lines and terminal history drop. Requires authentication; scoped server-side to the principal's rootId.
What happens
Reads only — the inbound pipeline.
Who may call it
Capability area: Reading your records — Looking up and listing the records of your organization.
- Owner
- System Administrator
- Manager
- Associate Manager
- Warehouse Associate
- Sales Associate
- An API key whose scope allows
api:expectedReceipts
Returns
ExpectedReceipt [ExpectedReceipt!]! — One derived inbound line. DERIVED at read — never stored (the TR outstanding stance).
Example request
query ExampleExpectedReceipts {
expectedReceipts {
purchaseOrderId
purchaseOrderSysId
orgVendorId
organizationId
lineNo
variantId
logicalFacilityId
outstandingQty
expectedArrivalAt
}
}
Example response
{
"data": {
"expectedReceipts": [
{
"purchaseOrderId": "01900000-0000-7000-8000-54a5b8570000",
"purchaseOrderSysId": "<purchase order sys id>",
"orgVendorId": "01900000-0000-7000-8000-f885fa720000",
"organizationId": "01900000-0000-7000-8000-44b781470000",
"lineNo": 1,
"variantId": "01900000-0000-7000-8000-8415e73b0000",
"logicalFacilityId": "01900000-0000-7000-8000-8026f71c0000",
"outstandingQty": "<outstanding qty>",
"expectedArrivalAt": "2027-01-31T00:00:00.000Z"
}
]
},
"extensions": {
"at": {
"callId": "01EXAMPLE-CALL-ID",
"version": {
"requested": null,
"serviced": {
"name": "genesis",
"number": 0
}
}
}
}
}
Errors this call can answer
VALIDATION/INVALID— Something in the request is not valid. (VALIDATION)AUTHN/REQUIRED— Sign in to do this. (AUTHN)AUTHZ/FORBIDDEN— Your role does not allow this action. (AUTHZ)RATE_LIMIT/THROTTLED— Too many requests in a short time. (RATE_LIMIT)