Via this endpoint you can import sales order candidates into metasfresh and at the same time even create new business partner and product entries. You can also use this endpoint to upload file attachments and attach them to the sales order candidates.
To use this endpoint successfully, you might need the following data:
SOURCE.de.metas.ordercandidate.rest.OrderCandidatesRestControllerImpl
DEST.de.metas.ordercandidate
Note: |
---|
You will find the imported sales order candidates and file attachments under “Sales Order Disposition” in the WebUI menu. |
Follow these instructions and use the request method POST /api/sales/order/candidates. At step 7, paste your JSON server request you have prepared based on the request example provided for this endpoint.
Note: You can view the External Header ID in the advanced edit menu from the actions menu of the respective sales order candidate’s entry.
Note: Any error messages will be displayed in the Responses section below.
{
"bpartner": {
"bpartner": {
"active": true,
"code": "API_001_testBP",
"companyName": "API Inc.",
"externalId": "API-bp00001",
"group": "Standard",
"name": "Ganesh Rupka BP",
"phone": "1800-CALL-ME",
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "CREATE"
}
},
"contact": {
"active": true,
"description": "RESTing with the apes.",
"email": "ganesh.rupka@nomail.com",
"externalId": "API-con00001",
"firstName": "Ganesh",
"lastName": "Rupka",
"name": "Ganesh B. Rupka",
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "CREATE"
}
},
"location": {
"active": true,
"address1": "Street No. 1",
"address2": "East Wing",
"address3": "Apt. 3",
"address4": "Room 4",
"city": "New Dehli",
"countryCode": "IN",
"externalId": "API-loc00001",
"name": "Ganesh Rupka's address",
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "CREATE"
}
},
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "CREATE"
}
},
"currencyCode": "INR",
"dataDestInternalName": "DEST.de.metas.ordercandidate",
"dataSourceInternalName": "SOURCE.de.metas.ordercandidate.rest.OrderCandidatesRestControllerImpl",
"dateRequired": "2019-08-23",
"externalHeaderId": "extHead-101",
"externalLineId": "extLine-101",
"invoiceDocType": {
"docBaseType": "ARI"
},
"org": {
"code": "001",
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "FAIL"
}
},
"poReference": "SEO_768-04",
"price": 6.90,
"pricingSystemCode": 2000837,
"product": {
"code": "Coco_2468",
"name": "Coconuts",
"type": "ITEM",
"uomCode": "PCE",
"syncAdvise": {
"ifExists": "DONT_UPDATE",
"ifNotExists": "CREATE"
}
},
"uomCode": "PCE",
"productDescription": "I've got a lovely bunch of coconuts.",
"qty": 5
}