Implementation Steps
| Task | Responsible Party |
|---|---|
| Provide API endpoint access details and credentials | FacilityOS |
| Set up automated job to send PO Header and PO Line Data, and to pull PO Receipt data | Client |
| Set up PO receiving screen for use by end users | FacilityOS |
| Review data and confirm accuracy | Client |
Data Flow
Note: PO and Receipt data is specific to a LogisticsOS profile. If multiple profiles will use PO line item receiving, PO data must be sent to and Receipt data must be pulled from multiple profiles. Consult your FacilityOS implementation contact for the correct ProfileID value(s).
- Add or update PO data
- Add or update a PO Header
- Add or update a PO Line for an existing PO Header
- Get PO receipt data
- Request PO Receipts for a specified timeframe, optionally filtering out processed receipts
- Mark processed PO Receipts as processed
API
Authentication: OAuth
Format: JSON
PO Header
For each PO, create or update the header details in FacilityOS to ensure the latest PO information is available. For updates, it is recommended to only send updates for records that have recently changed.
Fields
| Friendly Name | Field Name | Data Type | Required | Description |
|---|---|---|---|---|
| PO ID | po_ID | Text (50) | Yes | Primary Key Used to track Purchase Orders entered into system |
| PO Type | po_Type | Text (20) | No | Reporting use and may be displayed in the LOS UI |
| Business Unit | business_Unit | Text (50) | Yes | Reporting use and may be displayed in the LOS UI |
| Receive Status | Recv_Status | Text (1) | No | N = New, P = Partial, R = Received (complete) Reporting use and may be displayed in the LOS UI |
| Vendor ID | vendor_ID | Text (50) | No | Reporting use and may be displayed in the LOS UI |
| Vendor Name | vendor_Name | Text (50) | No | Reporting use and may be displayed in the LOS UI |
| Vendor Set ID | vendor_SetID | Text (20) | No | Reporting use and may be displayed in the LOS UI |
| Entered DateTime | entered_DT | DateTime | No | Reporting use and may be displayed in the LOS UI |
| PO Revision | po_Revision | Integer | No | Reporting use and may be displayed in the LOS UI |
| Total Order Amount | total_Order_Amt | Currency | No | Reporting use and may be displayed in the LOS UI |
| Default Cost Center | default_Cost_Center | Text (50) | No | Reporting use and may be displayed in the LOS UI |
| Default Deliver To | default_Deliver_To | Text (50) | No | Reporting use and may match EmpID in Recipient table; if so, the PO Lookup automation may configured to set the Recipient |
| Profile ID | profileID | Integer | Yes | The FacilityOS profile ID. Consult your FacilityOS implementation contact for the correct ProfileID value(s). |
Add a PO Header
Endpoint: POST /api/v1/po/header
Curl
curl -X POST \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"Business_Unit": "IT",
"PO_ID": "PO-100254",
"PO_Type": "STANDARD",
"RECV_STATUS": "N",
"VENDOR_ID": "VEND-1001",
"Vendor_Name": "Acme Office Supplies",
"VENDOR_SETID": "SET001",
"ENTERED_DT": "2026-10-21T17:25:13.528Z",
"PO_REVISION": 1,
"Total_Order_Amt": 2450.75,
"Default_Cost_Center": "CC-100",
"Default_Deliver_To": "Building A - Receiving",
"profileID": 1
}' \
'<base URL>/api/v1/po/header'
Update a PO Header
Endpoint: PATCH /api/v1/po/header
In the following example, the record's Default_Deliver_to is being updated to a new value and the Vendor_SetID value is being cleared. All other fields will retain their existing values.
When updating records, PO_ID and profileID are the only required fields.
Curl
curl -X PATCH \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"VENDOR_SETID": null,
"Default_Deliver_To": "Building B - Dock",
"profileID": 1
}' \
'<base URL>/api/v1/po/header'
PO Lines
For each PO line, create or update the line details in FacilityOS to ensure the latest PO line information is available. For updates, it is recommended to only send updates for records that have recently changed.
Fields
| Friendly Name | Field Name | Data Type | Required | Description |
|---|---|---|---|---|
| PO ID | po_Id | Text (50) | Yes | Composite Key (with Line_Number) Used to track Purchase Orders entered into system |
| Line Number | line_Number | Integer | Yes | Composite Key (with PO_ID) The line in the PO Line numbers should start with 1 and be sequential |
| Business Unit | business_Unit | Text (50) | Yes | Reporting use and may be displayed in the Line Item UI |
| Entered DateTime | entered_DT | Datetime | No | Reporting use |
| Quantity | quantity_PO | Numeric (11.4) | Yes | Reporting use and displayed in the Line Item UI Most quantities are whole numbers, but decimals are possible for units like gallons |
| Price | price_PO | Currency | No | Reporting use and may be displayed in the Line Item UI |
| Unit of Measure | unit_Of_Measure | Text (50) | No | Reporting use and may be displayed in the Line Item UI |
| Vendor Item ID | vendor_ItemId | Text (50) | No | Reporting use and may be displayed in the Line Item UI |
| Item Description | item_Description | Text (255) | Yes | Reporting use and may be displayed in the Line Item UI |
| Location ID | location_Id | Text (50) | No | Reporting use Vendor's Ship-to location; for central receiving, this is often the same for every order |
| Financial Asset SW | financial_Asset_SW | Text (1) | No | Reporting use |
| Requisition ID | req_Id | Text (50) | No | Reporting use |
| Schedule Line Number | schedule_Line_Number | Integer | No | Reporting use |
| Distribution Line Number | distribution_Line_Number | Integer | No | Reporting use |
| Delivery Location ID | delivery_Location_ID | Text (50) | No | Reporting use and may match EmpID in Recipient table; if so, the PO Lookup automation may be configured to set the Recipient |
| Delivery Comment | deliverycomment | Text (50) | No | Reporting use and may be displayed in the Line Item UI |
| Buyer Name | buyername | Text (50) | No | Reporting use and may be displayed in the Line Item UI |
| Default Cost Center | defaultcostcenter | Text (50) | No | Reporting use and may be displayed in the Line Item UI |
| Profile ID | profileID | Integer | Yes | The FacilityOS profile ID. Consult your FacilityOS implementation contact for the correct ProfileID value(s). |
Add a PO Line
Endpoint: POST /api/v1/po/line
Curl
curl -X POST \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"business_Unit": "IT",
"po_ID": "PO-100254",
"line_Number": 1,
"entered_DT": "2026-10-21T18:41:53.956Z",
"quantity_PO": 100,
"price_PO": 24.50,
"unit_Of_Measure": "EA",
"vendor_ItemId": "ITEM-1001",
"item_Description": "USB-C Charging Cable",
"location_ID": "LOC-001",
"financial_Asset_SW": "N",
"req_ID": "REQ-10025",
"schedule_Line_Number": 1,
"distribution_Line_Number": 1,
"delivery_Location_ID": "BLDG-A",
"delivery_Comment": "Deliver to IT receiving department",
"buyer_Name": "John Smith",
"default_Cost_Center": "CC-100",
"profileID": 1
}' \
'<base URL>/api/v1/po/line'
Update a PO Line
Endpoint: PATCH /api/v1/po/line
In the following example, the record's item_Description is being updated to a new value and the delivery_Comment value is being cleared. All other fields will retain their existing values.
When updating records, PO_ID, line_Number, and profileID are the only required fields.
Curl
curl -X PATCH \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"PO_ID": "PO-100254",
"line_Number": 1,
"item_Description": "USB-C Charging Cable v2",
"delivery_Comment": null,
"profileID": 1
}' \
'<base URL>/api/v1/po/line'
PO Receipts
At predefined intervals, query the FacilityOS API to retrieve recent PO receipts by specifying the start and end dates of the desired timeframe. Optionally (recommended), filter out receipts already marked as processed.
Get PO Receipts
Endpoint: GET /api/v1/po/receipts
Request
Fields
| Field Name | Required | Type | Descriptions/Notes |
|---|---|---|---|
| beginDate | Yes | DateTime | The start of the timeframe of receipts to pull Time zone matches that of database server (UTC for FacilityOS-hosted clients) |
| endDate | Yes | DateTime | The end of the timeframe of receipts to pull Time zone matches that of database server (UTC for FacilityOS-hosted clients) |
| PO_ID | No | Text | Purchase Order Number |
| returnUnprocessed | No | Integer | 1 = get receipts not marked as processed 0 = get receipts marked as processed; default |
| receiptSource | No | Text | The source of the receipt transaction |
| profileID | Yes | Integer | FacilityOS Profile ID. Consult your FacilityOS implementation contact for the correct ProfileID value(s). |
Curl
curl -X GET \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"beginDate": "2026-10-01T00:00:00.000Z",
"endDate": "2026-10-21T23:59:59.999Z",
"po_ID": "PO-100254",
"returnUnprocessed": 1,
"receiptSource": "INTRA",
"profileID": 1
}' \
'<base URL>/api/v1/po/receipts'Response
Fields
| Field Name | Type (Length) | Description | Purpose/Notes |
|---|---|---|---|
| Business_Unit | Text (50) | Business Unit | |
| PO_ID | Text (50) | Purchase Order Number | |
| PO_Line_Number | Integer | Line Number | |
| Recv_ID | String | Receipt ID | System-assigned unique ID for the PO and Line Number receipt transaction |
| ManifestNumber | Text (50) | Manifest ID | FacilityOS’s manifest/transaction ID |
| Quantity_Received | Numeric (11.4) | Quantity Received | Quantity received in manifest/transaction |
| PO_Type | Text (20) | PO Type | |
| Vendor_ItemID | Text (50) | Vendor Item ID | |
| Item_Description | Text (255) | Item Description | |
| IntraUsername | Text (50) | Username | The FacilityOS user who received the PO |
| ReceivedDateTime | Datetime | HDate | Timestamp of receipt |
| Unit_of_Measure | Text (50) | EA, PK, CT, etc. | |
| Price_PO | Currency | Cost per Unit | |
| Vendor_ID | Text (50) | Vendor ID | |
| Receiving_Comments | Text (350) | Comments from receipt activity | |
| Processed | Integer | For ERP to mark receipt as processed | For ERP to mark receipt as processed 1 = processed by ERP 0 = not processed by ERP |
| ProcessedDateTime | Datetime | Timestamp of receipt being processed | Timestamp of receipt being processed |
| Receipt_Source | Text | The source of the receipt transaction | |
| profileID | Integer | FacilityOS Profile ID | FacilityOS Profile ID |
Sample
The following is a sample response with a single receipt transaction. Depending on the dataset, multiple receipt transactions (objects) may be returned in the array.
[
{
"business_UNIT": "IT",
"po_ID": "PO-100254",
"po_Line_Number": 1,
"recv_ID": "SC00000034",
"manifestNumber": "130054AA32",
"quantity_Received": 2,
"po_Type": "GEN",
"vendor_ItemId": "0201255",
"item_Description": "100 Count Cable Ties",
"intraUsername": "admin",
"receivedDateTime": "2026-10-12T11:24:21.093",
"unit_of_Measure": "EA",
"price_PO": 20.00,
"vendor_ID": "0000000002",
"receiving_Comments": "",
"processed": 0,
"processedDateTime": "1900-01-01T00:00:00",
"receipt_Source": "",
"profileID": 1
}
]
Mark a Receipt as Processed
Endpoint: POST /api/v1/po/receiptMarkProcessed
Request
Fields
| Friendly Name | Field Name | Data Type | Required | Description |
|---|---|---|---|---|
| Receipt ID | receiptID | String (50) | Yes | Primary Key Used to track receipt transactions |
| Mark as Processed | markProcessed | Integer | Yes | 1 = receipt has been marked as processed 0 = receipt has been not marked as processed |
| External Receipt Batch ID | externalReceiptBatchID | String | No | The Receipt Batch ID from the ERP |
| Profile ID | profileID | Integer | Yes | FacilityOS Profile ID. Consult your FacilityOS implementation contact for the correct ProfileID value(s). |
Curl
curl -X POST \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <token>' \
-d '{
"receiptID": "SC00000034",
"markProcessed": 1,
"externalReceiptBatchID": "ERP30217",
"profileID": 1
}' \
'<base URL>/api/v1/po/receiptMarkProcessed'