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

API Sales Order (A2X) - Response

arindamsur
Participant
0 Likes
494
  • SAP Managed Tags

Dear Expert,

I am working on Sales order API from functional point of view.

in order to create mapping sheet, I take help from Sales Order (A2X) | SAP Help Portal

Here I got full details about API inbound fields. 

My question is where I can find this API response (Sales Order Confirmation) related fields?

Accepted Solutions (1)

Accepted Solutions (1)

FabioPagoti
Active Contributor

By definition, an OData API will return the whole entity after a document was created.

So, imagine you call the create request using something similar

 

POST /SalesOrder

{
"customer": "1234",
"sales_organization": "0100",
"channel": "10",
"division": "20"
"Items": [

]
}

 

So what you get in return assuming you get a 201 (Create successful) is actually the whole SalesOrder entity (including any fields generated in the back end)

 

POST /SalesOrder

{
"id": "40001",
"created_by": "USER_ABC",
"created_on": "some date",
"customer": "1234",
"sales_organization": "0100",
"channel": "10",
"division": "20",
"Items": [

]
}
​

 

In order to understand all fields available in the API for any entity, you can always call the $metadata endpoint of the API as you can also do for any OData API.

GET /sap/opu/xxxxx/service_srv/$metadata 
(do not include an entity name in the url)

Answers (0)