# API 2025-03 changelog

Changes in API version `2025-03`. [Open the 2025-03 API reference](/reference/2025-03).

This API version is a major upgrade compared to the previous API. This document mentions the primary changes done.

## Products API

#### Remove fields

* `in_stock` `booked` `available` and `incoming` fields have been removed. Instead you need to access the stock levels for the product to get the stock numbers.
* `close_at_quantity` is moved to stock levels since it should be applied at the warehouse and product level.
* `lead_time` has been moved to the product-supplier relation. The API for product supplier relation is not exposed. You can set lead time using the Sumtracker UI.

#### Renamed fields

* `cost` has been renamed to `wavg_landed_cost`

#### Filter changes

* Filters using the removed fields are also removed.

## Stock levels API

* Bundle stock levels now have a new endpoint of its own. The primary end for stock levels will not return bundle products.

## Purchase orders API

Purchase orders API has a lot of changes. The primary change being now stock transfer can be done using the purchase orders API.

#### Stock transfers

* For stock transfers you need to provide `from_warehouse_id` in creation instead of the `contact_id`.
* Stock transfers do not have the option to add `shipping_cost` and `pack_size` in line items.

#### Async actions

* When you perform an action on the purchase order, the action is performed asynchronously
* The status of the async task is provided by the field `is_task_in_progress`

#### Order dates

* `ship_by_time` now refers to the date by which the supplier is expected to ship the goods.
  Previously it referred to the date the goods were expected to arrive at the warehouse.
* `expected_arrival_date` is a new field holding the date the goods are expected to arrive at
  the warehouse. This is the value `ship_by_time` used to carry, so integrations that read or
  write `ship_by_time` for arrival dates must switch to `expected_arrival_date`.
* `confirmation_date` is a new field holding the date the order was confirmed.
* All three dates are optional and may be null. They can be set when creating an order and
  changed later with the update endpoint.
* Matching range filters are available: `confirmation_date_range`, `ship_by_time_range` (now
  filtering on the ship-by date) and `expected_arrival_date_range`.

#### New Contacts (Suppliers) API

* You can fetch the list of contacts for creating purchase orders.

#### Line errors

* PO lines have a new read only `error` field. It is `null` when the line is fine, and otherwise
  describes why the line is not ready, for example a quantity that is not a whole number of packs.
* No action can be performed on a purchase order while any of its lines has an `error`.
* The PO lines list can be filtered with `error__isnull`. Pass `false` to list only the lines
  that have an error.
* The line update API still rejects a `quantity` that is not a multiple of `pack_size`, so this
  field is only set for lines added or edited in the Sumtracker app.

## Stock adjustments

* Stock adjustments API `mark-complete` action is now async.
* The status of the async action is provided by the field `is_task_in_progress`
