Search stock transfers

distru-search-stock-transfersRead

Searches stock transfers — moves of inventory between your locations — with their lines.

Inputs

Every tool also takes the common inputs.

FieldTypeRequiredDescription
limitintegerNoDefault: 10
cursorstringNonextCursor of the previous call; keep the other arguments unchanged.
idsstring[]No
searchstringNoCase-insensitive substring of the transfer number. Ranks by closeness to it; sortBy is ignored.
statusesenum[]
CANCELEDCOMPLETEDTRANSIT
NoTRANSIT: sent, not yet received; its stock is held aside at the source.
fromLocationIdsstring[]NoResolve via distru-search-locations.
toLocationIdsstring[]NoResolve via distru-search-locations.
productIdsstring[]NoTransfers with a line of these products. Resolve via distru-search-products.
batchIdsstring[]NoTransfers with a line of these batches. Resolve via distru-search-batches.
packageIdsstring[]NoTransfers with a line of these packages. Resolve via distru-search-packages.
transferDatetimeAfterstringNoInclusive. YYYY-MM-DD (start of day, company timezone) or ISO 8601 with a UTC offset.
transferDatetimeBeforestringNoInclusive. YYYY-MM-DD (end of day, company timezone) or ISO 8601 with a UTC offset.
completedAtAfterstringNoInclusive. YYYY-MM-DD (start of day, company timezone) or ISO 8601 with a UTC offset.
completedAtBeforestringNoInclusive. YYYY-MM-DD (end of day, company timezone) or ISO 8601 with a UTC offset.
customFieldsobject[]NoSet one of contains, anyOf or onOrAfter/onOrBefore per entry. Records with no value for the field never match.
customFields[].customFieldIdstringYesResolve via distru-search-custom-fields.
customFields[].containsstringNoTEXT: case-insensitive substring.
customFields[].anyOfstring[]NoDROPDOWN, CHECKBOX: any of these options, case-sensitive.
customFields[].onOrAfterstringNoDATE: YYYY-MM-DD, company timezone.
customFields[].onOrBeforestringNoDATE: YYYY-MM-DD, company timezone.
sortByobjectNoDefault UPDATED_AT DESC.
sortBy.directionenum
ASCDESC
Yes
sortBy.fieldenum
COMPLETED_ATINITIATED_ATINSERTED_ATSTOCK_TRANSFER_NUMBERUPDATED_AT
YesINITIATED_AT: transferDatetime. COMPLETED_AT: transfers not completed sort last either direction.

Output

Presence on a nested field assumes its parent exists.

FieldTypePresence
hasMorebooleanAlways
nextCursorstringCan be absent
totalCountintegerCan be absent
itemsobject[]Always
items[].idstringAlways
items[].stockTransferNumberstringAlways
items[].statusenum
CANCELEDCOMPLETEDTRANSIT
Always
items[].transferDatetimestringCan be null
items[].completedAtstringCan be null
items[].descriptionstringCan be null
items[].customFieldsobject[]Always
items[].customFields[].customFieldobjectAlways
items[].customFields[].customField.idstringAlways
items[].customFields[].customField.namestringAlways
items[].customFields[].customField.fieldTypeenum
CHECKBOXDATEDROPDOWNTEXT
Always
items[].customFields[].valuestringCan be null
items[].fromLocationobjectCan be null
items[].fromLocation.idstringAlways
items[].fromLocation.namestringAlways
items[].toLocationobjectCan be null
items[].toLocation.idstringAlways
items[].toLocation.namestringAlways
items[].itemsobject[]Always
items[].items[].quantitystringCan be null
items[].items[].productobjectAlways
items[].items[].product.idstringAlways
items[].items[].product.namestringAlways
items[].items[].batchobjectCan be null
items[].items[].batch.idstringAlways
items[].items[].batch.namestringAlways
items[].items[].packageobjectCan be null
items[].items[].package.idstringAlways
items[].items[].package.metrcLabelstringAlways
What the AI reads

Searches stock transfers — moves of inventory between your locations — with their lines. To move stock, use distru-move-stock. transferDatetime is the date the transfer shows; completedAt is when its stock arrived, null unless COMPLETED. An item's quantity is in the package's unit type on package lines, else in the product's unit type. batch is set only for batch-tracked products. fromLocation or toLocation is null on legacy transfers to or from a person instead of a location. Scoped to the transfers the caller's team may see.