Overview
This API is used for receiving items being purchased with Purchase Orders.
If the Location has a checkmark in field Require Receive, this method cannot be used.
|
Endpoint name |
|
|
Source table |
|
|
Fixed view |
Only has orders which are not fully received:
|
|
Requests allowed |
GET |
|
Primary Key |
|
|
Record ID |
|
|
Procedures |
|
Data
Field List
|
Property |
Type |
Max Len |
Description |
non-editable |
|
|
string uuid |
|
The system id of the record. |
|
|
|
string |
20 |
No. of the Purchase Order. |
Record ID |
|
|
string |
20 |
The number of the vendor |
|
|
|
string |
100 |
The vendor name |
|
|
|
string |
35 |
Your Reference. This field can be used for all kinds of info. |
|
|
|
string |
10 |
Location Code. If given on the header, usually all lines have that same location. |
|
|
|
enum |
|
The status of the order, it can be both Open or Released when items are being received. When released, the order is not editable. |
|
|
|
date |
|
The expected receipt date. |
|
|
|
string |
35 |
A shipment reference or delivery note. |
|
|
|
string |
35 |
If the invoice number has already been registered on the order, but often it is done after receipt of the items. |
|
|
|
integer |
|
The number of lines (items) on the order. |
|
|
|
array |
|
An array that contains the lines of the order. Will only be shown by using URL parameter |
|
|
|
date-time utc |
|
Timestamp. |
|
Example Object
Usage
Read all open purchase orders
GET .../openPurchaseOrders
Read a specific order
For this endpoint, it is enough to give the number of the order:
GET .../openPurchaseOrders([No.])
Example:
Reading order 106091 and get all the lines as well:
GET .../openPurchaseOrders('106091')?$expand=openPurchaseLines
Post Receipt
Usage of the procedures on openPurchaseOrders and API - Open Purchase Lines must be as follows:
-
Send in all received items for the order - on line level:
-
For item with item tracking (see below), use endpoint
openPurchaseLines(..)/..createItemTrackingfor each line to send in the Lot numbers. -
For every item without item tracking, use endpoint
openPurchaseLines(..)/..updateQuantityToReceiveto modify how many pieces were received. -
If a bin is used, use
openPurchaseLines(..)/..updateQuantityToReceiveToBininstead.
-
-
When all lines have got the correct quantity, lots and bins registered, the receipt can be posted either
-
manually
-
or with this procedure
openPurchaseOrders(id)/...postReceipt/as shown here below:
-
POST .../openPurchaseOrders([No.])/Microsoft.NAV.postReceipt
Body:
{
// no parameters
}
After a successful run when the receipt is for a Purchase Order, the following has happened.
-
Posted Purchase Receipt has been created, for all the received items
-
One Item Ledger Entry for each combination of item and lot
-
The columns Qty. Received has been updated on all the lines of the order