Is there any way to find out when a DiscountRedeemCodeBulkCreation has a progress update without long polling?
The discountRedeemCodeBulkAdd API, in addition to only allowing batches of 100 redeem codes at a time, seems to only allow up to 30 concurrent batches. This poses challenges when a merchant wants to generate/upload more than 3,000 codes.
For example, we’ve had a merchant who wanted to generate 1,000,000 codes. This would have required them to manually split the codes into 334 batches of 3,000 and wait for each to complete.
The best workaround we’ve been able to come up with is to implement long-polling to continually monitor the status of up to 30 active DiscountRedeemCodeBulkCreation and queue up new ones as jobs finish.
However, this approach has issues: polling too quickly could lead to rate limit issues.
It doesn’t seem like there’s any webhook we can subscribe to in order to avoid polling. Are there any plans for such a webhook? Thank you.
A webhook would theoretically be nice, but you’d still have to store a jobId in state (somewhere), so l’d imagine the infrastructure would look almost the same as what you’d do today.
We do up to 1 million at a time with Code Bulk, and whilst you do get the occasional failures, it’s a pretty rock solid API.
I’d also say, given the history of bulk redemption codes, I think it’s unlikely there will be a lot of work done there in the near future - just a feeling!
Not sure if this would work for your use cases, since I do understand if you’re creating a bunch in bulk it may get heavy to handle all of the incoming webhooks, but just wanted to share this as a possible workaround - let me know if this helps!