Docs

Docs / Data Feed / In-house inventory

For Data Feed stores
Endpoint · Change some fields

PATCH/items/{upc}

Change some fields of an existing row and keep the rest. PATCH never creates a row.

Needs In-house inventory: Read and writeBase URL https://backend.fflmonkey.com/api/v1/inventoryCounts 1 toward 120 a minute

Fields

Needs write access. Send any of the PUT fields, with the same rules; the rest are kept. Send null to clear cost_price, sku or notes; stock and price cannot be null. An empty body is refused.

FieldTypeRule
stockoptionalintegerWhole number, 0 to 1,000,000.
priceoptionalnumber or string0.01 to 9,999,999.99, at most two decimals.
cost_priceoptionalnumber, string or null0 to 9,999,999.99, at most two decimals, or null. For your records only.
skuoptionalstring or nullUp to 64 characters, or null.
notesoptionalstring or nullUp to 5,000 characters, or null.
  • PATCH never creates a row: 404 item_not_found if it does not exist.
  • If the row's price is 0.00, include a price unless the change leaves stock at 0.

Why the price must be at least 0.01

An in-house row is published at your price with no markup, and it wins ties. A row priced 0.00 with stock would put the product in your store at $0.00.

So no write through this API may leave a row with stock above 0 and a price under 0.01. The In-house inventory screen in wp-admin does accept 0.00, so you may meet a row priced 0.00. A PATCH or an adjustment that would leave it with stock is refused with 422 validation_failed on price until you give it a price. Taking its stock to 0 is always allowed.

Returns

  • 200Updated: the whole row, in data.
  • 404item_not_found: create the row with PUT or batch first.
  • 422A field broke a rule, the body was empty, or the row is priced 0.00.

This endpoint can also answer 401 invalid_api_key, 403 license_not_active, 403 product_not_included and 429 rate_limited.

Example

FFL Monkey Data Feed API, version 1. Questions: Support in your FFL Monkey account, or [email protected].