sanmar_sdk.standard.inventory ============================= .. py:module:: sanmar_sdk.standard.inventory .. autoapi-nested-parse:: SanMar's own inventory service. Reports stock by warehouse for a style, optionally narrowed to a catalog color or a size. SanMar caps the quantity it reports per warehouse, and asks that this service be used for a handful of items at a time; for anything more frequent than a live check at ordering time, it recommends ``sanmar_dip.txt`` or the PromoStandards inventory service. SanMar answers a lookup by style and color, style and size, or style alone with each size and warehouse named, but answers a lookup by style, color *and* size with bare numbers in an order it does not state. This service therefore never sends all three: given a color and a size, it asks for the color and keeps the matching size itself. Classes ------- .. autoapisummary:: sanmar_sdk.standard.inventory.WarehouseStock sanmar_sdk.standard.inventory.SkuStock sanmar_sdk.standard.inventory.InventoryService Module Contents --------------- .. py:class:: WarehouseStock(/, **data: Any) Bases: :py:obj:`sanmar_sdk.base.Record` Stock of one style, color and size at one warehouse. .. py:attribute:: warehouse :type: sanmar_sdk.common.WarehouseNumber :value: None .. py:attribute:: quantity :type: int :value: None Stock at this warehouse, capped by SanMar. .. py:attribute:: name :type: str | None :value: None .. py:class:: SkuStock(/, **data: Any) Bases: :py:obj:`sanmar_sdk.base.Record` Stock of one style, color and size, warehouse by warehouse. .. py:attribute:: style :type: str .. py:attribute:: catalog_color :type: str :value: None The catalog (mainframe) color, which web services and orders expect. .. py:attribute:: size :type: str .. py:attribute:: warehouses :type: sanmar_sdk.base.OneOrMany[WarehouseStock] :value: None .. py:property:: total :type: int Stock across every warehouse. .. py:class:: InventoryService(soap: SoapClient, credentials: Credentials) Bases: :py:obj:`sanmar_sdk._soap.Service` SanMar's own inventory service. .. py:method:: get(style: str, *, catalog_color: str | None = None, size: str | None = None) -> list[SkuStock] Look up stock by warehouse for a style, one catalog color, one size, or both. The color must be the catalog (mainframe) color, not the display name. .. py:method:: get_quantity(style: str, catalog_color: str, size: str, warehouse: sanmar_sdk.common.Warehouse | int) -> int Look up the stock of one style, catalog color and size at one warehouse.