Lots feed
Every lot in your Sourcing Events is available through the Lots feed, including lots that have received no bids. The feed provides a record per lot, with its ID and its name on the bid sheet. See the OpenAPI specification for full details.
The Awards and Latest Bids feeds only include lots that were awarded or bid on. The Lots feed includes every lot, so you can use it to see which lots have no bids while an event is still open.
Examples
The following examples show how the feed may be used to get lot data. In each example, we show the URL used with
a GET request and the corresponding response JSON. Click on the Response section to see the full response
content.
Basic Lots feed
This example shows simple use of the Lots feed. It is unfiltered so returns all lot records in the order they have been added or modified, starting from the oldest.
Filtered example
The below example filters to the lots of a specific Sourcing Event.
Including sourcing event data
Add include=sourcing_events to get each event's name and status in the same response. This tells you if the
event is open, closed or deleted without another call.
Identifying lots with no bids
To find the lots of an open event that have not been bid on, fetch both feeds for the same Sourcing Event.
Any lot in the Lots feed that does not appear in the Latest Bids feed has no bids. The id on a Lots feed
record is the same value as lot on a Latest Bids record. Skip lots that have removed set to true, because
they are no longer part of the event.
Using the example responses above, the event contains Lot 1, Lot 2 and Lot 3, while the Latest Bids feed
returns records for Lot 1 and Lot 2 only, so Lot 3 has no bids.
The Latest Bids feed returns a record per supplier per lot, so a lot appears once for each supplier that has bid
on it. Remove duplicate lot values before comparing.
Unlike the Lots feed, the Latest Bids feed applies the 45 day default even when filtered by Sourcing Event. Pass a
modified_after date from before the event was published, or bids older than 45 days will be missed and their
lots will wrongly appear to have no bids. Both feeds are paginated, so follow the next link until every page has
been read.
Filters
The following filters are available on the Lots feed. These are also detailed on the OpenAPI specification. Filters are applied additively.
Filter to the lots of a specific Sourcing Event.
Filter to the lots of a specific Sourcing Request.
Filter to the lots of Sourcing Events that have the specified tags.
Filter to records modified within a date range. One or both ends may be provided. If a date is supplied
without a time, the time defaults to 00:00 UTC.
If no date filters are provided, the feed returns the last 45 days of data by default. The sourcing_event
filter is the exception. Lots only change when the event's lot list changes, so filtering by one event always
returns all of its lots, including removed ones, however long ago it was published.
Response fields
Each lot record contains:
| Field | Type | Description |
|---|---|---|
id |
UUID | The lot identifier, matching lot on the Latest Bids and Awards feeds |
sourcing_event |
UUID | The Sourcing Event this lot belongs to |
sourcing_request |
UUID | The Sourcing Request the event was created from. Not shown if there is none |
lot_name |
string | The lot's name on the bid sheet |
removed |
boolean | true if the lot has been removed from the Sourcing Event |
modified |
datetime | When this record was last updated |
Data updates
The Lots feed is updated each time Sourcing Optimizer sends the lot list of a Sourcing Event, for example when the event is published or resumed, and when bids are placed. Once bidders have seen a lot, it can only be removed if the event is moved back to draft.
When the lot list changes, only lots that were added or renamed get a new record, added to the end of the feed
(see Data Updates for details on how updates work). Lots that did not change keep their
existing record. When a lot is removed from the event, including when all of its lots are removed, its record is
added to the end of the feed again with removed set to true. If a whole Sourcing Event is deleted, its lots are
not marked as removed. To check the event's status, use the sourcing_events include.
The Lots feed has no webhook yet. To see changes, check the feed regularly.