Global API
...
Requests
Sales Order
Update
1min
The following is an example of update SalesOrder where we are changing some of the fields . (See SalesOrder for all available fields). The NetSuite Sales Order Id (internalId) is required to update the Sales Order.
Note: You can only update one record at a time.
The response returns the complete Sales Order information, but we have shortened the response in our example for ease of reading.
Request
Response
{
action = updateSalesOrder,
timestamp = 1621491360689,
validRequest = true,
version = 1.0,
responseJSON = {
"status": "200",
"errors": [],
"salesOrders": [
{
"tranId": "1",
"tranDate": 1630953000,
"total": 199.8,
"taxTotal": 1.98,
"subTotal": 217.82,
"subsidiary": {
"type": null,
"name": "Parent Company",
"internalId": "1",
"externalId": null
},
"status": "Pending Approval",
"shippingCost": null,
"shippingAddress": {
"zip": "94567",
"state": "CA",
"internalId": null,
"country": "_unitedStates",
"city": "Pope Valley",
"attention": null,
"addrPhone": null,
"addressee": "Atherton Grocery",
"addr3": null,
"addr2": "Palo Alto",
"addr1": null
},
"shipAddressList": {
"type": null,
"name": "Unnamed Address",
"internalId": "212",
"externalId": null
},
"salesRep": null,
"salesforceID": "a0N5Y00000XLadRUAT",
"otherRefNum": "4343390",
"nullFieldList": null,
"memo": "Order 30",
"location": null,
"lastModifiedDate": 1621491357,
"itemList": {
"replaceAll": null,
"item": [
{
"unitsDisplay": null,
"taxRate1": "1.0",
"taxCode": {
"type": null,
"name": "VAT_IN:UNDEF-IN",
"internalId": "5",
"externalId": null
},
"tax1Amt": 2.18,
"shipMethod": null,
"shipGroup": null,
"serialNumbers": null,
"revRecStartDate": null,
"revRecSchedule": null,
"revRecEndDate": null,
"rate": "100.00",
"quantityRemaining": null,
"quantityReceived": null,
"quantityBilled": 0,
"quantity": 2,
"price": {
"type": null,
"name": "Base Price",
"internalId": "1",
"externalId": null
},
"poNum": null,
"orderLine": null,
"onHand": null,
"location": null,
"line": 38,
"jobName": null,
"itemReceive": null,
"itemName": null,
"itemIsFulfilled": null,
"item": {
"type": null,
"name": "Bow",
"internalId": "239",
"externalId": null
},
"grossAmt": 220,
"expectedReceiptDate": null,
"description": "A weapon for shooting arrows test",
"department": null,
"customFieldList": {
"customField": [
{
"valueLookup": null,
"value": "1",
"scriptId": "custcol_gh_line_no",
"internalId": "175",
"fieldType": null
}
]
},
"createPo": "_dropShipment",
"costEstimateType": null,
"costEstimate": null,
"classification": null,
"amount": 217.82
}
]
},
"internalId": "83943",
"handlingCost": null,
"externalId": "1",
"exchangeRate": 1,
"entity": {
"type": null,
"name": "21 Atherton Grocery",
"internalId": "362",
"externalId": null
},
"discountTotal": -20,
"discountRate": "-20.00",
"discountItem": {
"type": null,
"name": "Partner Discount",
"internalId": "-6",
"externalId": null
},
"department": {
"type": null,
"name": "PR Department",
"internalId": "1",
"externalId": null
},
"customForm": {
"type": null,
"name": "Custom Sales Order 2",
"internalId": "121",
"externalId": null
},
"customFieldList": {
"customField": [
{
"valueLookup": null,
"value": " - ",
"scriptId": "custbody_breadwinner_pc_internal_id",
"internalId": "299",
"fieldType": null
},
{
"valueLookup": null,
"value": "false",
"scriptId": "custbody23",
"internalId": "271",
"fieldType": null
},
{
"valueLookup": null,
"value": "2021-05-19 23:15:57",
"scriptId": "custbodylastmodifieddate",
"internalId": "298",
"fieldType": null
}
]
},
"currencyRecord": null,
"currencyName": "INR",
"createdFrom": null,
"createdDate": 1620386017,
"classification": {
"type": null,
"name": "Individual Partner Class",
"internalId": "2",
"externalId": null
},
"billingAddress": {
"zip": "94567",
"state": "CA",
"internalId": null,
"country": "_unitedStates",
"city": "Pope Valley",
"attention": null,
"addrPhone": null,
"addressee": "Atherton Grocery",
"addr3": null,
"addr2": "Palo Alto",
"addr1": null
},
"billAddressList": {
"type": null,
"name": "Unnamed Address",
"internalId": "212",
"externalId": null
}
}
]
}
}