The window.GiveawayGator.test() method is a powerful developer API that allows merchants and developers to simulate active giveaway promotions on their storefront without needing to configure actual promotions in the admin panel. This is perfect for testing designs, previewing functionality, and demonstrating the Giveaway Gator experience.
window.GiveawayGator.test()
This creates a simulated promotion with:
window.GiveawayGator.test({
dollarPerEntry: 10,
entryCalculation: {
bonusPeriod: {
multiplier: 5,
endTime: "2025-07-07T12:00:00"
}
}
})
window.GiveawayGator.test(false)
This restores the original state and removes the test mode badge.