Purchase Order

NetSuite exposes the purchase order record to REST web services. This record has the following subrecords:

The following elements are not accessible through REST web services:

If the Allow Expenses on Purchases accounting preference is set, the expenses sublist is also not accessible.

All other elements on this record are accessible through REST web services.

Note:

REST web services do not support legacy tax features. To work with taxation through REST web services, you must have the SuiteTax feature enabled. For more information about using SuiteTax, see SuiteTax.

The REST API Browser includes information about the field names and field types of the purchase order record, and about the HTTP methods, request parameters, and operations available to this record. For details, see the REST API Browser's purchase order reference page.

For information about using the REST API Browser, see The REST API Browser.

Record ID

The record ID for a purchase order REST record is purchaseOrder.

Prerequisites

You must enable the Purchase Orders feature before you can use this record through REST web services.

Usage Notes

Starting in 2026.1, when you set the grossAmt field for a taxable transaction line through REST web services, NetSuite recalculates the line amount field based on the applicable tax code, tax rate, and tax rounding rules. This behavior matches the NetSuite UI. In previous releases, REST web services ignored submitted grossAmt values, so setting this field didn't recalculate the line amount field.

Code Samples

The following samples show common use cases for a purchase order record.

Creating a Purchase Order

              POST https://demo123.suitetalk.api.netsuite.com/services/rest/record/v1/purchaseOrder
Body:
{ "entity": { "id": {{vendorId}} }, "item": { "items": [{ "item": { "id": {{ItemId}} }, "rate": 10 }] }
} 

            

Reading a Purchase Order

              GET https://demo123.suitetalk.api.netsuite.com/services/rest/record/v1/purchaseOrder/{{id}}?expandSubResources=true 

            

Updating a Purchase Order

              PATCH https://demo123.suitetalk.api.netsuite.com/services/rest/record/v1/purchaseOrder/{{id}}
Body:
{ "memo": "This is a test"
} 

            

Deleting a Purchase Order

              DELETE https://demo123.suitetalk.api.netsuite.com/services/rest/record/v1/purchaseOrder/{{id}} 

            

Related Topics

General Notices