When I create an issue through the UI, it works. I try to do the same thing through the API, and I get the error noted in the subject. Here’s the full payload i PUT to /entity/Default/22.200.001/InventoryIssue
this is only problematic when the stock item requires a lot number. I want to pass that & not able to through the API
payload = {
"Note": {
"value": "test"
},
"Details": l
{
"InventoryID": {
"value": "GEN-10127"
},
"Note": {
"value": "VO 109044, VOI 123872"
},
"LotSerialNbr": {
"value": "64980051405"
},
"WarehouseID": {
"value": "TP-NY"
},
"Location": {
"value": "TP-NY"
},
"Qty": {
"value": "1",
},
"TranType": {
"value": "Issue"
},
"UnitPrice": {
"value": 3.52
},
"UOM": {
"value": "BOTTLE"
},
"ReasonCode": {
"value": "TPISSUE"
}
}
],
"PostPeriod": {
"value": "10-2023"
},
"Date": {
"value": "2023-10-12"
},
}
Here’s the response I get back, note that the LotSerialNbr
does not come back, as if it was filtered pre-processing in Acumatica
{
"ControlAmount": {
"value": 3.52
},
"ControlQty": {
"value": 1.0
},
"Date": {
"value": "2023-10-12T00:00:00+00:00"
},
"Description": {},
"Details":
{
"Branch": {
"value": "VETCOVE"
},
"Description": {
"value": "Timolol Maleate Ophthalmic Solution 0.50% 5mL Bottle"
},
"ExpirationDate": {},
"ExtCost": {
"value": 0.0
},
"ExtPrice": {
"value": 3.52
},
"InventoryID": {
"value": "GEN-10127"
},
"LineNumber": {
"value": 1
},
"Location": {
"value": "TP-NY"
},
"LotSerialNbr": {
"value": ""
},
"Qty": {
"error": "One or more lines have unassigned Location and/or Lot/Serial Number",
"value": 1.0
},
"ReasonCode": {
"value": "TPISSUE"
},
"TranType": {
"value": "Issue"
},
"UOM": {
"value": "BOTTLE"
},
"UnitCost": {
"value": 0.0
},
"UnitPrice": {
"value": 3.52
},
"WarehouseID": {
"value": "TP-NY"
},
"_links": {
"files:put": "/entity/Default/22.200.001/files/PX.Objects.IN.INIssueEntry/transactions/b4fddece-576c-ee11-834d-124ed9a423ab/{filename}"
},
"custom": {},
"id": "b4fddece-576c-ee11-834d-124ed9a423ab",
"note": {
"value": "VO 109044, VOI 123872"
},
"rowNumber": 1
}
],
"ExternalRef": {},
"PostPeriod": {
"value": "102023"
},
"ReferenceNbr": {
"value": "<NEW>"
},
"Status": {
"value": "Balanced"
},
"TotalAmount": {
"value": 3.52
},
"TotalCost": {
"value": 0.0
},
"TotalQty": {
"value": 1.0
},
"_links": {
"files:put": "<deleted>",
"self": "<deleted>"
},
"custom": {},
"error": "Inserting IN Transaction record raised at least one error. Please review the errors.",
"id": "b1fddece-576c-ee11-834d-124ed9a423ab",
"note": {
"value": "test"
},
"rowNumber": 1
}