sanmar_sdk.promostandards.product_data

SanMar’s PromoStandards Product Data service, version 2.0.0.

Describes a style and every color and size of it, and lists which parts are closed out, changed or sellable. In PromoStandards terms a product is a SanMar style (K500) and a part is one style, color and size, identified by SanMar’s unique key.

Attributes

Classes

Color

One of a part's colors.

ApparelSize

A part's size.

Dimension

A part's measurements.

Packaging

A way a part is packed: how many to a box, and how big and heavy the box is.

Specification

A measurement of a part, such as its chest or inseam.

ProductPart

One color and size of a style.

MarketingPoint

A selling point from a product's description.

Category

A category a product is listed under.

RelatedProduct

Another product SanMar relates to this one.

ProductPrice

One price break.

PriceGroup

A named set of price breaks, such as MSRP.

FobPoint

A place SanMar ships from: one of its warehouses.

Product

A style, and every color and size of it.

PartReference

A product, or one part of it, in a list of changed, closed-out or sellable items.

ProductDataService

SanMar's PromoStandards Product Data service.

Module Contents

sanmar_sdk.promostandards.product_data.COUNTRY = 'US'[source]
sanmar_sdk.promostandards.product_data.LANGUAGE = 'en'[source]
class sanmar_sdk.promostandards.product_data.Color(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

One of a part’s colors.

catalog_color: str = None[source]

The catalog (mainframe) color, which web services and orders expect.

color_name: str | None = None[source]

The full color name, for display only.

hex: str | None = None[source]
approximate_pms: str | None = None[source]

The nearest Pantone color, such as BLACK C.

class sanmar_sdk.promostandards.product_data.ApparelSize(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A part’s size.

apparel_style: str = None[source]

Unisex, Mens, Womens, Youth, MensTall and so on.

label_size: str = None[source]

XS through 6XL, OSFA, or CUSTOM when custom_size holds it.

custom_size: str | None = None[source]

The size when it is not a standard label size, such as a pant size (2732).

property size: str[source]

The size as SanMar prints it, which is the custom size where there is one.

class sanmar_sdk.promostandards.product_data.Dimension(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A part’s measurements.

dimension_uom: str = None[source]
depth: decimal.Decimal[source]
height: decimal.Decimal[source]
width: decimal.Decimal[source]
weight_uom: str = None[source]
weight: decimal.Decimal[source]
class sanmar_sdk.promostandards.product_data.Packaging(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A way a part is packed: how many to a box, and how big and heavy the box is.

package_type: str = None[source]
quantity: decimal.Decimal[source]
description: str | None = None[source]
default: bool = False[source]
dimension_uom: str | None = None[source]
depth: decimal.Decimal | None = None[source]
height: decimal.Decimal | None = None[source]
width: decimal.Decimal | None = None[source]
weight_uom: str | None = None[source]
weight: decimal.Decimal | None = None[source]
class sanmar_sdk.promostandards.product_data.Specification(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A measurement of a part, such as its chest or inseam.

specification_type: str = None[source]
uom: str = None[source]
value: str = None[source]
class sanmar_sdk.promostandards.product_data.ProductPart(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

One color and size of a style.

part_id: str = None[source]

SanMar’s unique key for this style, color and size.

primary_color: Color | None = None[source]
colors: list[Color] = None[source]
descriptions: list[str] = None[source]
apparel_size: ApparelSize | None = None[source]
country_of_origin: str | None = None[source]
primary_material: str | None = None[source]
specifications: list[Specification] = None[source]
dimension: Dimension | None = None[source]
lead_time: int | None = None[source]
gtin: str | None = None[source]
rush_service: bool = None[source]
packaging: list[Packaging] = None[source]
shipping_packages: list[Packaging] = None[source]

How the part ships, as the case it comes in and how many pieces are in it.

effective_date: datetime.datetime | None = None[source]
end_date: datetime.datetime | None = None[source]
closeout: bool = None[source]
caution: bool = None[source]
caution_comment: str | None = None[source]
on_demand: bool = None[source]
hazmat: bool = None[source]
property catalog_color: str | None[source]

The part’s catalog (mainframe) color, which web services and orders expect.

class sanmar_sdk.promostandards.product_data.MarketingPoint(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A selling point from a product’s description.

text: str = None[source]
point_type: str | None = None[source]
class sanmar_sdk.promostandards.product_data.Category(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A category a product is listed under.

category: str[source]
subcategory: str | None = None[source]
class sanmar_sdk.promostandards.product_data.RelatedProduct(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

Another product SanMar relates to this one.

relation_type: str = None[source]

Companion Sell, Substitute or Common Grouping.

product_id: str = None[source]
part_id: str | None = None[source]
class sanmar_sdk.promostandards.product_data.ProductPrice(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

One price break.

quantity_min: int = None[source]
quantity_max: int | None = None[source]
price: decimal.Decimal[source]
discount_code: str | None = None[source]
class sanmar_sdk.promostandards.product_data.PriceGroup(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A named set of price breaks, such as MSRP.

name: str = None[source]
currency: str[source]
description: str | None = None[source]
prices: list[ProductPrice] = None[source]
class sanmar_sdk.promostandards.product_data.FobPoint(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A place SanMar ships from: one of its warehouses.

warehouse: sanmar_sdk.common.WarehouseNumber = None[source]
city: str | None = None[source]
state: str | None = None[source]
postal_code: str | None = None[source]
country: str | None = None[source]
currencies: Annotated[list[str], pluck('currency')] = None[source]

The currencies SanMar prices in from here. Only the pricing service reports them.

class sanmar_sdk.promostandards.product_data.Product(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A style, and every color and size of it.

product_id: str = None[source]

The style number, such as K500.

name: str = None[source]
descriptions: list[str] = None[source]

The description, one paragraph or bullet point to an entry.

brand: str | None = None[source]
line_name: str | None = None[source]
marketing_points: list[MarketingPoint] = None[source]
keywords: Annotated[list[str], pluck('keyword')] = None[source]
categories: list[Category] = None[source]
related_products: list[RelatedProduct] = None[source]
primary_image_url: str | None = None[source]
price_groups: list[PriceGroup] = None[source]
price_expires_date: datetime.datetime | None = None[source]
parts: list[ProductPart] = None[source]
fob_points: list[FobPoint] = None[source]
export: bool | None = None[source]
compliance_info_available: bool | None = None[source]
unspsc_commodity_code: int | None = None[source]
last_change_date: datetime.datetime | None = None[source]
creation_date: datetime.datetime | None = None[source]
effective_date: datetime.datetime | None = None[source]
end_date: datetime.datetime | None = None[source]
closeout: bool = None[source]
caution: bool = None[source]
caution_comment: str | None = None[source]
class sanmar_sdk.promostandards.product_data.PartReference(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A product, or one part of it, in a list of changed, closed-out or sellable items.

product_id: str = None[source]
part_id: str | None = None[source]
class sanmar_sdk.promostandards.product_data.ProductDataService(soap: SoapClient, credentials: Credentials)[source]

Bases: sanmar_sdk.promostandards._common.PromoStandardsService

SanMar’s PromoStandards Product Data service.

endpoint[source]
version = '2.0.0'[source]

The PromoStandards version SanMar implements, sent as wsVersion.

get(product_id: str, *, part_id: str | None = None, catalog_color: str | None = None) → Product[source]

Describe a style, optionally narrowed to one part or one catalog color.

SanMar recommends asking for whole styles rather than one part at a time.

closeouts() → list[PartReference][source]

List every part SanMar has discontinued.

modified_since(since: datetime.datetime) → list[PartReference][source]

List every part that changed after a point in time.

sellable(product_id: str | None = None, *, part_id: str | None = None, is_sellable: bool = True) → list[PartReference][source]

List the parts SanMar sells, across the catalog or within one style.

With is_sellable=False, list the parts SanMar no longer sells instead.