cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SAP 4/HANA Resource not found for segment 'A_PurOrdAccountAssignmentType

former_member712913
Discoverer
0 Likes
1,439

Hello.

We have the next PO in our SAP 4/HANA SandBox

And need to Assign its GL Account through the API

We are using POST method:

https://my305811-api.s4hana.ondemand.com/sap/opu/odata/sap/API_PURCHASEORDER_PROCESS_SRV/A_PurchaseOrderItem(PurchaseOrder='4500000511',PurchaseOrderItem='10')/to_AccountAssignment

Whit the next body:

{ "PurchaseOrder": "4500000511", "PurchaseOrderItem": "10", "AccountAssignmentNumber": "01", "GLAccount": "51600000" }

Also Tried with

{ "PurchaseOrder": "4500000511", "PurchaseOrderItem": "10", "AccountAssignmentNumber": "1", "GLAccount": "51600000" }

But we are receiving the next error: Resource not found for segment 'A_PurOrdAccountAssignmentType'


We sent many combinations, with/without cost center, with/without project, with/without account, with/without quantity, always with the same result.

Please, we appreciate your orientation to solve this issue.

Kind Regards,

Margarita Guerrero

Accepted Solutions (0)

Answers (2)

Answers (2)

mglcorreia
Explorer
0 Likes

Hi. Did you found a solution for this? I'm getting quite the same error
thanks.

geert-janklaps
SAP Mentor
SAP Mentor
0 Likes

Hi,

Did you set both the Content-Type and Accept header to application/json in postman? (by default the odata API will expect / return XML formatted data)

Best regards,

Geert-Jan Klaps

former_member712913
Discoverer
0 Likes

Hi Geert-Jan.

We did it, but same error

Thanks

Margarita