I’m trying to create a shipment via the rest api. The api call succeeds and the shipment is created but I’m getting errors in the Request Profiler. How do I debug these? The errors are vague and the stack traces don’t help either.
Please take a look to my test. Please add LineNbr to the lines. The date format might also be an issue. Set it to the local handled by Acumatica Ex:
,""ShipmentDate"":{""value"":""09/12/2022""}
Hi @XodusRich
Please make sure the InventoryID, You are sending is as InventoryCD, and also no need to pass the ShipmentNbr as Null. If we set as an auto number, it will consider the next number. Please remove this field as well
Leo, I copied your JSON and replaced it with my info. I’m still getting the same Request Profiler errors. Can you do me a favor and clear your Request Profiler log and try your import again? Do you get any errors?
jinin, I tried as you said. Same errors. InventoryCD and InventoryID look interchangeable. My product was correctly added onto the shipment.
Your Request looks good. Do you have any customization on the shipment screen? If yes, can you please unpublish the package and try once?
No customizations. For fields like the OrderQty, OpenQty, and ShippedQty does it matter if the values have quotes around them or not?
@XodusRich
Acumatica will accept with and without quotes as well.
It's enough to send only the Shipped Qty. The open and ordered qty Acumatica will update.
So I installed the new Postman desktop app and I have everything configured.
PUT URL: http://accounting/(W(1))/entity/Default/20.200.001/Shipment
{
"Type": {
"value": "Shipment"
},
"Operation": {
"value": "Issue"
},
"ShipmentDate": {
"value": "9/13/2022"
},
"CustomerID": {
"value": "CUST2943"
},
"WarehouseID": {
"value": "XODUS"
},
"Details": ;
{
"OrderType": {
"value": "SO"
},
"OrderNbr": {
"value": "SO251106"
},
"InventoryID": {
"value": "50500"
},
"UOM": {
"value": "CASE"
},
"ShippedQty": {
"value": "2"
},
"LineNbr": {
"value": 1
}
}
]
}
I’m still getting the same 6 exceptions in the Request Profiler from the POSTMAN PUT as I was getting from my Rest API call. Can someone clear their Request Profiles and try this shipment import. Do you get any exceptions as well?
@XodusRich
Can you share the returned payload with all errors please?
Thanks
Look at my screenshot above. That is from my Request Profiler page in Acumatica. That’s what I get when I create a shipment via POSTMAN or the Rest API. The shipment record does create correctly but profiler reports a bunch of exceptions.
Look at my screenshot above. That is from my Request Profiler page in Acumatica. That’s what I get when I create a shipment via POSTMAN or the Rest API. The shipment record does create correctly but profiler reports a bunch of exceptions.
I thought the Shipment was not created and an error was thrown. Sometimes, even operating with Acumatica user interface, you get some internal errors that are handled by upper layers in the code and never pop up to the user, but are written into the trace log and you can see them. This might be one of those cases. Are those errors impacting something else or stopping you from operating with any other document or entity?
I would relay more on any error coming in the response than errors caught in the profiler. Nevertheless, I would also keep an eye on those internal errors. I will check on my local about similar behaviors regarding REST API interactions.