-
Notifications
You must be signed in to change notification settings - Fork 3
Store API Integration
serdarakay edited this page Jun 17, 2025
·
2 revisions
This guide explains how to use the GameDistribution Store API in a Construct 2 project using the Execute JavaScript action.
-
Use the "Execute JavaScript" action in Construct 2 to interact with the Store API.
Example:gdsdk.executeStoreAction({ action: 'ui.open' });
| Description | JavaScript Code |
|---|---|
| Open Store UI | gdsdk.executeStoreAction({ action: 'ui.open' }); |
| Close Store UI | gdsdk.executeStoreAction({ action: 'ui.close' }); |
| Get Virtual Items | await gdsdk.executeStoreAction({ action: 'api.items' }); |
| Buy a Product | await gdsdk.executeStoreAction({ action: 'api.buyProduct', payload: { sku: 'ss-enhance-shield-5', quantity: 1 } }); |
| Inventory Items | await gdsdk.executeStoreAction({ action: 'api.inventoryItems' }); |
More actions are available in the full documentation (see link below).
-
🖼️ Example UI:
➡️ View the full HTML5 SDK Store API Documentation
