Class: DiscountCodeCreationJob

DiscountCodeCreationJob(shopify)

new DiscountCodeCreationJob(shopify)

Creates an DiscountCodeCreation instance.
Parameters:
Name Type Description
shopify Shopify Reference to the Shopify instance

Methods

create(priceRuleId, params) → {Promise}

Creates a discount code creation job.
Parameters:
Name Type Description
priceRuleId Number Price rule ID
params Array Array of discount codes
Returns:
Promise that resolves with the result
Type
Promise

discountCodes(priceRuleId, batchId) → {Promise}

Retrieves a list of discount codes for a discount code creation job.
Parameters:
Name Type Description
priceRuleId Number Price rule ID
batchId Number Discount code creation job ID
Returns:
Promise that resolves with the result
Type
Promise