Wherefour API (1.0.18)

Download OpenAPI specification:Download

API documentation for the Wherefour ERP/traceability platform. More information at: wherefour.com.

Categories

List categories

Returns a list of inventory categories, ordered by name.

Authorizations:
BasicAuth
query Parameters
page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
name
string

Response samples

Content type
application/json
[
]

Inventory

List Inventory Items

Returns a paginated list of all inventory items.

Authorizations:
BasicAuth
query Parameters
updated_at
string

Oldest date/time for the records to return

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
name
string non-empty
category_name
string non-empty
on_hand
number
unit_of_use
string non-empty
unit_of_purchase
string non-empty
unit_of_order
string non-empty
unit_of_invoice
string non-empty
unit_of_pick_and_ship
string non-empty
unit_of_weight
string non-empty
unit_of_dimension
string non-empty
purchase_conversion
number
property
string non-empty
sku
string non-empty
pull_strategy
string non-empty
reorder_point
number
lead_time
number
retired
boolean
waste_percentage
number
quantity_not_tracked
boolean
Array of objects >= 0 items unique
weight
number
height
number
width
number
length
number
created_at
string non-empty
updated_at
string non-empty
Array of objects >= 0 items unique

Response samples

Content type
application/json
{
}

Create inventory item

Creates a new inventory item with the provided parameters.

Authorizations:
BasicAuth
Request Body schema: application/json
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
unit_of_dimension
string
purchase_conversion
number
property
string
Enum: "raw_material" "overhead" "work_in_progress" "finished_good"
sku
string
upc
string
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
height
number
width
number
length
number

Responses

Response Schema:
id
number
name
string non-empty
category_name
string non-empty
on_hand
number
unit_of_use
string non-empty
unit_of_purchase
string non-empty
unit_of_order
string non-empty
unit_of_invoice
string non-empty
unit_of_pick_and_ship
string non-empty
unit_of_weight
string non-empty
unit_of_dimension
string non-empty
purchase_conversion
number
property
string non-empty
sku
string non-empty
pull_strategy
string non-empty
reorder_point
number
lead_time
number
retired
boolean
waste_percentage
number
quantity_not_tracked
boolean
Array of objects >= 0 items unique
weight
number
height
number
width
number
length
number
created_at
string non-empty
updated_at
string non-empty
Array of objects >= 0 items unique

Request samples

Content type
application/json
{
}

Response samples

Content type
{
}

Add stock lot

Adds a new stock lot to the specified inventory item.

Authorizations:
BasicAuth
path Parameters
inventory_id
required
integer

inventory item record ID

Request Body schema: application/json
delivery_method_id
required
number
location_id
number
vendor_id
number
vendor_reference
string
count
required
number
lot_code
required
string

required if automatic sequencing is not enabled or generate_lot_code is false

barcode
string
serial_number
string
expiration_date
string

must be in the preferred date format of the API user

received_date
required
string

must be in the preferred date time format of the API user

generate_lot_code
boolean
generate_barcode
boolean
generate_serial_number
string
cost
required
number
cost_entered_is_total_code
boolean

if cost_entered_is_total_code is false, the cost will be treated as a per unit cost

stock_description
string
vendor_item_number
string
status
string
Enum: "active" "inactive" "on_hold" "quarantined"

Responses

Response Schema: application/json
id
number
user_id
number
inventory_id
number
location_id
number
lot_code
string
status
string
barcode
string
details
string
note
string
count
number
cost
number
vendor_id
number
expiration_date
string
created_at
string
updated_at
string
base_count
number
rate
number
purchase_id
number
global_identifier
string
organization_id
number
expiration_notified_at
string
weight
number
height
number
width
number
length
number
serial_number
string
generate_barcode
boolean
generate_lot_code
boolean
generate_serial_number
boolean
Array of objects >= 0 items unique

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Get last stock lot change

Gets the last stock lot change for the specified inventory item.

Authorizations:
BasicAuth

Responses

Response Schema: application/json
object

Response samples

Content type
application/json
{
}

Search for inventory item

Returns inventory items that match the given name or SKU. Multiple matches may be returned.

Authorizations:
BasicAuth
query Parameters
page
integer

Results page to view

Request Body schema: application/json

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.

object

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
name
string non-empty
category_name
string non-empty
on_hand
number
unit_of_use
string non-empty
unit_of_purchase
string non-empty
unit_of_order
string non-empty
unit_of_invoice
string non-empty
unit_of_pick_and_ship
string non-empty
unit_of_weight
string non-empty
unit_of_dimension
string non-empty
purchase_conversion
number
property
string non-empty
sku
string non-empty
pull_strategy
string non-empty
reorder_point
number
lead_time
number
retired
boolean
waste_percentage
number
quantity_not_tracked
boolean
Array of objects >= 0 items unique
weight
number
height
number
width
number
length
number
created_at
string non-empty
updated_at
string non-empty
Array of objects >= 0 items unique

Request samples

Content type
application/json
Example
{
}

Response samples

Content type
application/json
{
}

Invoices

List customer invoices

Lists invoices for a customer

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Responses

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Create Invoice

Creates a new invoice for the customer.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Request Body schema: application/json
object

Responses

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Update invoice

Updates an existing invoice

Authorizations:
BasicAuth
path Parameters
invoice_id
required
integer

invoice record ID

customer_id
required
integer

customer record ID

Responses

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

List Invoices

Returns a paginated list of all invoices.

Authorizations:
BasicAuth
query Parameters
updated_at
string

Oldest date/time for the records returned

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Get Invoice

Retrieves a invoice record by ID

Authorizations:
BasicAuth
path Parameters
invoice_id
required
integer
Example: 1

ID for the invoice record

Responses

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Search for invoice

Locates a invoice by the invoice_number

Authorizations:
BasicAuth
query Parameters
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

Request Body schema: application/json
object

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
invoice_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
invoice_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Orders

List orders for a customer

Returns all the orders for the customer ID provided.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

query Parameters
updated_at
string

Oldest date/time for the records to return

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Create Order

Creates a new order for the customer.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Request Body schema: application/json
object

Responses

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Update Order

Updates an existing order

Authorizations:
BasicAuth
path Parameters
order_id
required
integer

order record ID

customer_id
required
integer

customer record ID

Responses

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Get Last Shipment

Returns the most recent shipment information for the order ID provided.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer
Example: 1

customer record ID

order_id
required
integer

order record ID

Responses

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

List shipments for order

Returns the most recent shipment information for the order ID provided.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer
Example: 1

customer record ID

order_id
required
integer
Example: 2

order record ID

query Parameters
page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Auto Pick and Ship

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.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Request Body schema:
delivery_method
required
string
location_name
string

Name of the Wherefour location to pull stock from. If not provided, auto ship will pull available stock lots from any location. Name lookup will use the closest found match for the name provided or "null" for no match.

tracking_number
string

Tracking number to record for the shipment.

ship_date
string

Responses

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
{
}

Response samples

Content type
application/json
{
}

List Orders

Returns a paginated list of all orders.

Authorizations:
BasicAuth
query Parameters
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

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Get Order

Retrieves an order record by ID

Authorizations:
BasicAuth
path Parameters
order_id
required
integer
Example: 1

ID for the order record

Responses

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Search for Order

Locates an order by the order_number

Authorizations:
BasicAuth
query Parameters
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

Request Body schema: application/json
object

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
order_date
string
produce_date
string
deliver_date
string
po_number
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
order_number
string
created_at
string
updated_at
string
invoiced_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Quotes

List quotes for a customer

Lists the quotes for a the customer.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Request Body schema: application/json
object

Responses

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Create Quote

Creates a new quote for the customer.

Authorizations:
BasicAuth
path Parameters
customer_id
required
integer

customer record ID

Request Body schema: application/json
object

Responses

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Update Quote

Updates an existing quote

Authorizations:
BasicAuth
path Parameters
quote_id
required
integer

quote record ID

customer_id
required
integer

customer record ID

Responses

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Get Quote

Retrieves a quote record by ID

Authorizations:
BasicAuth
path Parameters
quote_id
required
integer
Example: 1

ID for the quote record

Responses

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Search for quote

Locates a quote by the quote_number

Authorizations:
BasicAuth
query Parameters
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

Request Body schema: application/json
object

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

List Quotes

Returns a paginated list of all quotes.

Authorizations:
BasicAuth
query Parameters
updated_at
string

Oldest date/time for the records to return

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
integer
quote_date
string
expiration_date
string
status
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
quote_number
string
created_at
string
updated_at
string
object
object
salesperson
string
payment_term
string

Response samples

Content type
application/json
{
}

Shipments

List shipments

Returns a paginated list of all shipments.

Authorizations:
BasicAuth
query Parameters
page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
order_id
number
customer_id
number
user_name
string
ship_date
string
shipment_number
number
tracking_number
string
note
string
created_at
string
updated_at
string
object
Array of objects

Response samples

Content type
application/json
{
}

Search for shipment

Returns a paginated list of shipments for the specified order number.

Authorizations:
BasicAuth
query Parameters
page
integer

Results page to view

Request Body schema: application/json
object

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
order_id
number
customer_id
number
user_name
string
ship_date
string
shipment_number
number
tracking_number
string
note
string
created_at
string
updated_at
string
object
Array of objects

Request samples

Content type
application/json
{
}

Response samples

Content type
application/json
{
}

Purchases

List purchases

Returns a paginated list of purchase orders.

Authorizations:
BasicAuth
query Parameters
updated_at
string

Oldest date/time for the records returned.

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
purchase_date
string
purchase_number
string
status
string
deliver_by_date
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
created_at
string
updated_at
string
object
object
object
object
object
Array of objects

Response samples

Content type
application/json
{
}

Search Purchases

Searches for a purchase order based on the purchase order number provided. Multiple matches may be returned.

Authorizations:
BasicAuth
query Parameters
purchase_number
string

PO number to search for

page
integer

Results page to view

Responses

Response Headers
Total
integer

Total count of results

Per-Page
integer

Number of results per page

Link
string

URLs for the next or previous pages of the results

Response Schema: application/json
id
number
purchase_date
string
purchase_number
string
status
string
deliver_by_date
string
instructions
string
subtotal
string
discount
string
tax
string
shipping
string
total
string
created_at
string
updated_at
string