Queries LibraryCreate thousands of redemption codes for AppSumo in LemonSqueezy
Create thousands of redemption codes for AppSumo in LemonSqueezy
This query connects to the LemonSqueezy API and creates a hundred 100% discount codes at one go.
Execute this query multiple times to create the 10.000 codes required to run an AppSumo campaign.
You must provide:
The access token to connect to the Lemon Squeezy API, via variable $lemonSqueezyAccessToken
The Lemon Squeezy store, via variable $storeID
The product(s) to be redeemed by that code, via variable $variantIDs
The generated discount code will be a random string. You can prepend a string to the code (via variable $codePrefix), indicate how long the code will be (via variable $codeLength), and customize the name of the discount code (via variables $discountNamePrefix and $firstRecordNumber) to search for it in the Lemon Squeezy dashboard.
Collect all the newly-created discount codes by providing a $postId, then all codes will be appended at the end of that post.