sanmar_sdk.ftp.pricing

SanMar’s customer pricing files.

SanMar writes these on request, nightly after 2 AM Pacific, to the account’s outbound folder. my_price is the price for this account specifically.

  • sanmar_dp.csv covers the whole catalog, with the lowest price available to the account in my_price.

  • sanmar_dpIncentive.csv covers the whole catalog, with any special pricing in my_price, or 0 where there is none.

  • sanmar_dpc.csv lists only what changed since the previous file (the first one has everything), with just unique_key and my_price.

Attributes

CUSTOMER_PRICE_COLUMNS

sanmar_dp.csv and sanmar_dpIncentive.csv, per the FTP Integration Guide v23.6.

PRICE_CHANGE_COLUMNS

sanmar_dpc.csv, per the FTP Integration Guide v23.6.

Classes

CustomerPrice

The account's price for one style, color and size.

PriceChange

A changed price from sanmar_dpc.csv.

Functions

read_customer_prices(...)

Stream sanmar_dp.csv or sanmar_dpIncentive.csv, one row at a time.

read_price_changes(→ collections.abc.Iterator[PriceChange])

Stream sanmar_dpc.csv, one changed price at a time.

Module Contents

sanmar_sdk.ftp.pricing.CUSTOMER_PRICE_COLUMNS = ('inventory_key', 'size_index', 'catalog_no', 'catalog_color', 'size', 'piece_weight',...[source]

sanmar_dp.csv and sanmar_dpIncentive.csv, per the FTP Integration Guide v23.6.

sanmar_sdk.ftp.pricing.PRICE_CHANGE_COLUMNS = ('unique_key', 'my_price')[source]

sanmar_dpc.csv, per the FTP Integration Guide v23.6.

class sanmar_sdk.ftp.pricing.CustomerPrice(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

The account’s price for one style, color and size.

unique_key: str[source]
inventory_key: int[source]
size_index: int[source]
style: str = None[source]
catalog_color: str[source]

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

size: str[source]
my_price: sanmar_sdk.base.Price[source]

The account’s price, which is the case or sale price where there is no special pricing.

piece_weight: decimal.Decimal | None = None[source]
piece_price: sanmar_sdk.base.Price = None[source]
case_price: sanmar_sdk.base.Price = None[source]
case_size: int | None = None[source]
piece_sale_price: sanmar_sdk.base.Price = None[source]
case_sale_price: sanmar_sdk.base.Price = None[source]
sale_start_date: sanmar_sdk.base.SanMarDate | None = None[source]
sale_end_date: sanmar_sdk.base.SanMarDate | None = None[source]
discontinued_code: str | None = None[source]

Who discontinued the product, S for SanMar or M for the mill.

class sanmar_sdk.ftp.pricing.PriceChange(/, **data: Any)[source]

Bases: sanmar_sdk.base.Record

A changed price from sanmar_dpc.csv.

unique_key: str[source]
my_price: sanmar_sdk.base.Price[source]
sanmar_sdk.ftp.pricing.read_customer_prices(source: sanmar_sdk.ftp.readers.Source, *, encoding: str = 'utf-8-sig') → collections.abc.Iterator[CustomerPrice][source]

Stream sanmar_dp.csv or sanmar_dpIncentive.csv, one row at a time.

sanmar_sdk.ftp.pricing.read_price_changes(source: sanmar_sdk.ftp.readers.Source, *, encoding: str = 'utf-8-sig') → collections.abc.Iterator[PriceChange][source]

Stream sanmar_dpc.csv, one changed price at a time.