Staging Environment
The Loyalty.lt API provides a dedicated staging environment for testing your integrations before going live with production data.Staging vs Production
| Feature | Staging | Production |
|---|---|---|
| Base URL | https://staging-api.loyalty.lt | https://api.loyalty.lt |
| Data | Demo/test data | Real customer data |
| API Credentials | Staging credentials only | Production credentials only |
| Weekly reset | Yes (Sundays) | No |
Getting Staging API Credentials
- Log in to the Partners Portal
- Navigate to API Credentials in the sidebar menu
- Click Create New Credential
- Select Environment: Staging
- Save your API Key and Secret (shown only once!)
Demo Test Data
The staging environment includes pre-configured demo data for testing:Demo Loyalty Cards
Card numbers use the formatXXX-XXX-XXX. Demo cards start with 900-:
| Card Number | Phone | Points | |
|---|---|---|---|
900-001-001 | +37060000001 | [email protected] | 1000 |
900-002-001 | +37060000002 | [email protected] | 2500 |
900-003-001 | +37060000003 | [email protected] | 500 |
900-004-001 | +37060000004 | [email protected] | 10000 |
900-005-001 | +37060000005 | [email protected] | 150 |
Card number format:
900-{user_id}-{partner_id} where IDs are zero-padded to 3 digits.Demo Staff Accounts
Staff members log in to the Staff App using their Barcode (numbers only):| Barcode | Name | Role |
|---|---|---|
100000001 | Demo Manager | Manager |
100000002 | Demo Cashier | Cashier |
Barcode format:
{partner_id}{user_id} where user_id is zero-padded to 8 digits.Example: For partner ID 5 and user ID 123, barcode would be 500000123.Staff accounts are created for each partner synced from production.SDK Configuration
JavaScript SDK
PHP SDK
Python SDK
Weekly Data Reset
The staging environment is reset every Sunday at 05:00 EET.
All test transactions and temporary data are cleared.
Demo cards and partner catalog data are preserved.
What Gets Reset
- Customer transactions
- Point awards/redemptions
- Game progress and sessions
- Coupon redemptions
- Activity logs
What Gets Preserved
- Partner settings and catalog (products, games, offers)
- Demo loyalty cards
- Demo staff accounts
- API credentials
Testing Recommendations
1. Test the Full Flow
2. Test Error Handling
Use invalid card numbers to test error handling:3. Test Games & Coupons
Rate Limits
Staging environment has the same rate limits as production:- 100 requests per minute per API credential
- 1000 requests per hour per partner
Troubleshooting
Common Issues
401 Unauthorized
401 Unauthorized
404 Card Not Found
404 Card Not Found
- Use demo card numbers listed above
- Cards created in production don’t exist in staging
- Wait for weekly sync if testing with specific partner data
Connection Timeout
Connection Timeout
- Staging server may have higher latency than production
- Increase timeout settings in your SDK configuration
Support
If you encounter issues with the staging environment:- Email: [email protected]
- Include your partner ID and error details