on 11-17-2017 12:47 PM
When submitting a new Purchase Delivery Note to be saved as a draft to the OData Service Layer, I get a "502 Proxy Error". However, if I submit the same request to the service layer to the PurchaseDeliveryNotes entity instead of the Drafts entity, the document is correctly saved.
The request being submitted is as follows:
POST /b1s/v1/Drafts HTTP/1.1
Host: hanab1.xxxxxxxx.local:50000
Cookie: B1SESSION=xxxxxx-xxxx-xxxxx-xxxxx-xxxxxxxxx; ROUTEID=.node1
Content-Type: application/json
Cache-Control: no-cache
{
"DocEntry": 0,
"HandWritten": 0,
"DocDate": "2017-11-17T00:00:00+00:00",
"CardCode": "FI00003",
"NumAtCard": "88888",
"Series": 0,
"DocObjectCode": "20",
"OpeningRemarks": "",
"DocumentLines": [{
"ItemCode": "HTHT14D",
"Quantity": 2.0,
"Price": 0.0,
"WarehouseCode": "01",
"BaseType": 22,
"BaseEntry": 66,
"BaseLine": 2,
"DocEntry": 0
}, {
"ItemCode": "HTHT9012",
"Quantity": 2.0,
"Price": 0.0,
"WarehouseCode": "01",
"BaseType": 22,
"BaseEntry": 66,
"BaseLine": 1,
"DocEntry": 0
}
]
}
Thanks Joseph. The problem was solved after a SAP update, there was nothing wrong with the request itself.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
Check the properties type from the both EntityType. Sometime this error appears when you want to set a string value in numeric type.
If it is not that, try to do a Read query from PurchaseDeliveryNotes and compare the response with your body. They should be more or less identically.
Regards,
Joseph
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
6 | |
6 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.