DevelopersAPI reference

Pricing rules API

REST endpoints for pricing rules in SKUFlow: 6 operations with parameters, request and response fields, permissions and curl examples.

Base URL: https://app.skuflow.ai/api. Every call needs Authorization: Bearer skf_… (Authentication); {organizationId} ($ORGANIZATION_ID in the examples) is your business's id.

OperationEndpointRisk
Pricing rulesGET /organizations/{organizationId}/pricing-rulesread
Add a pricing rulePOST /organizations/{organizationId}/pricing-ruleswrite
A pricing ruleGET /organizations/{organizationId}/pricing-rules/{pricingRuleId}read
Change a pricing rulePATCH /organizations/{organizationId}/pricing-rules/{pricingRuleId}write
Delete a pricing ruleDELETE /organizations/{organizationId}/pricing-rules/{pricingRuleId}sensitive
Preview a priceGET /organizations/{organizationId}/pricing-rules/previewread

Pricing rules

GET /organizations/{organizationId}/pricing-rules

The business's pricing rules: markup by cost tier (percent or multiplier), what they match (kind, brand, category, supplier), rounding and minimum margin. A product follows its own rule, else the most specific matching rule (ties by priority), else the default, else keystone ×2 ending .99. Read-only.

Permissionproducts.read (Owner, Admin, Staff, Member)
Riskread, OAuth scope skuflow.read. Read: reads only.
MCP toolpricingRules_list (toolset catalog)

Example

curl "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY"

Response

200: the answer's fields
FieldTypeDescription
itemsarray of object
items[].idstring
items[].namestring
items[].priorityinteger
items[].activeboolean
items[].isDefaultboolean
items[].kindenum or nullAPPAREL (garments: colour × size), PROMO (promotional items), LARGE_FORMAT (banners and signs priced per square foot from a material) or OTHER. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
items[].brandstring or null
items[].categorystring or null
items[].supplierConnectionIdstring or null
items[].tiersarray of objectCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
items[].tiers[].minCostCentsintegerThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
items[].tiers[].modeenumPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
items[].tiers[].valuenumberThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
items[].roundingenumOne of NONE, END_99, WHOLE_DOLLAR.
items[].minMarginPercentnumber or null
items[].productCountintegerProducts that chose this rule (others may match it).
items[].createdAtstring (date-time)
items[].updatedAtstring (date-time)

Add a pricing rule

POST /organizations/{organizationId}/pricing-rules

Creates a rule and reprices every product that now follows it (owner prices are kept). repriced counts variants whose price changed. One tier must start at cost 0.

Permissionpricing.manage (Owner, Admin)
Riskwrite, OAuth scope skuflow.write. Write: creates or changes records inside the business; nothing leaves it.
MCP toolpricingRules_create (toolset catalog)

Request body

FieldTypeRequiredDescription
namestringYesUp to 200 characters.
priorityintegerNoLower wins among equally specific rules. 0–100000.
activebooleanNo
isDefaultbooleanNoUsed when no other rule matches (one per business).
kindenum or nullNoMatch only this product kind. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
brandstring or nullNoMatch only this brand (any case). Up to 200 characters.
categorystring or nullNoMatch only this category. Up to 200 characters.
supplierConnectionIdstring or nullNoMatch only products from this supplier connection.
tiersarray of objectYesCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
tiers[].minCostCentsintegerYesThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
tiers[].modeenumYesPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
tiers[].valuenumberYesThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
roundingenumNoNONE, END_99 (up to .99) or WHOLE_DOLLAR. One of NONE, END_99, WHOLE_DOLLAR.
minMarginPercentnumber or nullNoThe price never leaves less margin than this. 0–95.

Example

curl -X POST "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"Dana Whitfield","tiers":[{"minCostCents":12500,"mode":"PERCENT","value":1}]}'

Response

200: the answer's fields
FieldTypeDescription
idstring
namestring
priorityinteger
activeboolean
isDefaultboolean
kindenum or nullAPPAREL (garments: colour × size), PROMO (promotional items), LARGE_FORMAT (banners and signs priced per square foot from a material) or OTHER. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
brandstring or null
categorystring or null
supplierConnectionIdstring or null
tiersarray of objectCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
tiers[].minCostCentsintegerThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
tiers[].modeenumPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
tiers[].valuenumberThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
roundingenumOne of NONE, END_99, WHOLE_DOLLAR.
minMarginPercentnumber or null
productCountintegerProducts that chose this rule (others may match it).
createdAtstring (date-time)
updatedAtstring (date-time)
repricedinteger

A pricing rule

GET /organizations/{organizationId}/pricing-rules/{pricingRuleId}

One pricing rule with its cost tiers, match criteria, rounding and minimum margin. Read-only.

Permissionproducts.read (Owner, Admin, Staff, Member)
Riskread, OAuth scope skuflow.read. Read: reads only.
MCP toolpricingRules_get (toolset catalog)

Parameters

NameInTypeRequiredDescription
pricingRuleIdpathstringYes

Example

curl "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules/{pricingRuleId}" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY"

Response

200: the answer's fields
FieldTypeDescription
idstring
namestring
priorityinteger
activeboolean
isDefaultboolean
kindenum or nullAPPAREL (garments: colour × size), PROMO (promotional items), LARGE_FORMAT (banners and signs priced per square foot from a material) or OTHER. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
brandstring or null
categorystring or null
supplierConnectionIdstring or null
tiersarray of objectCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
tiers[].minCostCentsintegerThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
tiers[].modeenumPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
tiers[].valuenumberThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
roundingenumOne of NONE, END_99, WHOLE_DOLLAR.
minMarginPercentnumber or null
productCountintegerProducts that chose this rule (others may match it).
createdAtstring (date-time)
updatedAtstring (date-time)

Change a pricing rule

PATCH /organizations/{organizationId}/pricing-rules/{pricingRuleId}

Changes the fields sent and reprices every product that follows the rule (owner prices kept).

Permissionpricing.manage (Owner, Admin)
Riskwrite, OAuth scope skuflow.write. Write: creates or changes records inside the business; nothing leaves it.
MCP toolpricingRules_update (toolset catalog)

Parameters

NameInTypeRequiredDescription
pricingRuleIdpathstringYes

Request body

FieldTypeRequiredDescription
namestringNoUp to 200 characters.
priorityintegerNoLower wins among equally specific rules. 0–100000.
activebooleanNo
isDefaultbooleanNoUsed when no other rule matches (one per business).
kindenum or nullNoMatch only this product kind. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
brandstring or nullNoMatch only this brand (any case). Up to 200 characters.
categorystring or nullNoMatch only this category. Up to 200 characters.
supplierConnectionIdstring or nullNoMatch only products from this supplier connection.
tiersarray of objectNoCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
tiers[].minCostCentsintegerYesThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
tiers[].modeenumYesPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
tiers[].valuenumberYesThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
roundingenumNoNONE, END_99 (up to .99) or WHOLE_DOLLAR. One of NONE, END_99, WHOLE_DOLLAR.
minMarginPercentnumber or nullNoThe price never leaves less margin than this. 0–95.

Example

curl -X PATCH "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules/{pricingRuleId}" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"Dana Whitfield","priority":1,"active":true}'

Response

200: the answer's fields
FieldTypeDescription
idstring
namestring
priorityinteger
activeboolean
isDefaultboolean
kindenum or nullAPPAREL (garments: colour × size), PROMO (promotional items), LARGE_FORMAT (banners and signs priced per square foot from a material) or OTHER. One of APPAREL, PROMO, LARGE_FORMAT, OTHER.
brandstring or null
categorystring or null
supplierConnectionIdstring or null
tiersarray of objectCost tiers: the tier with the highest starting cost at or under a product's cost applies. Up to 20 items.
tiers[].minCostCentsintegerThe tier applies from this unit cost (cents) up to the next tier's. 0–100000000.
tiers[].modeenumPercent: cost × (1 + value ÷ 100). MULTIPLIER: cost × value. One of PERCENT, MULTIPLIER.
tiers[].valuenumberThe markup percent (e.g. 60 for +60 %) or the multiplier (e.g. 1.8). 0–10000.
roundingenumOne of NONE, END_99, WHOLE_DOLLAR.
minMarginPercentnumber or null
productCountintegerProducts that chose this rule (others may match it).
createdAtstring (date-time)
updatedAtstring (date-time)
repricedinteger

Delete a pricing rule

DELETE /organizations/{organizationId}/pricing-rules/{pricingRuleId}

Destructive: deletes the rule; products that chose it follow the matching rule again and are repriced now.

Permissionpricing.manage (Owner, Admin)
Risksensitive, OAuth scope skuflow.sensitive. Sensitive: moves money, deletes, sends or shows something to a customer, or grants or revokes access.
MCP toolpricingRules_delete (toolset catalog)
ApprovalOver MCP, this tool always waits for your approval in SKUFlow. See Approvals.

Parameters

NameInTypeRequiredDescription
pricingRuleIdpathstringYes

Example

curl -X DELETE "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules/{pricingRuleId}" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY"

Response

200: the answer's fields
FieldTypeDescription
deletedtrue
repricedinteger

Preview a price

GET /organizations/{organizationId}/pricing-rules/preview

What a rule (or the keystone fallback when none is named) makes of a unit cost: the tier, the markup, whether the minimum margin lifted it, the rounded price and the margin. Read-only.

Permissionpricing.manage (Owner, Admin)
Riskread, OAuth scope skuflow.read. Read: reads only.
MCP toolpricingRules_preview (toolset catalog)

Parameters

NameInTypeRequiredDescription
costCentsqueryintegerYes0–100000000.
pricingRuleIdquerystringNo

Example

curl "https://app.skuflow.ai/api/organizations/$ORGANIZATION_ID/pricing-rules/preview?costCents=12500" \
  -H "Authorization: Bearer $SKUFLOW_API_KEY"

Response

200: the answer's fields
FieldTypeDescription
pricingRuleIdstring or null
costCentsinteger
markedUpCentsinteger
marginFloorAppliedboolean
priceCentsinteger
marginCentsinteger
marginPercentnumber or null

On this page