I am trying to create an `estimate` record through...
# general
l
I am trying to create an
estimate
record through the rest api. My example payload looks like this:
Copy code
{
  "entity": {
    "id": "6206743"
  },
  "item": {
    "items": [
      {
        "line": 1,
        "item": {
          "id": "348383"
        },
        "quantity": 10
      },
      {
        "line": 2,
        "item": {
          "id": "351979"
        },
        "quantity": 5
      }
    ]
  },
  "memo": "Quotevalidfor30days",
  "expirationDate": "2026-02-15",
  "custbody_sale_channel": 1,
  "shipMethod": 233250,
  "shippingAddress": {
    "addressee": "John Smith",
    "addr1": "123 Main St",
    "addr2": "Suite 100",
    "city": "Springfield",
    "state": "MO",
    "zip": "65801",
    "country": "US",
    "addrPhone": "<tel:314-999-9999|314-999-9999>"
  },
  "shipAddressList": null
}
If I remove the "shippingAddress" it creates without issue. However, with it included I get the error "Error while accessing a resource. Please enter value(s) for: Addressee, Phone, Address 1, City.". Does anyone know the proper address format for the rest API?
m
Looking at NS documentation I found this: POST http://demo123.suitetalk.api.netsuite.com/services/rest/record/v1/customer { “entityid”: “My Customer”, “companyname”: “My Company”, “email”: “another.customer@example.com”, “addressbook”: { “items”: [{ “label”: “New York HQ”, “addressbookaddress”: { “country”: “US”, “state”: “NY”, “zip”: “10001”, “addressee”: “Dwight Schrute” } }] } }
Hope it helps!
l
appreciate the feedback. I was ultimately able to Create the estimate w/o shipping address first. Then do separate update to add Shipping Address, and that worked.
1