The units available for tracking quantity: weight, length, volume and count.
Sortly API
The Sortly API lets you work with your inventory from your own systems: add and update items, keep stock levels in sync, and track what goes out on a job.
Available on the Sortly Enterprise Plan. All requests go to https://api.sortly.co over HTTPS and return JSON. Email dev-support@sortly.com with questions or issues.
New here? Start with Getting Started, then read Items and Folders so the vocabulary in the endpoint reference makes sense. Once you know what you're building, jump to the matching Use Case Guide.
Goal: keep Sortly jobs in step with the work orders in your external system, from the moment one is raised to the moment it closes, so field staff work against accurate inventory and nobody keys the same movement in twice.
A job is a work order. Creating one also creates a folder to hold the items assigned to it. Jobs move through three statuses: not_started, in_progress, completed.
Each subsection below maps to one event in your system. Your system owns the job lifecycle and drives each of these calls; where you need to see the state on the Sortly side, read it with GET /api/v1/jobs on whatever schedule suits you.
Goal: keep Sortly purchase orders in step with the accounting or ordering system you buy through, so both sides agree on what was ordered, what it costs and where it has got to.
A purchase order records what you ordered from a vendor and on what terms, with a list of line items drawn from your inventory. You don't need to send amount, sub_total, total or line_number: Sortly works them out from the lines.
How an order moves:
draft,ready_for_reviewandapprovedcan each move to one another, or on toordered- From
orderedyou can requestvoidedorclosed - From
ordered, receiving stock also moves the order topartially_receivedand thenreceived, through the receive flow rather than a status call - From
partially_receivedorreceived, the only status you can request isclosed voidedandclosedare final
For the transitions themselves, see Manage PO Statuses.
Goal: move a Sortly purchase order to match where it has got to in your own process, whether that decision was made in another system or over email.
Every transition uses the same endpoint and the same two fields: the target status and the version you got from your last read.
- A stale
versionis rejected with409. Read immediately before writing, and retry with the new one. - Sending a status the order already has changes nothing, so a retried delivery is safe.
| From | Can move to |
|---|---|
draft, ready_for_review, approved | each other, or ordered |
ordered | voided or closed |
partially_received, received | closed |
voided, closed | final |
Anything outside that returns 400. received and partially_received cannot be requested here at all: Sortly sets them when a delivery is recorded against the order, either in the app or through the receive endpoint.
Items are the things you track: stock, tools, assets, supplies. Each one has a quantity and can carry a price, photos, tags and custom fields.
Items and folders share these endpoints; type is what tells them apart. Pass "type": "item" here. For the folder side of the same endpoints, see Folders.
Folders are how you organize inventory by location, category, job, or whatever fits how you work. They can be nested, and items live inside them.
Folders use the same endpoints as items, with "type": "folder" and no quantity or price. Nest one inside another by setting parent_id; leave it out for the top level. To list a folder's contents, pass its id as folder_id when listing items.
Purchase orders record what you have ordered from a vendor and on what terms. Each one carries vendor and ship-to details plus a list of line items drawn from your inventory.
How an order moves:
draft,ready_for_reviewandapprovedcan each move to one another, or on toordered- From
orderedyou can requestvoidedorclosed - Receiving stock moves an
orderedorder topartially_receivedand thenreceived, through the receive flow rather than a status call - From
partially_receivedorreceived, the only status you can request isclosed voidedandclosedare final
Use the status endpoint for these transitions rather than the update endpoint.
Request
Moves the job forward to not_started, in_progress or completed. Moving backwards returns 400. Resending the current status is safe to retry. Completing a job locks its folder.
Target status for the job. Any other value is rejected with 400.
- https://api.sortly.co/api/v1/jobs/{job_id}/status
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -X PUT 'https://api.sortly.co/api/v1/jobs/678/status' \
-H 'Authorization: Bearer YOUR_SECRET_KEY' \
-H 'Content-Type: application/json' \
-d '{"status": "in_progress"}'{ "data": { "id": 101, "name": "HVAC Repair - Unit 4B", "status": "not_started", "folder_id": 4200, "custom_field_values": [], "created_by": { … }, "updated_by": { … }, "created_at": "2026-07-31T07:50:21.524205Z", "updated_at": "2026-07-31T07:50:21.524222Z", "version": 1, "start_date": null, "end_date": null, "notes": "Check refrigerant levels before starting.", "external_job_link": null, "started_at": null, "completed_at": null } }
Request
Moves an item out of the folder it currently sits in and into the job's folder. It does not create anything: pass the item_id of any existing item in your account along with the quantity to move, and that quantity is relocated onto the job.
Up to 100 items per request, and they may sit in different folders, which makes this the practical way to record a batch of usage in one call. POST /items/{item_id}/move performs the same action one item at a time.
Items land in the job's folder itself, never in a subfolder. Even when the job was created with subfolders, everything arrives at the top level of the job folder. To file an item into a particular subfolder, move it again afterwards with POST /items/{item_id}/move and folder_id set to that subfolder.
Items are processed independently, so a failure on one does not reject the rest and a partial failure still returns 200. Always check data.errors rather than relying on the status code, and retry only the items listed there.
Moving part of a quantity splits the item, so an id in added_item_ids can differ from the one you sent. Pulling items into a completed job returns 403.
1 to 100 items per request.
The action reason recorded in each item's history. Required on this endpoint.
UID of a move-type action reason. Required: without it the call is rejected with 400 A reason is required for this action type, and that holds even if you send action with only notes in it. Every account carries Sortly's default move reason Added to Job, e36df891-596f-42a2-a561-3d127d9fa080, which is the one to send unless you have your own. A receive-type reason is rejected with 400 Reason type does not match action type, an unknown one with 400 Reason not found, and a non-UUID with 400 Bad Request.
- https://api.sortly.co/api/v1/jobs/{job_id}/items
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -X POST 'https://api.sortly.co/api/v1/jobs/678/items' \
-H 'Authorization: Bearer YOUR_SECRET_KEY' \
-H 'Content-Type: application/json' \
-d '{"items": [{"item_id": 12345, "quantity": 4}]}'- all-succeeded
- partial-failure
{ "data": { "added_item_ids": [ … ], "errors": [] } }
Request
Moves each item out of the job folder and into destination_folder_id, up to 100 per request. Items are processed one by one, so check errors in the response.
1 to 100 items per request.
Folder to return the item to. If not defined the item is moved to All Items.
- https://api.sortly.co/api/v1/jobs/{job_id}/items/return
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -X POST 'https://api.sortly.co/api/v1/jobs/678/items/return' \
-H 'Authorization: Bearer YOUR_SECRET_KEY' \
-H 'Content-Type: application/json' \
-d '{"items": [{"item_id": 12345, "quantity": 4, "destination_folder_id": 55}]}'- all-succeeded
- completed-job
{ "data": { "returned_item_ids": [ … ], "errors": [] } }
Aug 5, 2026. Added Purchase Orders: list, create, fetch, update and change status.
Jul 31, 2026. Added Jobs: list, create, fetch, update, change status and delete, plus adding items to a job and returning them.
Jun 17, 2021. Added yard and gallon units of measure.
Jun 5, 2021. Added support for item variants (Item Groups).
Jan 4, 2021. Renamed attribute_value to value on custom field values (attribute_value still works). Added tags to item reads and search.
Sep 1, 2020. Added the search endpoint.
Jun 15, 2020. Added alerts.
Mar 2, 2019. First release.