Download OpenAPI specification:
API documentation for the Wherefour ERP/traceability platform. More information at: wherefour.com.
API requests are limited to 1 request per second.
Requests over the limit receive an HTTP 429 Too Many Requests response with a plain-text body of Retry later. No Retry-After header is sent.
To stay within the limit:
429, wait at least one second before retrying, and back off further if 429s continue.Returns a list of inventory categories, ordered by name.
| page | integer Results page to view |
[- {
- "id": 1,
- "name": "Ingredients"
}, - {
- "id": 5,
- "name": "Labor"
}, - {
- "id": 2,
- "name": "Packaging"
}, - {
- "id": 8,
- "name": "Parts"
}, - {
- "id": 3,
- "name": "Products"
}
]Locates a facility by name
| page | integer Results page to view |
| name | string Case-insensitive partial name search |
| locator_code | string Case-insensitive partial locator code search |
[- {
- "id": 1,
- "name": "Main Facility",
- "locator_code": "MAI",
- "primary": true,
- "allowed_user_strategy": "all_users",
- "level_1_name": "Zone",
- "level_2_name": "Aisle",
- "level_3_name": "Rack",
- "level_4_name": "Rack",
- "level_5_name": "Shelf",
- "level_6_name": "Bin"
}
]Returns a paginated list of all inventory items.
| updated_at | string Oldest date/time for the records to return |
| page | integer Results page to view |
[- {
- "id": 56,
- "name": "New inventory item",
- "category_name": "Ingredients",
- "on_hand": "0.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "unit_of_order": "each",
- "unit_of_invoice": "each",
- "unit_of_pick_and_ship": "each",
- "unit_of_weight": "pound",
- "unit_of_dimension": "inch",
- "purchase_conversion": "1.0",
- "property": "finished_good",
- "sku": "1234",
- "upc": "5678",
- "pull_strategy": "FIFO",
- "reorder_point": "0.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "quantity_not_tracked": false,
- "conversions": [ ],
- "weight": 100,
- "height": "10.0",
- "width": "10.0",
- "length": "20.0",
- "internal_photo_is_public": true,
- "internal_description": "This is an internal description",
- "internal_description_is_public": true,
- "public_name": "New inventory item",
- "public_description": "This is an internal description",
- "show_hold_amounts": true,
- "internal_name_is_public": true,
- "receive_default_delivery_method_id": 1,
- "receive_default_location_id": 1,
- "receive_default_accept_rows": 1,
- "receive_default_to_total_cost": true,
- "receive_default_stock_status": "active",
- "receive_require_barcode": false,
- "receive_require_serial_number": false,
- "receive_require_location": false,
- "receive_require_expiration_date": false,
- "receive_prefill_expiration_date": false,
- "receive_expiration_date_days": 30,
- "receive_allow_unit_of_receiving_change": true,
- "receive_keep_quantity": true,
- "receive_keep_unit_of_receiving": true,
- "receive_keep_cost": true,
- "receive_keep_vendor_item_number": true,
- "receive_keep_location": true,
- "receive_keep_expiration_date": true,
- "receive_keep_stock_description": true,
- "receive_allow_custom_field_entry": true,
- "created_at": "2024-06-15T02:54:11.546Z",
- "updated_at": "2024-06-15T02:54:11.546Z",
- "custom_field_values": [
- {
- "id": 1,
- "custom_field_id": 1,
- "inventory_id": 1,
- "active_stock_id": 1,
- "value": "1",
- "value_type": "number",
- "created_at": "2021-08-23T14:25:37.200Z",
- "updated_at": "2021-08-23T14:25:37.200Z",
- "custom_field": {
- "id": 1,
- "name": "Test",
- "value_type": "number",
- "created_at": "2021-08-23T14:25:21.663Z",
- "updated_at": "2021-08-23T14:25:21.663Z"
}
}
]
}
]Creates a new inventory item with the provided parameters.
| name | string |
| category_id | number |
| unit_of_use | string |
| unit_of_purchase | string |
| unit_of_order | string |
| unit_of_invoice | string |
| unit_of_pick_and_ship | string |
| unit_of_weight | string or null |
| unit_of_dimension | string or null |
| purchase_conversion | number |
| property | string Enum: "raw_material" "overhead" "work_in_progress" "finished_good" |
| sku | string or null |
| upc | string or null |
| pull_strategy | string Enum: "FIFO" "Hand Pick" "FEFO" "LIFO" |
| reorder_point | number |
| rate | number |
| lead_time | number |
| retired | boolean |
| waste_percentage | number |
| quantity_not_tracked | boolean |
| standard_cost | number |
| weight | number or null |
| height | number or null |
| width | number or null |
| length | number or null |
{- "name": "Whole milk",
- "category_id": 1,
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "unit_of_order": "gallon",
- "unit_of_invoice": "gallon",
- "unit_of_pick_and_ship": "gallon",
- "unit_of_weight": null,
- "unit_of_dimension": null,
- "purchase_conversion": 1,
- "property": "raw_material",
- "sku": null,
- "upc": null,
- "pull_strategy": "FIFO",
- "reorder_point": 50,
- "lead_time": 1,
- "retired": false,
- "waste_percentage": 0,
- "quantity_not_tracked": false,
- "standard_cost": 0,
- "weight": null,
- "height": null,
- "width": null,
- "length": null
}{- "id": 0,
- "name": "string",
- "category_name": "string",
- "on_hand": "string",
- "unit_of_use": "string",
- "unit_of_purchase": "string",
- "unit_of_order": "string",
- "unit_of_invoice": "string",
- "unit_of_pick_and_ship": "string",
- "unit_of_weight": "string",
- "unit_of_dimension": "string",
- "purchase_conversion": "string",
- "property": "string",
- "sku": "string",
- "upc": "string",
- "pull_strategy": "string",
- "reorder_point": "string",
- "lead_time": 0,
- "retired": true,
- "waste_percentage": "string",
- "quantity_not_tracked": true,
- "conversions": [
- {
- "to_count": "string",
- "from_count": "string",
- "catch_weight": true,
- "maximum_weight": "string",
- "minimum_weight": "string",
- "unit_of_measurement": "string",
- "_destroy": null
}
], - "weight": 0,
- "height": "string",
- "width": "string",
- "length": "string",
- "created_at": "string",
- "updated_at": "string",
- "custom_field_values": [
- {
- "id": 0,
- "custom_field_id": 0,
- "inventory_id": 0,
- "active_stock_id": 0,
- "value": "string",
- "value_type": "string",
- "created_at": "string",
- "updated_at": "string",
- "custom_field": {
- "id": 0,
- "name": "string",
- "value_type": "string",
- "created_at": "string",
- "updated_at": "string"
}
}
], - "internal_photo_is_public": true,
- "internal_description": "string",
- "internal_description_is_public": true,
- "public_name": "string",
- "public_description": "string",
- "show_hold_amounts": true,
- "internal_name_is_public": true,
- "receive_default_delivery_method_id": null,
- "receive_default_location_id": null,
- "receive_default_accept_rows": 0,
- "receive_default_to_total_cost": true,
- "receive_default_stock_status": "string",
- "receive_require_barcode": true,
- "receive_require_serial_number": true,
- "receive_require_location": true,
- "receive_require_expiration_date": true,
- "receive_prefill_expiration_date": true,
- "receive_expiration_date_days": 0,
- "receive_allow_unit_of_receiving_change": true,
- "receive_keep_quantity": true,
- "receive_keep_unit_of_receiving": true,
- "receive_keep_cost": true,
- "receive_keep_vendor_item_number": true,
- "receive_keep_location": true,
- "receive_keep_expiration_date": true,
- "receive_keep_stock_description": true,
- "receive_allow_custom_field_entry": true
}Adds a new stock lot to the specified inventory item.
| inventory_id required | integer inventory item record ID |
| delivery_method_id required | integer |
| location_id | integer |
| vendor_id | integer |
| vendor_reference | string |
| vendor_item_number | string |
| count required | number |
| cost required | number |
| cost_entered_is_total_cost | boolean True when |
| lot_code required | string Required unless |
| barcode | string |
| serial_number | string |
| generate_lot_code | boolean Generates the lot code, when automatic sequencing is on for the account |
| generate_barcode | boolean Generates the barcode, when automatic sequencing is on for the account |
| generate_serial_number | boolean Generates the serial number, when automatic sequencing is on for the account |
| expiration_date | string |
| received_date | string Date and time received, in the API user's date and time style |
| stock_description | string |
| status required | string Enum: "active" "inactive" "on_hold" "quarantined" The new stock's status |
{- "delivery_method_id": 1,
- "location_id": 1,
- "vendor_id": 1,
- "lot_code": "1234",
- "stock_description": "New stock",
- "count": 100,
- "cost": 100,
- "cost_entered_is_total_cost": true,
- "status": "active",
- "expiration_date": "11/05/25",
- "received_date": "11/05/2024 02:39 PM"
}{- "id": 35,
- "user_id": 6,
- "inventory_id": 4,
- "location_id": 1,
- "lot_code": "1234",
- "status": "active",
- "barcode": null,
- "details": "New stock",
- "note": "",
- "count": "100.0",
- "cost": "100.0",
- "vendor_id": 1,
- "expiration_date": "2025-11-05",
- "created_at": "2024-11-05T17:42:31.000Z",
- "updated_at": "2024-11-05T17:42:31.000Z",
- "base_count": "100.0",
- "rate": null,
- "purchase_id": null,
- "global_identifier": "18c63c87-fcac-40d3-b334-22ef41c85cf5",
- "organization_id": 1,
- "expiration_notified_at": null,
- "weight": null,
- "height": null,
- "width": null,
- "length": null,
- "serial_number": null,
- "generate_barcode": false,
- "generate_lot_code": false,
- "generate_serial_number": false,
- "custom_field_values": [ ]
}Lists active stocks of the provided inventory item.
| inventory_id required | integer inventory item record ID |
| location_name | string The name of the location to filter stock lots by |
| location_locator_code | string The locator code of the location to filter stock lots by |
| page | string Results page to view |
[- {
- "id": 1,
- "name": "Raw material A",
- "lot_code": "WM001",
- "status": "active",
- "barcode": "WM-000001-18",
- "details": "Raw material A",
- "note": "buy lot WM001",
- "count": "100.0",
- "cost": "200.0",
- "expiration_date": "2026-12-14",
- "weight": null,
- "height": null,
- "width": null,
- "length": null,
- "created_at": "2026-05-18T17:53:40.213Z",
- "updated_at": "2026-05-18T17:53:40.213Z",
- "custom_field_values": [ ],
- "location": { }
}, - {
- "id": 2,
- "name": "Raw material A",
- "lot_code": "WM002",
- "status": "active",
- "barcode": "WM-000002-18",
- "details": "Raw material A",
- "note": "buy lot WM002",
- "count": "375.0",
- "cost": "300.0",
- "expiration_date": "2026-11-29",
- "weight": null,
- "height": null,
- "width": null,
- "length": null,
- "created_at": "2026-05-18T17:53:40.213Z",
- "updated_at": "2026-05-18T17:53:40.213Z",
- "custom_field_values": [ ],
- "location": { }
}, - {
- "id": 3,
- "name": "Raw material A",
- "lot_code": "WM003",
- "status": "active",
- "barcode": "WM-000003-18",
- "details": "Raw material A",
- "note": "buy lot WM003",
- "count": "185.0",
- "cost": "500.0",
- "expiration_date": "2026-12-04",
- "weight": null,
- "height": null,
- "width": null,
- "length": null,
- "created_at": "2026-05-18T17:53:40.213Z",
- "updated_at": "2026-05-18T17:53:40.213Z",
- "custom_field_values": [ ],
- "location": { }
}, - {
- "id": 4,
- "name": "Raw material A",
- "lot_code": "WM004",
- "status": "active",
- "barcode": "WM-000004-18",
- "details": "Raw material A",
- "note": "buy lot WM004",
- "count": "750.0",
- "cost": "1200.0",
- "expiration_date": "2026-12-06",
- "weight": null,
- "height": null,
- "width": null,
- "length": null,
- "created_at": "2026-05-18T17:53:40.213Z",
- "updated_at": "2026-05-18T17:53:40.213Z",
- "custom_field_values": [ ],
- "location": { }
}
]Gets the last stock lot change for the specified inventory item.
| inventory_id | integer Optional inventory ID to get the most recent stock lot change for |
[- {
- "id": 1,
- "user_id": 1,
- "user_first_name": "Tony",
- "user_last_name": "Fiorello",
- "reason": "purchase",
- "lot_code": "WM001",
- "old_lot_code": "WM001",
- "barcode": "WM-000001-18",
- "old_barcode": "WM-000001-18",
- "details": "Whole milk",
- "rate": null,
- "cost": "200.0",
- "count": "100.0",
- "change": "100.0",
- "absolute_change": "100.0",
- "note": "buy lot 1",
- "work_order": null,
- "expiration_date": "2020-05-31",
- "created_at": "2020-09-11T13:57:47.026Z",
- "updated_at": "2020-09-11T13:57:47.026Z",
- "stock": {
- "id": 1,
- "name": "Whole milk",
- "lot_code": "WM001",
- "status": "active",
- "barcode": "WM-000001-18",
- "details": "Whole milk",
- "note": "buy lot WM001",
- "count": "100.0",
- "cost": "200.0",
- "expiration_date": "2020-10-11",
- "created_at": "2020-09-11T13:57:47.058Z",
- "updated_at": "2020-09-11T13:57:47.058Z",
- "inventory": {
- "id": 1,
- "name": "Whole milk",
- "category_name": "Ingredients",
- "on_hand": "1410.0",
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "property": "raw_material",
- "sku": null,
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "location": {
- "id": 1,
- "name": "North Warehouse"
}, - "vendor": {
- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Foods Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "mobile": null,
- "fax": null,
- "note": null,
- "kind": "distributor",
- "created_at": "2020-09-11T13:57:47.005Z",
- "updated_at": "2020-09-11T13:57:47.005Z",
- "custom_field_1": null,
- "custom_field_2": null,
- "custom_field_3": null,
- "custom_field_4": null,
- "business_license_number": null
}, - "purchase": null
}
}
]Returns inventory items that match the given name or SKU. Multiple matches may be returned.
| page | integer Results page to view |
Search can be performed based on EITHER the inventory item name, OR a single SKU or an array of SKUs. The inventory item name will take precedence over the SKU parameter. Multiple matches may be returned.
| name | string Part of the inventory item's name |
string or Array of strings One SKU, or an array of SKUs | |
| location_id | integer |
{- "name": "Product Name Here"
}[- {
- "id": 3,
- "name": "Bulk chocolate",
- "category_name": "Ingredients",
- "on_hand": "0.0",
- "unit_of_use": "pound",
- "unit_of_purchase": "pound",
- "purchase_conversion": "1.0",
- "property": "work_in_progress",
- "sku": "123456",
- "upc": "AAABBB",
- "pull_strategy": "Hand Pick",
- "reorder_point": "10.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}
]Lists invoices for a customer
| customer_id required | integer customer record ID |
[- {
- "id": 6,
- "invoice_date": "2020-09-04",
- "status": "draft",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "invoice_number": "INV100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "invoice_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Creates a new invoice for the customer.
| customer_id required | integer customer record ID |
| invoice_number required | string Not generated automatically, so send the number you want on the invoice |
| invoice_date required | string |
| status required | string Enum: "draft" "open" "paid" "canceled" "archived" |
| payment_term_id | integer or null |
| delivery_method_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| quote_id | integer |
| instructions | string or null |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
required | Array of objects |
Array of objects (custom_line_items) |
{- "invoice_number": "INV100",
- "invoice_date": "2020-09-04",
- "payment_term_id": null,
- "status": "open",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "invoice_items_attributes": [
- {
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "invoice_item_details_attributes": [
- {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 1
}
}, - {
- "kind": "note",
- "note": "Stack no more than 4 high."
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 6,
- "invoice_date": "2020-09-04",
- "status": "draft",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "invoice_number": "INV100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "invoice_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Updates an existing invoice
| invoice_id required | integer invoice record ID |
| customer_id required | integer customer record ID |
| invoice_number | string |
| invoice_date | string |
| status | string Enum: "draft" "open" "paid" "canceled" "archived" |
| payment_term_id | integer or null |
| delivery_method_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| quote_id | integer |
| instructions | string or null |
| invoiced | boolean |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
Array of objects | |
Array of objects (custom_line_items-2) |
{- "invoice_number": "INV100",
- "invoice_date": "2020-09-04",
- "payment_term_id": null,
- "status": "open",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "invoice_items_attributes": [
- {
- "id": 2,
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "_destroy": false,
- "invoice_item_details_attributes": [
- {
- "id": 52,
- "note": "Stack no more than 3 high."
}, - {
- "id": 53,
- "_destroy": true
}, - {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 2
}
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "id": 1,
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100,
- "_destroy": false
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 6,
- "invoice_date": "2020-09-04",
- "status": "draft",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "invoice_number": "INV100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "invoice_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Returns a paginated list of all invoices.
| updated_at | string Oldest date/time for the records returned |
| page | integer Results page to view |
[- {
- "id": 6,
- "invoice_date": "2020-09-04",
- "status": "open",
- "salesperson_id": null,
- "salesperson_name": "",
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "invoice_number": "INV100",
- "payment_term_id": null,
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "invoice_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "invoice_item_details": [ ]
}
]
}
]Retrieves a invoice record by ID
| invoice_id required | integer Example: 1 ID for the invoice record |
[- {
- "id": 1,
- "invoice_date": "2020-09-04",
- "status": "open",
- "salesperson_id": null,
- "salesperson_name": null,
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "invoice_number": "INV1",
- "payment_term_id": null,
- "created_at": "2020-09-11T13:57:46.842Z",
- "updated_at": "2020-09-12T16:22:26.851Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "salesperson": "",
- "invoice_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "invoice_item_details": [ ]
}, - {
- "id": 12,
- "name": "Bulk chocolate",
- "inventory_id": 3,
- "category_name": "Ingredients",
- "count": "0.0",
- "cost": "0.0",
- "sku": null,
- "created_at": "2020-09-12T16:22:26.858Z",
- "updated_at": "2020-09-12T16:22:26.858Z",
- "invoice_item_details": [ ]
}, - {
- "id": 13,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:22:26.863Z",
- "updated_at": "2020-09-12T16:22:26.863Z",
- "invoice_item_details": [ ]
}
]
}
]Locates an invoice by the invoice_number
| invoice_number | string non-empty Example: invoice_number={
"invoice_number": "INV1"
} The invoice number in Wherefour to locate. All invoices with matching results will be returned. |
| page | integer Results page to view |
{- "invoice_number": "INV1"
}[- {
- "id": 1,
- "invoice_date": "2020-09-04",
- "status": "open",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "300.0",
- "discount": "10.0",
- "tax": "0.00",
- "shipping": "25.0",
- "total": "315.0",
- "invoice_number": "INV1",
- "payment_term_id": 1,
- "created_at": "2020-07-16T19:49:19.481Z",
- "updated_at": "2020-07-16T19:49:19.481Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-07-16T19:49:19.394Z",
- "updated_at": "2020-07-16T19:49:19.394Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "invoice_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "invoice_item_details": [
- {
- "id": 51,
- "invoice_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "invoice_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "invoice_item_details": [ ]
}
]
}
]Locates a location by name
| page | integer Results page to view |
| name | string Case-insensitive partial name search |
| locator_code | string Case-insensitive partial locator code search |
| facility_id | integer Filter locations to this facility |
| parent_location_id | integer Filter locations to this parent location |
| level_number | integer Filter locations to this level number |
[- {
- "id": 5,
- "facility_id": 1,
- "parent_location_id": null,
- "name": "London Warehouse",
- "locator_code": "LONW",
- "global_identifier": "",
- "locator_name_path": "Main Facility:London Warehouse",
- "locator_code_path": "MAI:LONW",
- "level_number": 1,
- "level_name": "Zone",
- "allowed_for_additives": true,
- "allowed_for_pick_and_ship": true,
- "allowed_for_returns": true,
- "allowed_for_warehouse_receive": true,
- "allowed_for_work_order_pulls": true,
- "child_location_count": 0
}, - {
- "id": 6,
- "facility_id": 1,
- "parent_location_id": null,
- "name": "Sydney Warehouse",
- "locator_code": "SYDW",
- "global_identifier": "",
- "locator_name_path": "Main Facility:Sydney Warehouse",
- "locator_code_path": "MAI:SYDW",
- "level_number": 1,
- "level_name": "Zone",
- "allowed_for_additives": true,
- "allowed_for_pick_and_ship": true,
- "allowed_for_returns": true,
- "allowed_for_warehouse_receive": true,
- "allowed_for_work_order_pulls": true,
- "child_location_count": 0
}
]Retrieves a location record by ID
| location_id required | integer Example: 1 ID for the location record |
[- {
- "id": 5,
- "facility_id": 1,
- "parent_location_id": null,
- "name": "London Warehouse",
- "locator_code": "LONW",
- "global_identifier": "",
- "locator_name_path": "Main Facility:London Warehouse",
- "locator_code_path": "MAI:LONW",
- "level_number": 1,
- "level_name": "Zone",
- "allowed_for_additives": true,
- "allowed_for_pick_and_ship": true,
- "allowed_for_returns": true,
- "allowed_for_warehouse_receive": true,
- "allowed_for_work_order_pulls": true,
- "child_location_count": 0
}
]Returns all the orders for the customer ID provided.
| customer_id required | integer customer record ID |
| updated_at | string Oldest date/time for the records to return |
| page | integer Results page to view |
[- {
- "id": 6,
- "order_date": "2020-09-04",
- "produce_date": "2020-09-04",
- "deliver_date": "2020-09-04",
- "po_number": "12345",
- "status": "open",
- "order_status_id": 1,
- "internal_notes": "Rush order",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "order_number": "SO100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "order_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [
- {
- "id": 51,
- "order_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Creates a new order for the customer.
| customer_id required | integer customer record ID |
| order_number required | string |
| order_date required | string |
| order_status_id | integer |
| price_tier_id | integer |
| ship_from_address_id | integer Facility Address ID, not Facility ID or Customer Address ID |
| po_number | string |
| payment_term_id | integer or null |
| deliver_date | string |
| produce_date | string |
| ship_date | string |
| delivery_method_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| quote_id | integer |
| instructions | string or null |
| internal_notes | string or null |
| invoiced | boolean |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
required | Array of objects |
Array of objects (custom_line_items) |
{- "order_number": "SO100",
- "order_date": "2020-09-04",
- "deliver_date": "2020-09-04",
- "produce_date": "2020-09-04",
- "po_number": "12345",
- "payment_term_id": null,
- "order_status_id": 1,
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "internal_notes": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "order_items_attributes": [
- {
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "order_item_details_attributes": [
- {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 1
}
}, - {
- "kind": "note",
- "note": "Stack no more than 4 high."
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 6,
- "order_date": "2020-09-04",
- "produce_date": "2020-09-04",
- "deliver_date": "2020-09-04",
- "po_number": "12345",
- "status": "open",
- "order_status_id": 1,
- "internal_notes": "Rush order",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "order_number": "SO100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "order_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [
- {
- "id": 51,
- "order_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Updates an existing order
| order_id required | integer order record ID |
| customer_id required | integer customer record ID |
| order_number | string |
| order_date | string |
| order_status_id | integer |
| po_number | string |
| produce_date | string |
| deliver_date | string |
| ship_date | string |
| price_tier_id | integer |
| payment_term_id | integer or null |
| delivery_method_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| quote_id | integer |
| ship_from_address_id | integer Facility Address ID, not Facility ID or Customer Address ID |
| instructions | string or null |
| internal_notes | string or null |
| invoiced | boolean |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
Array of objects | |
Array of objects (custom_line_items-2) |
{- "order_number": "SO100",
- "order_date": "2020-09-04",
- "payment_term_id": null,
- "order_status_id": 1,
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "internal_notes": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "order_items_attributes": [
- {
- "id": 2,
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "_destroy": false,
- "order_item_details_attributes": [
- {
- "id": 52,
- "note": "Stack no more than 3 high."
}, - {
- "id": 53,
- "_destroy": true
}, - {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 2
}
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "id": 1,
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100,
- "_destroy": false
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
], - "po_number": "12345",
- "produce_date": "2020-09-04",
- "deliver_date": "2020-09-04"
}[- {
- "id": 6,
- "order_date": "2020-09-04",
- "produce_date": "2020-09-04",
- "deliver_date": "2020-09-04",
- "po_number": "12345",
- "status": "open",
- "order_status_id": 1,
- "internal_notes": "Rush order",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "order_number": "SO100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "order_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [
- {
- "id": 51,
- "order_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Performs a "pick and ship" for the specified order. Wherefour will auto-select available lot coded inventory, based on each inventory item's pull strategy, to fulfill the order. If the location is specified, only inventory at that location will be considered. If not enough inventory is available, a partial shipment will be created. Results of the shipment, with the selected stock lots, will be returned.
The optional ship_date param can be used to specify the timestamp of the shipment. Date/time should be in the format "2021-02-02 12:00 AM" and in the same time zone as the user's Wherefour settings.
The request will be rejected with a 422 response if the order has already been fulfilled, if shipments are blocked for the customer, or if the order's order status does not allow shipments.
| customer_id required | integer customer record ID |
| order_id required | integer order record ID |
| delivery_method required | string |
| location_id | integer ID of the Wherefour Location to pull stock from. If not provided, auto ship will pull available stock lots from any location. |
| tracking_number | string Tracking number to record for the shipment. |
| ship_date | string |
{- "tracking_number": "123456",
- "delivery_method": "UPS Ground",
- "location_id": 1
}{- "messages": [
- {
- "message": "Auto pick and ship request for Order #SO1042 has been queued."
}
]
}Returns the most recent shipment information for the order ID provided.
| customer_id required | integer Example: 1 customer record ID |
| order_id required | integer order record ID |
[- {
- "id": 1,
- "order_id": 2,
- "user_name": "Tony Fiorello",
- "ship_date": "2020-09-12T16:48:00.000Z",
- "shipment_number": 1,
- "tracking_number": null,
- "note": null,
- "created_at": "2020-09-12T16:48:13.512Z",
- "updated_at": "2020-09-12T16:48:13.512Z",
- "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "order": {
- "id": 2,
- "order_date": "2020-09-10",
- "produce_date": "2020-09-11",
- "deliver_date": "2020-09-11",
- "po_number": "123456-55",
- "status": "invoiced",
- "salesperson_id": null,
- "salesperson_name": null,
- "delivery_method_id": 1,
- "instructions": "\nShipment #1: 09/12/20\n10.0 Each - Chocolate bar (lot code: SC-00000)\n40.0 Cases - Chocolate bar, finished case (lot code: SCC-0000)\n",
- "subtotal": "1400.0",
- "discount": "0.00",
- "tax": "0.00",
- "shipping": "0.00",
- "total": "1400.0",
- "order_number": "SO2",
- "payment_term_id": 1,
- "created_at": "2020-09-11T13:57:46.842Z",
- "updated_at": "2020-09-12T16:48:13.688Z",
- "invoiced_at": "2020-09-11T00:00:00.000Z"
}, - "shipment_items": [
- {
- "id": 1,
- "count": "10.0",
- "inventory_name": "Chocolate bar",
- "inventory_sku": "SK0001",
- "auto_ship": [
- {
- "adjustment_id": 25,
- "stock_id": 13,
- "lot_code": "SC-00000",
- "barcode": "CH-000001-18",
- "count": "10.0",
- "change": "-10.0",
- "reason": "shipment"
}
]
}, - {
- "id": 2,
- "count": "40.0",
- "inventory_name": "Chocolate bar, finished case",
- "inventory_sku": "SK0002",
- "auto_ship": [
- {
- "adjustment_id": 26,
- "stock_id": 14,
- "lot_code": "SCC-0000",
- "barcode": "CHCA-000001-18",
- "count": "40.0",
- "change": "-40.0",
- "reason": "shipment"
}
]
}
]
}
]Returns the most recent shipment information for the order ID provided.
| customer_id required | integer Example: 1 customer record ID |
| order_id required | integer Example: 2 order record ID |
| page | integer Results page to view |
[- {
- "id": 1,
- "order_id": 2,
- "user_name": "Tony Fiorello",
- "ship_date": "2020-09-12T16:48:00.000Z",
- "shipment_number": 1,
- "tracking_number": null,
- "note": null,
- "created_at": "2020-09-12T16:48:13.512Z",
- "updated_at": "2020-09-12T16:48:13.512Z",
- "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "order": {
- "id": 2,
- "order_date": "2020-09-10",
- "produce_date": "2020-09-11",
- "deliver_date": "2020-09-11",
- "po_number": "123456-55",
- "status": "invoiced",
- "salesperson_id": "",
- "salesperson_name": "",
- "delivery_method_id": 1,
- "instructions": "\nShipment #1: 09/12/20\n10.0 Each - Chocolate bar (lot code: SC-00000)\n40.0 Cases - Chocolate bar, finished case (lot code: SCC-0000)\n",
- "subtotal": "1400.0",
- "discount": "",
- "tax": "",
- "shipping": "",
- "total": "1400.0",
- "order_number": "SO2",
- "payment_term_id": 1,
- "created_at": "2020-09-11T13:57:46.842Z",
- "updated_at": "2020-09-12T16:48:13.688Z",
- "invoiced_at": "2020-09-11T00:00:00.000Z"
}, - "shipment_items": [
- {
- "id": 1,
- "count": "10.0",
- "inventory_name": "Chocolate bar",
- "inventory_sku": "SK0001",
- "auto_ship": [
- {
- "adjustment_id": 25,
- "stock_id": 13,
- "lot_code": "SC-00000",
- "barcode": "CH-000001-18",
- "count": "10.0",
- "change": "-10.0",
- "reason": "shipment"
}
]
}, - {
- "id": 2,
- "count": "40.0",
- "inventory_name": "Chocolate bar, finished case",
- "inventory_sku": "SK0002",
- "auto_ship": [
- {
- "adjustment_id": 26,
- "stock_id": 14,
- "lot_code": "SCC-0000",
- "barcode": "CHCA-000001-18",
- "count": "40.0",
- "change": "-40.0",
- "reason": "shipment"
}
]
}
]
}
]Returns a paginated list of all orders.
| updated_at | string Oldest date/time for the records returned |
| status | string Order status |
| search_start_date | string Oldest order date, produce on date, deliver on date, or ship on date to return |
| search_end_date | string Newest order date, produce on date, deliver on date, or ship on date to return |
| page | integer Results page to view |
[- {
- "id": 6,
- "order_date": "2020-09-04",
- "produce_date": "2020-09-04",
- "deliver_date": "2020-09-04",
- "po_number": "12345",
- "status": "open",
- "order_status_id": 1,
- "salesperson_id": null,
- "salesperson_name": "",
- "delivery_method_id": 1,
- "instructions": "",
- "internal_notes": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "order_number": "SO100",
- "payment_term_id": null,
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "invoiced_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "order_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [
- {
- "id": 51,
- "order_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "order_item_details": [ ]
}
]
}
]Retrieves an order record by ID
| order_id required | integer Example: 1 ID for the order record |
[- {
- "id": 1,
- "order_date": "3/1/20",
- "produce_date": "3/1/20",
- "deliver_date": "3/1/20",
- "po_number": "123456-11",
- "status": "complete",
- "order_status_id": 5,
- "salesperson_id": null,
- "salesperson_name": null,
- "delivery_method_id": 1,
- "instructions": "",
- "internal_notes": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "order_number": "SO1",
- "payment_term_id": null,
- "created_at": "2020-09-11T13:57:46.842Z",
- "updated_at": "2020-09-12T16:22:26.851Z",
- "invoiced_at": "2020-09-11T00:00:00.000Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "salesperson": "",
- "order_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "order_item_details": [
- {
- "id": 51,
- "order_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "order_item_details": [ ]
}, - {
- "id": 12,
- "name": "Bulk chocolate",
- "inventory_id": 3,
- "category_name": "Ingredients",
- "count": "0.0",
- "cost": "0.0",
- "sku": null,
- "created_at": "2020-09-12T16:22:26.858Z",
- "updated_at": "2020-09-12T16:22:26.858Z",
- "order_item_details": [ ]
}, - {
- "id": 13,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:22:26.863Z",
- "updated_at": "2020-09-12T16:22:26.863Z",
- "order_item_details": [ ]
}
]
}
]Locates an order by the order_number
| order_number | string non-empty Example: order_number={
"order_number": "SO1"
} The sales order number in Wherefour to locate. All orders with matching results will be returned. |
| page | integer Results page to view |
{- "order_number": "SO1"
}[- {
- "id": 1,
- "order_date": "2020-07-14",
- "produce_date": "2020-07-16",
- "deliver_date": "2020-07-16",
- "status": "invoiced",
- "order_status_id": 4,
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": "",
- "internal_notes": "",
- "subtotal": "300.0",
- "discount": "10.0",
- "tax": "0.00",
- "shipping": "25.0",
- "total": "315.0",
- "order_number": "SO1",
- "payment_term_id": 1,
- "created_at": "2020-07-16T19:49:19.481Z",
- "updated_at": "2020-07-16T19:49:19.481Z",
- "invoiced_at": "2020-07-16T00:00:00.000Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-07-16T19:49:19.394Z",
- "updated_at": "2020-07-16T19:49:19.394Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "order_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "order_item_details": [
- {
- "id": 51,
- "order_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "order_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "order_item_details": [ ]
}
]
}
]Lists the quotes for a the customer.
| customer_id required | integer customer record ID |
[- {
- "id": 14,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "sent",
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "quote_number": "QO100",
- "created_at": "2020-09-12T18:25:54.054Z",
- "updated_at": "2020-09-12T18:25:54.054Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "salesperson": "",
- "quote_items": [
- {
- "id": 28,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "10.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T18:25:54.062Z",
- "updated_at": "2020-09-12T18:25:54.062Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "1165.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "purchase_conversion": "1.0",
- "property": "finished_good",
- "sku": "SK0001",
- "pull_strategy": "FEFO",
- "reorder_point": "0.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 28,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 28,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 29,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "5.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T18:25:54.066Z",
- "updated_at": "2020-09-12T18:25:54.066Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "0.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "purchase_conversion": "1.0",
- "property": "finished_good",
- "sku": "SK0002",
- "pull_strategy": "FIFO",
- "reorder_point": "0.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Creates a new quote for the customer.
| customer_id required | integer customer record ID |
| quote_number | string |
| quote_date required | string |
| expiration_date | string |
| status required | string Enum: "draft" "sent" "accepted" "rejected" "archived" |
| payment_term_id | integer or null |
| price_tier_name | string |
| price_tier_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| delivery_method_id | integer |
| instructions | string or null |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
required | Array of objects |
Array of objects (custom_line_items) |
{- "quote_number": "QO100",
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "payment_term_id": null,
- "status": "draft",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "quote_items_attributes": [
- {
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "quote_item_details_attributes": [
- {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 1
}
}, - {
- "kind": "note",
- "note": "Stack no more than 4 high."
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 14,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "draft",
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "quote_number": "QO100",
- "created_at": "2020-09-12T18:25:54.054Z",
- "updated_at": "2020-09-12T18:25:54.054Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "salesperson": "",
- "quote_items": [
- {
- "id": 28,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "10.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T18:25:54.062Z",
- "updated_at": "2020-09-12T18:25:54.062Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "1165.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "purchase_conversion": "1.0",
- "property": "finished_good",
- "sku": "SK0001",
- "pull_strategy": "FEFO",
- "reorder_point": "0.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 28,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 28,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 29,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "5.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T18:25:54.066Z",
- "updated_at": "2020-09-12T18:25:54.066Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "0.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "purchase_conversion": "1.0",
- "property": "finished_good",
- "sku": "SK0002",
- "pull_strategy": "FIFO",
- "reorder_point": "0.0",
- "lead_time": 0,
- "retired": false,
- "waste_percentage": "0.0",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Updates an existing quote
| quote_id required | integer quote record ID |
| customer_id required | integer customer record ID |
| quote_number | string |
| quote_date | string |
| expiration_date | string |
| status | string Enum: "draft" "sent" "accepted" "rejected" "archived" |
| payment_term_id | integer or null |
| price_tier_name | string |
| price_tier_id | integer |
| sales_channel_id | integer |
| salesperson_id | integer or null |
| delivery_method_id | integer |
| instructions | string or null |
| tax | number |
| shipping | number |
| discount | number |
| price_tier_ids | Array of integers |
Array of objects | |
Array of objects (custom_line_items-2) |
{- "quote_number": "QO100",
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "payment_term_id": null,
- "status": "draft",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": null,
- "discount": 0,
- "tax": 0,
- "shipping": 0,
- "quote_items_attributes": [
- {
- "id": 2,
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "_destroy": false,
- "quote_item_details_attributes": [
- {
- "id": 52,
- "note": "Stack no more than 3 high."
}, - {
- "id": 53,
- "_destroy": true
}, - {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 2
}
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "id": 1,
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100,
- "_destroy": false
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 6,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "draft",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "quote_number": "QO100",
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping"
}, - "quote_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Retrieves a quote record by ID
| quote_id required | integer Example: 1 ID for the quote record |
[- {
- "id": 1,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "accepted",
- "salesperson_id": null,
- "salesperson_name": null,
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "quote_number": "QO1",
- "payment_term_id": null,
- "created_at": "2020-09-11T13:57:46.842Z",
- "updated_at": "2020-09-12T16:22:26.851Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "delivery_method": {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "instructions": ""
}, - "salesperson": "",
- "quote_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:47.050Z",
- "updated_at": "2020-09-11T13:57:47.050Z",
- "quote_item_details": [ ]
}, - {
- "id": 12,
- "name": "Bulk chocolate",
- "inventory_id": 3,
- "category_name": "Ingredients",
- "count": "0.0",
- "cost": "0.0",
- "sku": null,
- "created_at": "2020-09-12T16:22:26.858Z",
- "updated_at": "2020-09-12T16:22:26.858Z",
- "quote_item_details": [ ]
}, - {
- "id": 13,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:22:26.863Z",
- "updated_at": "2020-09-12T16:22:26.863Z",
- "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Locates a quote by the quote_number
| quote_number | string non-empty Example: quote_number={
"quote_number": "QO1"
} The quote number in Wherefour to locate. All quotes with matching results will be returned. |
| page | integer Results page to view |
{- "quote_number": "QO1"
}[- {
- "id": 1,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "accepted",
- "salesperson_id": null,
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "300.0",
- "discount": "10.0",
- "tax": "0.00",
- "shipping": "25.0",
- "total": "315.0",
- "quote_number": "QO1",
- "payment_term_id": 1,
- "created_at": "2020-07-16T19:49:19.481Z",
- "updated_at": "2020-07-16T19:49:19.481Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-07-16T19:49:19.394Z",
- "updated_at": "2020-07-16T19:49:19.394Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North"
}, - "quote_items": [
- {
- "id": 1,
- "name": "Chocolate bar",
- "category_name": "Products",
- "count": "20.0",
- "cost": "2.5",
- "sku": "SK0001",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "count": "10.0",
- "cost": "25.0",
- "sku": "SK0002",
- "created_at": "2020-07-16T19:49:19.640Z",
- "updated_at": "2020-07-16T19:49:19.640Z",
- "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Returns a paginated list of all quotes.
| updated_at | string Oldest date/time for the records to return |
| page | integer Results page to view |
[- {
- "id": 6,
- "quote_date": "2020-09-04",
- "expiration_date": "2020-09-04",
- "status": "sent",
- "salesperson_id": null,
- "salesperson_name": "",
- "delivery_method_id": 1,
- "instructions": "",
- "subtotal": "100.0",
- "discount": "0.0",
- "tax": "0.0",
- "shipping": "0.0",
- "total": "0.0",
- "quote_number": "QO100",
- "payment_term_id": null,
- "created_at": "2020-09-12T16:13:45.549Z",
- "updated_at": "2020-09-12T16:13:45.549Z",
- "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "",
- "payment_terms": "Net 30",
- "salesperson": "",
- "delivery_method": "Route: Embarcadero North",
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "quote_items": [
- {
- "id": 10,
- "name": "Chocolate bar",
- "inventory_id": 4,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0001",
- "created_at": "2020-09-12T16:13:45.568Z",
- "updated_at": "2020-09-12T16:13:45.568Z",
- "inventory": {
- "id": 4,
- "name": "Chocolate bar",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [
- {
- "id": 51,
- "quote_item_id": 10,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "quote_item_id": 10,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 11,
- "name": "Chocolate bar, finished case",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "0.0",
- "cost": "0.0",
- "sku": "SK0002",
- "created_at": "2020-09-12T16:13:45.574Z",
- "updated_at": "2020-09-12T16:13:45.574Z",
- "inventory": {
- "id": 6,
- "name": "Chocolate bar, finished case",
- "category_name": "Products",
- "on_hand": "40.0",
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "quote_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 3,
- "organization_id": 1,
- "name": "Delivery fee",
- "count": "10.0",
- "unit_price": "10.0",
- "force_subtotal": "100.0",
- "subtotal": "100.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 1,
- "organization_id": 1,
- "name": "Delivery fee",
- "description": "Flat delivery charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Returns a paginated list of all shipments.
| page | integer Results page to view |
[- {
- "id": 1,
- "order_id": 2,
- "customer_id": 1,
- "user_name": "Tony Fiorello",
- "ship_date": "2020-09-12T16:48:00.000Z",
- "shipment_number": 1,
- "created_at": "2020-09-12T16:48:13.512Z",
- "updated_at": "2020-09-12T16:48:13.512Z",
- "shipment_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipment_items": [
- {
- "id": 1,
- "count": "10.0",
- "inventory_name": "Chocolate bar",
- "inventory_sku": "SK0001",
- "auto_ship": [
- {
- "adjustment_id": 25,
- "stock_id": 13,
- "lot_code": "SC-00000",
- "barcode": "CH-000001-18",
- "count": "10.0",
- "change": "-10.0",
- "reason": "shipment"
}
]
}, - {
- "id": 2,
- "count": "40.0",
- "inventory_name": "Chocolate bar, finished case",
- "inventory_sku": "SK0002",
- "auto_ship": [
- {
- "adjustment_id": 26,
- "stock_id": 14,
- "lot_code": "SCC-0000",
- "barcode": "CHCA-000001-18",
- "count": "40.0",
- "change": "-40.0",
- "reason": "shipment"
}
]
}
]
}
]Returns a paginated list of shipments for the specified order number.
| page | integer Results page to view |
| order_number required | string The order whose shipments to list |
{- "order_number": "SO1"
}[- {
- "id": 1,
- "order_id": 2,
- "customer_id": 1,
- "user_name": "Tony Fiorello",
- "ship_date": "2020-09-12T16:48:00.000Z",
- "shipment_number": 1,
- "created_at": "2020-09-12T16:48:13.512Z",
- "updated_at": "2020-09-12T16:48:13.512Z",
- "shipment_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipment_items": [
- {
- "id": 1,
- "count": "10.0",
- "inventory_name": "Chocolate bar",
- "inventory_sku": "SK0001",
- "auto_ship": [
- {
- "adjustment_id": 25,
- "stock_id": 13,
- "lot_code": "SC-00000",
- "barcode": "CH-000001-18",
- "count": "10.0",
- "change": "-10.0",
- "reason": "shipment"
}
]
}, - {
- "id": 2,
- "count": "40.0",
- "inventory_name": "Chocolate bar, finished case",
- "inventory_sku": "SK0002",
- "auto_ship": [
- {
- "adjustment_id": 26,
- "stock_id": 14,
- "lot_code": "SCC-0000",
- "barcode": "CHCA-000001-18",
- "count": "40.0",
- "change": "-40.0",
- "reason": "shipment"
}
]
}
]
}
]Returns a paginated list of purchase orders.
| updated_at | string Oldest date/time for the records returned. |
| page | integer Results page to view |
[- {
- "id": 1,
- "purchase_date": "2020-09-11",
- "purchase_number": "PO1",
- "status": "draft",
- "subtotal": "424.4875",
- "total": "424.49",
- "created_at": "2020-09-11T13:57:46.783Z",
- "updated_at": "2020-09-11T13:57:46.783Z",
- "vendor": {
- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Foods Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "kind": "distributor",
- "created_at": "2020-09-11T13:57:47.005Z",
- "updated_at": "2020-09-11T13:57:47.005Z",
- "billing_address": {
- "id": 39,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "95440",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 40,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}, - "delivery_method": {
- "id": 3,
- "name": "Pickup",
- "kind": "shipping"
}, - "payment_term": {
- "id": 3,
- "name": "Net 15",
- "net": 15
}, - "purchase_items": [
- {
- "id": 2,
- "name": "Whole milk",
- "category_name": "Ingredients",
- "count": "58.75",
- "cost": "2.97",
- "created_at": "2020-09-11T13:57:46.836Z",
- "updated_at": "2020-09-11T13:57:46.836Z",
- "inventory": {
- "id": 1,
- "name": "Whole milk",
- "category_name": "Ingredients",
- "on_hand": "1410.0",
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "property": "raw_material",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "purchase_item_details": [
- {
- "id": 51,
- "purchase_item_id": 2,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "purchase_item_id": 2,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 1,
- "name": "Case box",
- "category_name": "Packaging",
- "count": "1000.0",
- "cost": "0.25",
- "created_at": "2020-09-11T13:57:46.836Z",
- "updated_at": "2020-09-11T13:57:46.836Z",
- "inventory": {
- "id": 7,
- "name": "Case box",
- "category_name": "Packaging",
- "on_hand": "400.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "raw_material",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "purchase_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 91,
- "organization_id": 1,
- "name": "Freight",
- "count": "1.0",
- "unit_price": "25.0",
- "force_subtotal": null,
- "subtotal": "25.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 7,
- "organization_id": 1,
- "name": "Freight",
- "description": "Inbound freight charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Searches for a purchase order based on the purchase order number provided. Multiple matches may be returned.
| purchase_number | string PO number to search for |
| page | integer Results page to view |
[- {
- "id": 1,
- "purchase_date": "2024-02-21",
- "purchase_number": "PO1",
- "status": "draft",
- "deliver_by_date": "2024-02-21",
- "instructions": "",
- "subtotal": "424.4875",
- "discount": "",
- "tax": "",
- "shipping": "",
- "total": "455.71",
- "created_at": "2024-02-21T18:36:22.516Z",
- "updated_at": "2024-02-21T18:36:22.516Z",
- "bill_to_address": {
- "id": 4,
- "type": "OrganizationAddress",
- "descriptive_name": "Main Address",
- "line1": "1390 N. McDowell Blvd.",
- "line2": "Suite G133",
- "line3": null,
- "line4": null,
- "line5": null,
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "USA",
- "created_at": "2024-02-21T18:36:22.094Z",
- "updated_at": "2024-02-21T18:36:22.094Z"
}, - "deliver_to_address": {
- "id": 4,
- "type": "OrganizationAddress",
- "descriptive_name": "Main Address",
- "line1": "1390 N. McDowell Blvd.",
- "line2": "Suite G133",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "USA",
- "created_at": "2024-02-21T18:36:22.094Z",
- "updated_at": "2024-02-21T18:36:22.094Z"
}, - "vendor": {
- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Supply Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "distributor",
- "created_at": "2024-02-21T18:36:22.638Z",
- "updated_at": "2024-02-21T18:36:22.638Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": ""
}, - "delivery_method": {
- "id": 3,
- "name": "Pickup",
- "kind": "shipping",
- "instructions": "These are some delivery instructions"
}, - "payment_term": {
- "id": 3,
- "name": "Net 15",
- "net": 15
}, - "purchase_items": [
- {
- "id": 1,
- "name": "Case box",
- "category_name": "Packaging",
- "count": "1000.0",
- "cost": "0.25",
- "sku": "CSECSECSECSE",
- "created_at": "2024-02-21T18:36:22.513Z",
- "updated_at": "2024-02-21T18:36:22.513Z",
- "purchase_item_details": [
- {
- "id": 51,
- "purchase_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "purchase_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}, - {
- "id": 2,
- "name": "Raw material A",
- "category_name": "Ingredients",
- "count": "58.75",
- "cost": "2.97",
- "sku": "AAAAAAAAAAA",
- "created_at": "2024-02-21T18:36:22.513Z",
- "updated_at": "2024-02-21T18:36:22.513Z",
- "purchase_item_details": [ ]
}
], - "custom_line_items": [
- {
- "id": 91,
- "organization_id": 1,
- "name": "Freight",
- "count": "1.0",
- "unit_price": "25.0",
- "force_subtotal": null,
- "subtotal": "25.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 7,
- "organization_id": 1,
- "name": "Freight",
- "description": "Inbound freight charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Creates a purchase order for the vendor. New purchase orders are drafts unless status is sent. Each line's unit price comes from the vendor's price list for its quantity, unless override_unit_price is sent. The subtotal and total are always worked out by Wherefour.
| vendor_id required | integer vendor record ID |
| purchase_number | string Defaults to the next purchase order number |
| purchase_date | string Defaults to today |
| deliver_by_date | string |
| status | string Enum: "draft" "open" "complete" "canceled" "archived" Defaults to |
| payment_term_id | integer Defaults to the vendor's payment term |
| delivery_method_id | integer Defaults to the vendor's delivery method |
| bill_to_address_id | integer A facility address. Defaults to the organization's main address |
| deliver_to_address_id | integer A facility address. Defaults to the organization's main address |
| vendor_reference | string |
| instructions | string |
| tax | number |
| shipping | number |
| discount | number |
required | Array of objects |
Array of objects (custom_line_items) |
{- "deliver_by_date": "2026-11-05",
- "vendor_reference": "Q-5521",
- "instructions": "Deliver to dock 4.",
- "shipping": 25,
- "purchase_items_attributes": [
- {
- "sku": "BOX-12",
- "count": 10,
- "purchase_item_details_attributes": [
- {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 1
}
}, - {
- "kind": "note",
- "note": "Stack no more than 4 high."
}
]
}
]
}[- {
- "id": 120,
- "purchase_date": "2026-10-25",
- "purchase_number": "PO1042",
- "status": "draft",
- "deliver_by_date": "2026-11-05",
- "vendor_reference": "Q-5521",
- "instructions": "Deliver to dock 4.",
- "subtotal": "1005.0",
- "discount": null,
- "tax": null,
- "shipping": "25.0",
- "total": "1030.0",
- "created_at": "2026-10-25T18:02:44.318Z",
- "updated_at": "2026-10-25T18:02:44.318Z",
- "purchase_items": [
- {
- "id": 311,
- "name": "Cardboard case box",
- "category_name": "Packaging",
- "count": "10.0",
- "cost": "99.0",
- "sku": "BOX-12",
- "upc": null,
- "created_at": "2026-10-25T18:02:44.320Z",
- "updated_at": "2026-10-25T18:02:44.320Z",
- "purchase_item_details": [
- {
- "id": 51,
- "purchase_item_id": 311,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Per pallet charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "purchase_item_id": 311,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.323Z",
- "updated_at": "2026-10-25T18:02:44.323Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 91,
- "organization_id": 1,
- "name": "Freight",
- "count": "1.0",
- "unit_price": "25.0",
- "force_subtotal": null,
- "subtotal": "25.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 7,
- "organization_id": 1,
- "name": "Freight",
- "description": "Inbound freight charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Returns one of the vendor's purchase orders, with its lines and their custom line items and notes.
| vendor_id required | integer vendor record ID |
| purchase_id required | integer purchase order record ID |
[- {
- "id": 120,
- "purchase_date": "2026-10-25",
- "purchase_number": "PO1042",
- "status": "draft",
- "deliver_by_date": "2026-11-05",
- "vendor_reference": "Q-5521",
- "instructions": "Deliver to dock 4.",
- "subtotal": "1005.0",
- "discount": null,
- "tax": null,
- "shipping": "25.0",
- "total": "1030.0",
- "created_at": "2026-10-25T18:02:44.318Z",
- "updated_at": "2026-10-25T18:02:44.318Z",
- "purchase_items": [
- {
- "id": 311,
- "name": "Cardboard case box",
- "category_name": "Packaging",
- "count": "10.0",
- "cost": "99.0",
- "sku": "BOX-12",
- "upc": null,
- "created_at": "2026-10-25T18:02:44.320Z",
- "updated_at": "2026-10-25T18:02:44.320Z",
- "purchase_item_details": [
- {
- "id": 51,
- "purchase_item_id": 311,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Per pallet charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "purchase_item_id": 311,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.323Z",
- "updated_at": "2026-10-25T18:02:44.323Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 91,
- "organization_id": 1,
- "name": "Freight",
- "count": "1.0",
- "unit_price": "25.0",
- "force_subtotal": null,
- "subtotal": "25.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 7,
- "organization_id": 1,
- "name": "Freight",
- "description": "Inbound freight charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Updates one of the vendor's purchase orders. A purchase order can't be changed once stock has been received against it; the request returns 422. Each line's unit price comes from the vendor's price list for its quantity, unless override_unit_price is sent. The subtotal and total are always worked out by Wherefour.
| vendor_id required | integer vendor record ID |
| purchase_id required | integer purchase order record ID |
| purchase_number | string |
| purchase_date | string |
| deliver_by_date | string |
| status | string Enum: "draft" "open" "complete" "canceled" "archived" |
| payment_term_id | integer |
| delivery_method_id | integer |
| bill_to_address_id | integer A facility address |
| deliver_to_address_id | integer A facility address |
| vendor_reference | string |
| instructions | string |
| tax | number |
| shipping | number |
| discount | number |
Array of objects | |
Array of objects (custom_line_items-2) |
{- "status": "open",
- "purchase_items_attributes": [
- {
- "id": 311,
- "count": 12,
- "purchase_item_details_attributes": [
- {
- "id": 52,
- "note": "Stack no more than 3 high."
}, - {
- "id": 53,
- "_destroy": true
}, - {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 2
}
}
]
}, - {
- "inventory_id": 42,
- "count": 4,
- "override_unit_price": 18.5
}
]
}[- {
- "id": 120,
- "purchase_date": "2026-10-25",
- "purchase_number": "PO1042",
- "status": "draft",
- "deliver_by_date": "2026-11-05",
- "vendor_reference": "Q-5521",
- "instructions": "Deliver to dock 4.",
- "subtotal": "1005.0",
- "discount": null,
- "tax": null,
- "shipping": "25.0",
- "total": "1030.0",
- "created_at": "2026-10-25T18:02:44.318Z",
- "updated_at": "2026-10-25T18:02:44.318Z",
- "purchase_items": [
- {
- "id": 311,
- "name": "Cardboard case box",
- "category_name": "Packaging",
- "count": "10.0",
- "cost": "99.0",
- "sku": "BOX-12",
- "upc": null,
- "created_at": "2026-10-25T18:02:44.320Z",
- "updated_at": "2026-10-25T18:02:44.320Z",
- "purchase_item_details": [
- {
- "id": 51,
- "purchase_item_id": 311,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Per pallet charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "purchase_item_id": 311,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.323Z",
- "updated_at": "2026-10-25T18:02:44.323Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 91,
- "organization_id": 1,
- "name": "Freight",
- "count": "1.0",
- "unit_price": "25.0",
- "force_subtotal": null,
- "subtotal": "25.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 7,
- "organization_id": 1,
- "name": "Freight",
- "description": "Inbound freight charge",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
]
}
]Returns a paginated list of customers.
| updated_at | string Oldest date/time for the records to return |
| page | integer Results page to view |
[- {
- "id": 1,
- "accounting_id": "123456abc",
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "sales_channel": "Direct",
- "sales_channel_id": 1,
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "salesperson": "Greg Stevenson",
- "salesperson_id": 2,
- "delivery_method": "Route: Embarcadero North",
- "block_shipments": false,
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}
]Creates a new customer record.
| first_name | string |
| middle_name | string or null |
| last_name | string |
| display_name required | string |
string | |
| phone | string |
| mobile | string |
| fax | string |
| website | string |
| note | string |
| kind | string |
| custom_field_1 | string or null |
| custom_field_2 | string or null |
| custom_field_3 | string or null |
| custom_field_4 | string or null |
| business_license_number | string |
| block_shipments | boolean |
| sales_channel_id | number |
| salesperson_id | number |
object | |
object |
{- "first_name": "John",
- "middle_name": null,
- "last_name": "Smith",
- "display_name": "John Smith",
- "email": "test@example.com",
- "phone": "555-1212",
- "mobile": "555-2222",
- "fax": "555-3333",
- "note": "This is a customer note.",
- "custom_field_1": null,
- "custom_field_2": null,
- "custom_field_3": null,
- "custom_field_4": null,
- "business_license_number": "123",
- "block_shipments": false,
- "sales_channel_id": 1,
- "salesperson_id": 2,
- "billing_address_attributes": {
- "line1": "123 Main",
- "line2": null,
- "line3": null,
- "line4": null,
- "line5": null,
- "city": null,
- "country_subdivision_code": null,
- "postal_code": null,
- "country": null
}, - "shipping_address_attributes": {
- "line1": "555 Main",
- "line2": null,
- "line3": null,
- "line4": null,
- "line5": null,
- "city": null,
- "country_subdivision_code": null,
- "postal_code": null,
- "country": null
}
}[- {
- "id": 1,
- "accounting_id": "",
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "sales_channel": "Direct",
- "sales_channel_id": 1,
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "salesperson": "Greg Stevenson",
- "salesperson_id": 2,
- "delivery_method": "Route: Embarcadero North",
- "block_shipments": false,
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}
]Returns the customer record for the specified ID.
| customer_id required | integer customer record ID |
{- "id": 1,
- "accounting_id": "123456abc",
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "sales_channel": "Direct",
- "sales_channel_id": 1,
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "salesperson": "Greg Stevenson",
- "salesperson_id": 2,
- "delivery_method": "Route: Embarcadero North",
- "block_shipments": false,
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}Updates the customer record for the specified ID. Omitted fields are left as is. To clear a value include the field with null.
| customer_id required | integer customer record ID |
| first_name | string |
| middle_name | string or null |
| last_name | string |
| display_name | string |
string | |
| phone | string |
| mobile | string |
| fax | string |
| website | string |
| note | string |
| kind | string |
| custom_field_1 | string or null |
| custom_field_2 | string or null |
| custom_field_3 | string or null |
| custom_field_4 | string or null |
| business_license_number | string |
| block_shipments | boolean |
| sales_channel_id | number |
| salesperson_id | number |
object | |
object |
{- "first_name": "John",
- "middle_name": null,
- "last_name": "Smith",
- "display_name": "John A Smith",
- "email": "test@example.com",
- "phone": "555-1212",
- "mobile": "555-2222",
- "fax": "555-3333",
- "note": "This is a customer note.",
- "custom_field_1": null,
- "custom_field_2": null,
- "custom_field_3": null,
- "custom_field_4": null,
- "business_license_number": "123",
- "block_shipments": false,
- "sales_channel_id": 1,
- "salesperson_id": 2,
- "billing_address_attributes": {
- "line1": "123 Main",
- "line2": null,
- "line3": null,
- "line4": null,
- "line5": null,
- "city": null,
- "country_subdivision_code": null,
- "postal_code": null,
- "country": null
}, - "shipping_address_attributes": {
- "line1": "555 Main",
- "line2": null,
- "line3": null,
- "line4": null,
- "line5": null,
- "city": null,
- "country_subdivision_code": null,
- "postal_code": null,
- "country": null
}
}[- {
- "id": 1,
- "accounting_id": "123456abc",
- "first_name": "John",
- "last_name": "Smith",
- "display_name": "John A Smith",
- "email": "test@example.com",
- "phone": "555-1212",
- "mobile": "555-2222",
- "fax": "555-3333",
- "kind": "retailer",
- "sales_channel": "Direct",
- "sales_channel_id": 1,
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "salesperson": "Greg Stevenson",
- "salesperson_id": 2,
- "delivery_method": "Route: Embarcadero North",
- "block_shipments": false,
- "billing_address": {
- "id": 1,
- "line1": "123 Main",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "555 Main",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}
]Returns customer records with a match on the display name.
| page | integer Results page to view |
| display_name | string Part of the customer's display name |
| business_license_number | string Part of the customer's business license number |
{- "display_name": "A name"
}[- {
- "id": 1,
- "accounting_id": "123456abc",
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Market & Deli",
- "email": "buyer@embarcaderodeli.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "kind": "retailer",
- "sales_channel": "Direct",
- "sales_channel_id": 1,
- "created_at": "2020-09-11T13:57:46.742Z",
- "updated_at": "2020-09-11T13:57:46.742Z",
- "payment_terms": "Net 30",
- "salesperson": "Greg Stevenson",
- "salesperson_id": 2,
- "delivery_method": "Route: Embarcadero North",
- "block_shipments": false,
- "billing_address": {
- "id": 1,
- "line1": "1142 Main Street",
- "line2": "Suite 100",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "94455",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 2,
- "line1": "415 S. Pine Street",
- "line2": "Suite 210",
- "line3": "Apt. G",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}
}
]Returns a paginated list of vendors
| updated_at | string Oldest date/time for the records to return |
| page | integer Results page to view |
[- {
- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Foods Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "kind": "distributor",
- "created_at": "2020-09-11T13:57:47.005Z",
- "updated_at": "2020-09-11T13:57:47.005Z",
- "billing_address": {
- "id": 39,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "95440",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 40,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "payment_term": {
- "id": 3,
- "name": "Net 15",
- "net": 15
}, - "delivery_method": {
- "id": 3,
- "name": "Pickup",
- "kind": "shipping"
}
}
]Returns the vendor record for the specified ID.
| vendor_id required | integer vendor record ID |
{- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Foods Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "kind": "distributor",
- "created_at": "2020-09-11T13:57:47.005Z",
- "updated_at": "2020-09-11T13:57:47.005Z",
- "billing_address": {
- "id": 39,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "95440",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 40,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "payment_term": {
- "id": 3,
- "name": "Net 15",
- "net": 15
}, - "delivery_method": {
- "id": 3,
- "name": "Pickup",
- "kind": "shipping"
}
}Searches vendor records for matches on the display name provided. Multiple matches may be returned.
| page | integer Results page to view |
[- {
- "id": 1,
- "first_name": "Joe",
- "last_name": "Sample",
- "display_name": "Pacific Foods Co.",
- "email": "jsample@pacificfoods.com",
- "phone": "415-555-6758",
- "kind": "distributor",
- "created_at": "2020-09-11T13:57:47.005Z",
- "updated_at": "2020-09-11T13:57:47.005Z",
- "billing_address": {
- "id": 39,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "postal_code": "95440",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "shipping_address": {
- "id": 40,
- "line1": "144 S. Broadway",
- "city": "San Francisco",
- "country_subdivision_code": "CA",
- "country": "USA",
- "created_at": "2020-09-11T13:57:46.802Z",
- "updated_at": "2020-09-11T13:57:46.802Z"
}, - "payment_term": {
- "id": 3,
- "name": "Net 15",
- "net": 15
}, - "delivery_method": {
- "id": 3,
- "name": "Pickup",
- "kind": "shipping"
}
}
]Lists inventory adjustment activity for a date range. The IDs of records returned are for the adjustment record.
| start_date_time required | string Start date/time for the oldest adjustment record to return, based on the adjustment's effective_at timestamp |
| end_date_time required | string End date/time for the newest adjustment record to return, based on the adjustment's effective_at timestamp |
| activity_types | Array of arrays Restrict records to the provided adjustment activity types |
| category_ids | Array of arrays Restrict records to inventory and stock lot that belong to the provided category IDs |
| customer_ids | Array of arrays Restrict records to activity associated with specific customer IDs |
| inventory_ids | Array of arrays Restrict records to the provided inventory IDs |
| location_ids | Array of arrays Restrict records to the provided location IDs |
| statuses | Array of arrays Restrict records to stock lots with the provided statuses |
| user_ids | Array of arrays Restrict records to adjustments made by the provided used IDs |
| vendor_ids | Array of arrays Restrict records to activity associated with specific vendor IDs |
| lot_code | Array of arrays Restrict records to adjustments made only to stock lots with the provided lot code |
| barcode | Array of arrays Restrict records to adjustments made only to stock lots with the provided barcode |
| serial_number | Array of arrays Restrict records to adjustments made only to stock lots with the provided serial number |
| page | integer Results page to view |
| start_date_time required | string Start of the report, as a date and time |
| end_date_time required | string End of the report, as a date and time |
| activity_types | Array of strings Adjustment reasons to include, such as |
| category_ids | Array of integers |
| customer_ids | Array of integers |
| inventory_ids | Array of integers |
| location_ids | Array of integers |
| statuses | Array of strings Stock statuses |
| user_ids | Array of integers |
| lot_code | string |
| barcode | string |
| serial_number | string |
| page | integer |
{- "start_date_time": "2026-10-01T00:00:00-07:00",
- "end_date_time": "2026-10-31T23:59:59-07:00",
- "activity_types": [
- "purchase",
- "shipment"
], - "inventory_ids": [
- 42
]
}[- {
- "id": 31,
- "organization_id": 1,
- "organization_name": "ABC Product Co.",
- "created_at": "2024-02-24T22:25:04.623Z",
- "effective_at": "2024-02-24T22:25:05.840Z",
- "category_name": "Ingredients",
- "inventory": "Raw material A",
- "inventory_id": 1,
- "property": "raw_material",
- "sku": "AAAAAAAAAAA",
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "purchase_conversion": "1.0",
- "lot_code": "BCCD001",
- "barcode": "BCCD-000001",
- "serial_number": null,
- "active_stock_id": 30,
- "order_id": null,
- "order_number": null,
- "customer_id": null,
- "customer_display_name": null,
- "wo_number": null,
- "work_order_id": null,
- "vendor": "Pacific Supply Co.",
- "purchase_number": null,
- "purchase_id": null,
- "reason": "purchase",
- "change": "100.0",
- "purchase_change": "100.0",
- "cost_per_unit": "2.0",
- "cost_applied": "200.0",
- "old_location": "North Warehouse",
- "location": "North Warehouse",
- "transfer_request_number": null,
- "note": "buy lot 1",
- "system_note": null,
- "backdated": null,
- "superseded": null,
- "user": "Tony Fiorello",
- "global_identifier": "e3d1e35d-7f89-4468-80de-e90469185003",
- "custom_fields": [ ]
}
]Account settings used when creating records, such as payment terms and custom line definitions.
Lists the available delivery methods
| page | integer Results page to view |
[- {
- "id": 1,
- "name": "UPS Ground",
- "kind": "shipping",
- "driver_name": null,
- "driver_email": null,
- "instructions": null,
- "created_at": "2020-09-11T13:57:46.884Z",
- "updated_at": "2020-09-11T13:57:46.884Z"
}
]Lists the available payment terms
| page | integer Results page to view |
[- {
- "id": 1,
- "name": "Net 30",
- "net": 30,
- "created_at": "2026-06-22T13:57:46.884Z",
- "updated_at": "2026-06-22T13:57:46.884Z"
}
]Lists the custom line definitions for custom line items, sorted by name. Use a definition's id as custom_line_definition_id when adding custom line items to a document, or to a document's lines in *_item_details_attributes. Inactive definitions are included unless filtered out.
| page | integer Results page to view |
| per_page | integer Results per page, up to 100 |
| active | boolean Only active ( |
| document | string Enum: "credits" "invoices" "orders" "purchases" "quotes" "shipments" "standing_orders" Only definitions that can be used on this kind of document |
| customer_id | integer Only definitions open to all customers or limited to this customer |
| vendor_id | integer Only definitions open to all vendors or limited to this vendor |
| inventory_id | integer Only definitions open to all inventory items or limited to this item. These definitions can be added under a line for this item |
| updated_at | string Only definitions updated on or after this time |
[- {
- "id": 4,
- "name": "Freight",
- "description": "Inbound freight charge",
- "active": true,
- "line_item_calculation_type": "additive",
- "unit_of_measurement": "each",
- "credits_allowed": false,
- "credits_mode": "manual",
- "invoices_allowed": true,
- "invoices_mode": "manual",
- "orders_allowed": true,
- "orders_mode": "manual",
- "purchases_allowed": true,
- "purchases_mode": "manual",
- "quotes_allowed": false,
- "quotes_mode": "manual",
- "shipments_allowed": false,
- "shipments_mode": "manual",
- "standing_orders_allowed": false,
- "standing_orders_mode": "manual",
- "customers_allowed": false,
- "vendors_allowed": false,
- "inventories_allowed": false,
- "created_at": "2026-10-01T16:20:11.512Z",
- "updated_at": "2026-10-01T16:20:11.512Z"
}
]Lists credits for a customer
| customer_id required | integer customer record ID |
[- {
- "id": 1,
- "organization_id": 1,
- "user_id": 1,
- "customer_id": 1,
- "order_id": 1,
- "salesperson_id": 2,
- "credit_number": "CRED10",
- "credit_date": "2025-03-20T00:00:00.000Z",
- "credit_from_address_id": 4,
- "status": "active",
- "total": "99.98999999999999",
- "customer_message": null,
- "created_at": "2025-04-15T16:15:44.399Z",
- "updated_at": "2025-04-15T16:15:44.399Z",
- "user": {
- "id": 1,
- "organization_name": "ABC Product Co.",
- "email": "app@wherefour.com"
}, - "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Distribution",
- "email": "buyer@embarcado.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "sales_channel_id": null,
- "created_at": "2025-04-15T16:15:05.904Z",
- "updated_at": "2025-04-15T16:15:05.904Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "404-X0001",
- "payment_terms": "Net 30",
- "salesperson": null,
- "delivery_method": "Route: Embarcadero North",
- "delivery_method_id": 6,
- "block_shipments": false,
- "default_special_instructions": "Deliver to back dock 12"
}, - "order": {
- "id": 1,
- "order_date": "2025-04-13",
- "produce_date": "2025-04-15",
- "deliver_date": "2025-04-15",
- "ship_date": null,
- "origin": "wherefour",
- "po_number": "123456-11",
- "status": "open",
- "invoiced": true,
- "instructions": "",
- "subtotal": "365.5",
- "discount": "10.0",
- "tax": "",
- "shipping": "25.0",
- "total": "380.5",
- "order_number": "SO1",
- "created_at": "2025-04-15T16:15:06.114Z",
- "updated_at": "2025-04-15T16:15:06.114Z",
- "invoiced_at": "2025-04-15T00:00:00.000Z"
}, - "salesperson": {
- "id": 2,
- "name": "Greg Stevenson"
}, - "credit_from_address": {
- "id": 4,
- "type": "OrganizationAddress",
- "descriptive_name": "Main Address",
- "line1": "1390 N. McDowell Blvd.",
- "line2": "Suite G133",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "USA",
- "created_at": "2025-04-15T16:15:05.723Z",
- "updated_at": "2025-04-15T16:15:05.723Z"
}, - "credit_items": [
- {
- "id": 1,
- "name": "Case of finished good B",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "2.0",
- "cost": "24.0",
- "sku": "SK0002",
- "upc": "000000005",
- "created_at": "2025-04-15T18:27:24.598Z",
- "updated_at": "2025-04-15T18:27:24.598Z",
- "inventory": {
- "id": 6,
- "name": "Case of finished good B",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "credit_item_details": [
- {
- "id": 51,
- "credit_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "credit_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Creates a new credit for the customer.
| customer_id required | integer customer record ID |
| credit_number required | string |
| credit_date required | string A date such as 2026-10-22 is saved as midnight in the API user's time zone. A date and time with an offset, such as 2026-10-22T09:00:00-07:00, is saved as given. |
| status required | string |
| order_id | integer |
| invoice_id | integer |
| salesperson_id | integer |
| credit_from_address_id | integer Facility Address ID, not Facility ID or Customer Address ID |
| customer_message | string or null |
| internal_notes | string or null |
Array of objects | |
Array of objects (custom_line_items) |
{- "order_id": 1,
- "invoice_id": 1,
- "salesperson_id": 2,
- "credit_from_address_id": 1,
- "credit_number": "CRED100",
- "credit_date": "2020-09-04",
- "status": "active",
- "customer_message": null,
- "internal_notes": null,
- "credit_items_attributes": [
- {
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "credit_item_details_attributes": [
- {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 1
}
}, - {
- "kind": "note",
- "note": "Stack no more than 4 high."
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 1,
- "organization_id": 1,
- "user_id": 1,
- "customer_id": 1,
- "order_id": 1,
- "salesperson_id": 2,
- "credit_number": "CRED10",
- "credit_date": "2025-03-20T00:00:00.000Z",
- "credit_from_address_id": 4,
- "status": "active",
- "total": "99.98999999999999",
- "customer_message": null,
- "created_at": "2025-04-15T16:15:44.399Z",
- "updated_at": "2025-04-15T16:15:44.399Z",
- "user": {
- "id": 1,
- "organization_name": "ABC Product Co.",
- "email": "app@wherefour.com"
}, - "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Distribution",
- "email": "buyer@embarcado.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "sales_channel_id": null,
- "created_at": "2025-04-15T16:15:05.904Z",
- "updated_at": "2025-04-15T16:15:05.904Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "404-X0001",
- "payment_terms": "Net 30",
- "salesperson": null,
- "delivery_method": "Route: Embarcadero North",
- "delivery_method_id": 6,
- "block_shipments": false,
- "default_special_instructions": "Deliver to back dock 12"
}, - "order": {
- "id": 1,
- "order_date": "2025-04-13",
- "produce_date": "2025-04-15",
- "deliver_date": "2025-04-15",
- "ship_date": null,
- "origin": "wherefour",
- "po_number": "123456-11",
- "status": "open",
- "invoiced": true,
- "instructions": "",
- "subtotal": "365.5",
- "discount": "10.0",
- "tax": "",
- "shipping": "25.0",
- "total": "380.5",
- "order_number": "SO1",
- "created_at": "2025-04-15T16:15:06.114Z",
- "updated_at": "2025-04-15T16:15:06.114Z",
- "invoiced_at": "2025-04-15T00:00:00.000Z"
}, - "salesperson": {
- "id": 2,
- "name": "Greg Stevenson"
}, - "credit_from_address": {
- "id": 4,
- "type": "OrganizationAddress",
- "descriptive_name": "Main Address",
- "line1": "1390 N. McDowell Blvd.",
- "line2": "Suite G133",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "USA",
- "created_at": "2025-04-15T16:15:05.723Z",
- "updated_at": "2025-04-15T16:15:05.723Z"
}, - "credit_items": [
- {
- "id": 1,
- "name": "Case of finished good B",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "2.0",
- "cost": "24.0",
- "sku": "SK0002",
- "upc": "000000005",
- "created_at": "2025-04-15T18:27:24.598Z",
- "updated_at": "2025-04-15T18:27:24.598Z",
- "inventory": {
- "id": 6,
- "name": "Case of finished good B",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "credit_item_details": [
- {
- "id": 51,
- "credit_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "credit_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Updates an existing credit
| credit_id required | integer credit record ID |
| customer_id required | integer customer record ID |
| credit_number | string |
| credit_date | string A date such as 2026-10-22 is saved as midnight in the API user's time zone. A date and time with an offset, such as 2026-10-22T09:00:00-07:00, is saved as given. |
| status | string |
| order_id | integer |
| invoice_id | integer |
| salesperson_id | integer |
| credit_from_address_id | integer Facility Address ID, not Facility ID or Customer Address ID |
| customer_message | string or null |
| internal_notes | string or null |
Array of objects | |
Array of objects (custom_line_items-2) |
{- "order_id": 1,
- "invoice_id": 1,
- "salesperson_id": 2,
- "credit_from_address_id": 1,
- "credit_number": "CRED100",
- "credit_date": "2020-09-04",
- "status": "active",
- "customer_message": null,
- "internal_notes": null,
- "credit_items_attributes": [
- {
- "id": 2,
- "inventory_id": 4,
- "count": 10,
- "override_unit_price": 0,
- "_destroy": false,
- "credit_item_details_attributes": [
- {
- "id": 52,
- "note": "Stack no more than 3 high."
}, - {
- "id": 53,
- "_destroy": true
}, - {
- "kind": "custom_line_item",
- "custom_line_item_attributes": {
- "custom_line_definition_id": 6,
- "count": 2
}
}
]
}, - {
- "inventory_id": 6,
- "count": 5,
- "override_unit_price": 0
}
], - "custom_line_items_attributes": [
- {
- "id": 2,
- "custom_line_definition_id": 1,
- "count": 10,
- "force_subtotal": 100,
- "_destroy": false
}, - {
- "custom_line_definition_id": 2,
- "count": 10,
- "force_subtotal": 100
}
]
}[- {
- "id": 1,
- "organization_id": 1,
- "user_id": 1,
- "customer_id": 1,
- "order_id": 1,
- "salesperson_id": 2,
- "credit_number": "CRED10",
- "credit_date": "2025-03-20T00:00:00.000Z",
- "credit_from_address_id": 4,
- "status": "active",
- "total": "99.98999999999999",
- "customer_message": null,
- "created_at": "2025-04-15T16:15:44.399Z",
- "updated_at": "2025-04-15T16:15:44.399Z",
- "user": {
- "id": 1,
- "organization_name": "ABC Product Co.",
- "email": "app@wherefour.com"
}, - "customer": {
- "id": 1,
- "first_name": "",
- "last_name": "",
- "display_name": "Embarcadero Distribution",
- "email": "buyer@embarcado.com",
- "phone": "415-555-6687",
- "mobile": "",
- "fax": "",
- "note": "",
- "kind": "retailer",
- "sales_channel_id": null,
- "created_at": "2025-04-15T16:15:05.904Z",
- "updated_at": "2025-04-15T16:15:05.904Z",
- "custom_field_1": "",
- "custom_field_2": "",
- "custom_field_3": "",
- "custom_field_4": "",
- "business_license_number": "404-X0001",
- "payment_terms": "Net 30",
- "salesperson": null,
- "delivery_method": "Route: Embarcadero North",
- "delivery_method_id": 6,
- "block_shipments": false,
- "default_special_instructions": "Deliver to back dock 12"
}, - "order": {
- "id": 1,
- "order_date": "2025-04-13",
- "produce_date": "2025-04-15",
- "deliver_date": "2025-04-15",
- "ship_date": null,
- "origin": "wherefour",
- "po_number": "123456-11",
- "status": "open",
- "invoiced": true,
- "instructions": "",
- "subtotal": "365.5",
- "discount": "10.0",
- "tax": "",
- "shipping": "25.0",
- "total": "380.5",
- "order_number": "SO1",
- "created_at": "2025-04-15T16:15:06.114Z",
- "updated_at": "2025-04-15T16:15:06.114Z",
- "invoiced_at": "2025-04-15T00:00:00.000Z"
}, - "salesperson": {
- "id": 2,
- "name": "Greg Stevenson"
}, - "credit_from_address": {
- "id": 4,
- "type": "OrganizationAddress",
- "descriptive_name": "Main Address",
- "line1": "1390 N. McDowell Blvd.",
- "line2": "Suite G133",
- "line3": "",
- "line4": "",
- "line5": "",
- "city": "Petaluma",
- "country_subdivision_code": "CA",
- "postal_code": "94954",
- "country": "USA",
- "created_at": "2025-04-15T16:15:05.723Z",
- "updated_at": "2025-04-15T16:15:05.723Z"
}, - "credit_items": [
- {
- "id": 1,
- "name": "Case of finished good B",
- "inventory_id": 6,
- "category_name": "Products",
- "count": "2.0",
- "cost": "24.0",
- "sku": "SK0002",
- "upc": "000000005",
- "created_at": "2025-04-15T18:27:24.598Z",
- "updated_at": "2025-04-15T18:27:24.598Z",
- "inventory": {
- "id": 6,
- "name": "Case of finished good B",
- "category_name": "Products",
- "on_hand": "75.0",
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2020-09-11T13:57:46.825Z",
- "updated_at": "2020-09-11T13:57:46.825Z"
}, - "credit_item_details": [
- {
- "id": 51,
- "credit_item_id": 1,
- "kind": "custom_line_item",
- "position": 0,
- "note": null,
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": {
- "id": 88,
- "organization_id": 1,
- "name": "Pallet fee",
- "count": "1.0",
- "unit_price": "15.0",
- "force_subtotal": null,
- "subtotal": "15.0",
- "qualified": true,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_definition": {
- "id": 6,
- "organization_id": 1,
- "name": "Pallet fee",
- "description": "Charge per pallet",
- "created_at": "2026-09-02T15:11:40.101Z",
- "updated_at": "2026-09-02T15:11:40.101Z"
}
}
}, - {
- "id": 52,
- "credit_item_id": 1,
- "kind": "note",
- "position": 1,
- "note": "Stack no more than 4 high.",
- "internal_note": false,
- "created_at": "2026-10-25T18:02:44.322Z",
- "updated_at": "2026-10-25T18:02:44.322Z",
- "custom_line_item": null
}
]
}
], - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
]Lists formulas with optional name, type and search_type filters
| name | string Name of the formula to search for |
| type required | string Type of formula to search for, one of: (boms, kits, disassemblies) |
| search_type required | string Type of data to search for, one of: (formula, formula_version) |
{- "boms": [
- {
- "id": 1,
- "name": "Make work in progress A",
- "version_name": "Make work in progress A",
- "organization_id": 1,
- "bom_id": 1,
- "default_version": true,
- "version_number": 0,
- "status": "active",
- "instructions": "Mix ingredients and make sure to monitor temperature while tempering",
- "production_lead_time": 0,
- "quantity_based": true,
- "standard_cost": "629.0",
- "created_at": "2025-09-03T12:41:17.364Z",
- "updated_at": "2025-09-04T14:36:16.319Z",
- "bom_pull_items": [
- {
- "id": 76,
- "bom_id": 1,
- "count": "183.0",
- "standard_unit_cost": "1.8",
- "created_at": "2025-09-04T15:02:26.518Z",
- "updated_at": "2025-09-04T15:02:26.518Z",
- "inventory": {
- "id": 5,
- "name": "Raw material B",
- "category_name": "Ingredients",
- "on_hand": "1012.0",
- "unit_of_use": "gram",
- "unit_of_purchase": "gram",
- "property": "raw_material",
- "sku": "BBBBBBBBBBB",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-04T18:36:12.384Z"
}
}
], - "custom_line_items": [
- {
- "id": 17,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:28:16.369Z",
- "updated_at": "2025-09-05T22:28:16.369Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}
], - "bom_result_item": {
- "id": 1,
- "created_at": "2025-09-03T12:41:17.343Z",
- "updated_at": "2025-09-03T12:41:17.343Z",
- "inventory": {
- "id": 3,
- "name": "Work in progress A",
- "category_name": "Ingredients",
- "on_hand": "0.0",
- "unit_of_use": "pound",
- "unit_of_purchase": "pound",
- "property": "work_in_progress",
- "sku": "WIPAWIPAWIPA",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}
}
], - "disassemblies": [
- {
- "id": 1,
- "name": "Disassemble Product E",
- "version_name": "Disassemble Product E",
- "organization_id": 1,
- "status": "active",
- "instructions": "",
- "production_lead_time": 0,
- "quantity_based": true,
- "standard_cost": 129.7,
- "created_at": "2025-09-03T12:41:18.275Z",
- "updated_at": "2025-09-05T22:30:17.330Z",
- "disassembly_source_items": [
- {
- "id": 2,
- "disassembly_id": 1,
- "count": 12,
- "standard_unit_cost": 0,
- "created_at": "2025-09-04T15:22:28.979Z",
- "updated_at": "2025-09-04T15:36:00.193Z",
- "inventory": {
- "id": 6,
- "name": "Case of finished good B",
- "category_name": "Products",
- "on_hand": 40,
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}, - {
- "id": 3,
- "disassembly_id": 1,
- "count": 13,
- "standard_unit_cost": 1.9,
- "created_at": "2025-09-04T15:36:00.199Z",
- "updated_at": "2025-09-05T22:30:17.334Z",
- "inventory": {
- "id": 1,
- "name": "Raw material A",
- "category_name": "Ingredients",
- "on_hand": 1309.55,
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "property": "raw_material",
- "sku": "AAAAAAAAAAA",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}
], - "disassembly_result_items": [
- {
- "id": 1,
- "disassembly_id": 1,
- "count": 1,
- "percentage_cost": 50,
- "prorated_cost": 500,
- "expiration_date_days": null,
- "created_at": "2025-09-03T12:41:18.216Z",
- "updated_at": "2025-09-03T12:41:18.216Z",
- "inventory": {
- "id": 43,
- "name": "Part A",
- "category_name": "Parts",
- "on_hand": 0,
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "raw_material",
- "sku": null,
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}, - "custom_line_items": [
- {
- "id": 20,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.317Z",
- "updated_at": "2025-09-05T22:30:17.317Z"
}
]
}, - {
- "id": 2,
- "disassembly_id": 1,
- "count": 1,
- "percentage_cost": 50,
- "prorated_cost": 500,
- "expiration_date_days": null,
- "created_at": "2025-09-03T12:41:18.216Z",
- "updated_at": "2025-09-03T12:41:18.216Z",
- "inventory": {
- "id": 44,
- "name": "Part B",
- "category_name": "Parts",
- "on_hand": 0,
- "unit_of_use": "pound",
- "unit_of_purchase": "each",
- "property": "raw_material",
- "sku": null,
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}, - "custom_line_items": [
- {
- "id": 21,
- "organization_id": 1,
- "name": "Production Labor",
- "count": 3,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.323Z",
- "updated_at": "2025-09-05T22:30:17.323Z"
}
]
}
], - "custom_line_items": [
- {
- "id": 19,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 1,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.309Z",
- "updated_at": "2025-09-05T22:30:17.309Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}, - {
- "id": 20,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.317Z",
- "updated_at": "2025-09-05T22:30:17.317Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}, - {
- "id": 21,
- "organization_id": 1,
- "name": "Production Labor",
- "count": 3,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.323Z",
- "updated_at": "2025-09-05T22:30:17.323Z",
- "custom_line_definition": {
- "id": 2,
- "organization_id": 1,
- "name": "Production Labor",
- "description": "Labor used in production process",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}
]
}
], - "kits": [
- {
- "id": 1,
- "name": "Kit product formula",
- "organization_id": 1,
- "yield_expected": 1,
- "status": "active",
- "instructions": null,
- "is_min_batch": true,
- "standard_cost": 2.89,
- "created_at": "2025-04-15T18:26:45.146Z",
- "updated_at": "2025-04-15T18:26:45.146Z",
- "kit_items": [
- {
- "id": 1,
- "kit_id": 1,
- "count": 6,
- "created_at": "2025-04-15T18:26:45.135Z",
- "updated_at": "2025-04-15T18:26:45.135Z",
- "inventory": {
- "id": 4,
- "name": "Finished good B",
- "category_name": "Products",
- "on_hand": 75,
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2025-04-15T18:26:45.094Z",
- "updated_at": "2025-04-15T18:26:45.094Z"
}
}
], - "product": {
- "id": 12,
- "display_formula_name": "KIT: Kit product formula",
- "product_name": null,
- "sku": null,
- "created_at": "2025-04-15T18:26:45.464Z",
- "updated_at": "2025-04-15T18:26:45.464Z",
- "inventory": {
- "id": 34,
- "name": "Kitted product",
- "category_name": "Products",
- "on_hand": 3,
- "unit_of_use": "box",
- "unit_of_purchase": "box",
- "property": "finished_good",
- "sku": "BBOC123",
- "created_at": "2025-04-15T18:26:45.094Z",
- "updated_at": "2025-04-15T18:26:45.094Z"
}, - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
}
]
}Searches formulas or formula versions for matches on name type and search_type filters
| name required | string Name of the formula to search for |
| type required | string Type of formula to search for, one of: (boms, kits, disassemblies) |
| search_type required | string Type of data to search for, one of: (formula, formula_version) |
{- "boms": [
- {
- "id": 1,
- "name": "Make work in progress A",
- "version_name": "Make work in progress A",
- "organization_id": 1,
- "bom_id": 1,
- "default_version": true,
- "version_number": 0,
- "status": "active",
- "instructions": "Mix ingredients and make sure to monitor temperature while tempering",
- "production_lead_time": 0,
- "quantity_based": true,
- "standard_cost": "629.0",
- "created_at": "2025-09-03T12:41:17.364Z",
- "updated_at": "2025-09-04T14:36:16.319Z",
- "bom_pull_items": [
- {
- "id": 76,
- "bom_id": 1,
- "count": "183.0",
- "standard_unit_cost": "1.8",
- "created_at": "2025-09-04T15:02:26.518Z",
- "updated_at": "2025-09-04T15:02:26.518Z",
- "inventory": {
- "id": 5,
- "name": "Raw material B",
- "category_name": "Ingredients",
- "on_hand": "1012.0",
- "unit_of_use": "gram",
- "unit_of_purchase": "gram",
- "property": "raw_material",
- "sku": "BBBBBBBBBBB",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-04T18:36:12.384Z"
}
}
], - "custom_line_items": [
- {
- "id": 17,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:28:16.369Z",
- "updated_at": "2025-09-05T22:28:16.369Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}
], - "bom_result_item": {
- "id": 1,
- "created_at": "2025-09-03T12:41:17.343Z",
- "updated_at": "2025-09-03T12:41:17.343Z",
- "inventory": {
- "id": 3,
- "name": "Work in progress A",
- "category_name": "Ingredients",
- "on_hand": "0.0",
- "unit_of_use": "pound",
- "unit_of_purchase": "pound",
- "property": "work_in_progress",
- "sku": "WIPAWIPAWIPA",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}
}
], - "disassemblies": [
- {
- "id": 1,
- "name": "Disassemble Product E",
- "version_name": "Disassemble Product E",
- "organization_id": 1,
- "status": "active",
- "instructions": "",
- "production_lead_time": 0,
- "quantity_based": true,
- "standard_cost": 129.7,
- "created_at": "2025-09-03T12:41:18.275Z",
- "updated_at": "2025-09-05T22:30:17.330Z",
- "disassembly_source_items": [
- {
- "id": 2,
- "disassembly_id": 1,
- "count": 12,
- "standard_unit_cost": 0,
- "created_at": "2025-09-04T15:22:28.979Z",
- "updated_at": "2025-09-04T15:36:00.193Z",
- "inventory": {
- "id": 6,
- "name": "Case of finished good B",
- "category_name": "Products",
- "on_hand": 40,
- "unit_of_use": "case",
- "unit_of_purchase": "case",
- "property": "finished_good",
- "sku": "SK0002",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}, - {
- "id": 3,
- "disassembly_id": 1,
- "count": 13,
- "standard_unit_cost": 1.9,
- "created_at": "2025-09-04T15:36:00.199Z",
- "updated_at": "2025-09-05T22:30:17.334Z",
- "inventory": {
- "id": 1,
- "name": "Raw material A",
- "category_name": "Ingredients",
- "on_hand": 1309.55,
- "unit_of_use": "gallon",
- "unit_of_purchase": "gallon",
- "property": "raw_material",
- "sku": "AAAAAAAAAAA",
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}
}
], - "disassembly_result_items": [
- {
- "id": 1,
- "disassembly_id": 1,
- "count": 1,
- "percentage_cost": 50,
- "prorated_cost": 500,
- "expiration_date_days": null,
- "created_at": "2025-09-03T12:41:18.216Z",
- "updated_at": "2025-09-03T12:41:18.216Z",
- "inventory": {
- "id": 43,
- "name": "Part A",
- "category_name": "Parts",
- "on_hand": 0,
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "raw_material",
- "sku": null,
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}, - "custom_line_items": [
- {
- "id": 20,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.317Z",
- "updated_at": "2025-09-05T22:30:17.317Z"
}
]
}, - {
- "id": 2,
- "disassembly_id": 1,
- "count": 1,
- "percentage_cost": 50,
- "prorated_cost": 500,
- "expiration_date_days": null,
- "created_at": "2025-09-03T12:41:18.216Z",
- "updated_at": "2025-09-03T12:41:18.216Z",
- "inventory": {
- "id": 44,
- "name": "Part B",
- "category_name": "Parts",
- "on_hand": 0,
- "unit_of_use": "pound",
- "unit_of_purchase": "each",
- "property": "raw_material",
- "sku": null,
- "created_at": "2025-09-03T12:41:18.410Z",
- "updated_at": "2025-09-03T12:41:18.410Z"
}, - "custom_line_items": [
- {
- "id": 21,
- "organization_id": 1,
- "name": "Production Labor",
- "count": 3,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.323Z",
- "updated_at": "2025-09-05T22:30:17.323Z"
}
]
}
], - "custom_line_items": [
- {
- "id": 19,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 1,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.309Z",
- "updated_at": "2025-09-05T22:30:17.309Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}, - {
- "id": 20,
- "organization_id": 1,
- "name": "Extra production material",
- "count": 2,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.317Z",
- "updated_at": "2025-09-05T22:30:17.317Z",
- "custom_line_definition": {
- "id": 3,
- "organization_id": 1,
- "name": "Extra production material",
- "description": "Additional material used in production",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}, - {
- "id": 21,
- "organization_id": 1,
- "name": "Production Labor",
- "count": 3,
- "unit_price": 10,
- "qualified": true,
- "created_at": "2025-09-05T22:30:17.323Z",
- "updated_at": "2025-09-05T22:30:17.323Z",
- "custom_line_definition": {
- "id": 2,
- "organization_id": 1,
- "name": "Production Labor",
- "description": "Labor used in production process",
- "created_at": "2025-09-03T12:41:17.944Z",
- "updated_at": "2025-09-03T12:41:17.944Z"
}
}
]
}
], - "kits": [
- {
- "id": 1,
- "name": "Kit product formula",
- "organization_id": 1,
- "yield_expected": 1,
- "status": "active",
- "instructions": null,
- "is_min_batch": true,
- "standard_cost": 2.89,
- "created_at": "2025-04-15T18:26:45.146Z",
- "updated_at": "2025-04-15T18:26:45.146Z",
- "kit_items": [
- {
- "id": 1,
- "kit_id": 1,
- "count": 6,
- "created_at": "2025-04-15T18:26:45.135Z",
- "updated_at": "2025-04-15T18:26:45.135Z",
- "inventory": {
- "id": 4,
- "name": "Finished good B",
- "category_name": "Products",
- "on_hand": 75,
- "unit_of_use": "each",
- "unit_of_purchase": "each",
- "property": "finished_good",
- "sku": "SK0001",
- "created_at": "2025-04-15T18:26:45.094Z",
- "updated_at": "2025-04-15T18:26:45.094Z"
}
}
], - "product": {
- "id": 12,
- "display_formula_name": "KIT: Kit product formula",
- "product_name": null,
- "sku": null,
- "created_at": "2025-04-15T18:26:45.464Z",
- "updated_at": "2025-04-15T18:26:45.464Z",
- "inventory": {
- "id": 34,
- "name": "Kitted product",
- "category_name": "Products",
- "on_hand": 3,
- "unit_of_use": "box",
- "unit_of_purchase": "box",
- "property": "finished_good",
- "sku": "BBOC123",
- "created_at": "2025-04-15T18:26:45.094Z",
- "updated_at": "2025-04-15T18:26:45.094Z"
}, - "custom_line_items": [
- {
- "id": 2,
- "organization_id": 1,
- "name": "Tiered CLI",
- "count": 2,
- "unit_price": 22.22,
- "qualified": false,
- "created_at": "2025-04-15T18:27:24.603Z",
- "updated_at": "2025-04-15T18:27:24.603Z",
- "custom_line_definition": {
- "id": 4,
- "organization_id": 1,
- "name": "Tiered CLI",
- "description": "Tiered CLI",
- "created_at": "2025-04-15T18:26:45.003Z",
- "updated_at": "2025-04-15T18:26:45.003Z"
}
}
]
}
}
]
}