|
|
|
|
@@ -25,7 +25,7 @@
|
|
|
|
|
|
|
|
|
|
| Merchant | Owner | Stores |
|
|
|
|
|
|----------|-------|--------|
|
|
|
|
|
| WizaCorp Ltd. (id=1) | john.owner@wizacorp.com | WIZAMART, WIZAGADGETS, WIZAHOME |
|
|
|
|
|
| WizaCorp Ltd. (id=1) | john.owner@wizacorp.com | ORION, WIZAGADGETS, WIZAHOME |
|
|
|
|
|
| Fashion Group S.A. (id=2) | jane.owner@fashiongroup.com | FASHIONHUB, FASHIONOUTLET |
|
|
|
|
|
| BookWorld Publishing (id=3) | bob.owner@bookworld.com | BOOKSTORE, BOOKDIGITAL |
|
|
|
|
|
|
|
|
|
|
@@ -33,7 +33,7 @@
|
|
|
|
|
|
|
|
|
|
| Email | Role | Type |
|
|
|
|
|
|-------|------|------|
|
|
|
|
|
| admin@wizamart.com | admin | Platform admin |
|
|
|
|
|
| admin@orion.lu | admin | Platform admin |
|
|
|
|
|
| samir.boulahtit@gmail.com | admin | Platform admin |
|
|
|
|
|
| john.owner@wizacorp.com | store | Owner of WizaCorp (merchant 1) |
|
|
|
|
|
| jane.owner@fashiongroup.com | store | Owner of Fashion Group (merchant 2) |
|
|
|
|
|
@@ -68,7 +68,7 @@ The dev server uses path-based platform routing: `http://localhost:9999/platform
|
|
|
|
|
|
|
|
|
|
### 1. Platform Admin Pages
|
|
|
|
|
|
|
|
|
|
Login as: `admin@wizamart.com` or `samir.boulahtit@gmail.com`
|
|
|
|
|
Login as: `admin@orion.lu` or `samir.boulahtit@gmail.com`
|
|
|
|
|
|
|
|
|
|
| Page | Dev URL |
|
|
|
|
|
|------|---------|
|
|
|
|
|
@@ -89,11 +89,11 @@ Login as the store owner, then navigate to any of their stores.
|
|
|
|
|
|
|
|
|
|
| Page | Dev URL |
|
|
|
|
|
|------|---------|
|
|
|
|
|
| Terminal | `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/terminal` |
|
|
|
|
|
| Cards | `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/cards` |
|
|
|
|
|
| Settings | `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/settings` |
|
|
|
|
|
| Stats | `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/stats` |
|
|
|
|
|
| Enroll Customer | `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/enroll` |
|
|
|
|
|
| Terminal | `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/terminal` |
|
|
|
|
|
| Cards | `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/cards` |
|
|
|
|
|
| Settings | `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/settings` |
|
|
|
|
|
| Stats | `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/stats` |
|
|
|
|
|
| Enroll Customer | `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/enroll` |
|
|
|
|
|
|
|
|
|
|
**Fashion Group (jane.owner@fashiongroup.com):**
|
|
|
|
|
|
|
|
|
|
@@ -117,10 +117,10 @@ Login as the store owner, then navigate to any of their stores.
|
|
|
|
|
|
|
|
|
|
### 3. Customer Storefront Pages
|
|
|
|
|
|
|
|
|
|
Login as a customer (e.g., `customer1@wizamart.example.com`).
|
|
|
|
|
Login as a customer (e.g., `customer1@orion.example.com`).
|
|
|
|
|
|
|
|
|
|
!!! note "Store domain required"
|
|
|
|
|
Storefront pages require a store domain context. Only WIZAMART (`wizamart.shop`)
|
|
|
|
|
Storefront pages require a store domain context. Only ORION (`orion.shop`)
|
|
|
|
|
and FASHIONHUB (`fashionhub.store`) have domains configured. In dev, storefront
|
|
|
|
|
routes may need to be accessed through the store's domain or platform path.
|
|
|
|
|
|
|
|
|
|
@@ -169,7 +169,7 @@ Login as a customer (e.g., `customer1@wizamart.example.com`).
|
|
|
|
|
|
|
|
|
|
| Method | Endpoint | Dev URL |
|
|
|
|
|
|--------|----------|---------|
|
|
|
|
|
| GET | program | `http://localhost:9999/platforms/loyalty/api/loyalty/programs/WIZAMART` |
|
|
|
|
|
| GET | program | `http://localhost:9999/platforms/loyalty/api/loyalty/programs/ORION` |
|
|
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
@@ -195,7 +195,7 @@ or **subdomains** of `loyalty.lu` (from `Store.subdomain`).
|
|
|
|
|
2. **Merchant domain** (`merchant_domains` table) — inherited by all merchant's stores
|
|
|
|
|
3. **Store subdomain** (`Store.subdomain` + platform domain) — fallback
|
|
|
|
|
|
|
|
|
|
### Case 1: Store with custom domain (e.g., `wizamart.shop`)
|
|
|
|
|
### Case 1: Store with custom domain (e.g., `orion.shop`)
|
|
|
|
|
|
|
|
|
|
The store has a verified entry in the `store_domains` table. **All** store URLs
|
|
|
|
|
(storefront, store backend, store APIs) are served from the custom domain.
|
|
|
|
|
@@ -204,42 +204,42 @@ The store has a verified entry in the `store_domains` table. **All** store URLs
|
|
|
|
|
|
|
|
|
|
| Page | Production URL |
|
|
|
|
|
|------|----------------|
|
|
|
|
|
| Loyalty Dashboard | `https://wizamart.shop/account/loyalty` |
|
|
|
|
|
| Transaction History | `https://wizamart.shop/account/loyalty/history` |
|
|
|
|
|
| Self-Enrollment | `https://wizamart.shop/loyalty/join` |
|
|
|
|
|
| Enrollment Success | `https://wizamart.shop/loyalty/join/success` |
|
|
|
|
|
| Loyalty Dashboard | `https://orion.shop/account/loyalty` |
|
|
|
|
|
| Transaction History | `https://orion.shop/account/loyalty/history` |
|
|
|
|
|
| Self-Enrollment | `https://orion.shop/loyalty/join` |
|
|
|
|
|
| Enrollment Success | `https://orion.shop/loyalty/join/success` |
|
|
|
|
|
|
|
|
|
|
**Storefront API:**
|
|
|
|
|
|
|
|
|
|
| Method | Production URL |
|
|
|
|
|
|--------|----------------|
|
|
|
|
|
| GET card | `https://wizamart.shop/api/storefront/loyalty/card` |
|
|
|
|
|
| GET transactions | `https://wizamart.shop/api/storefront/loyalty/transactions` |
|
|
|
|
|
| POST enroll | `https://wizamart.shop/api/storefront/loyalty/enroll` |
|
|
|
|
|
| GET program | `https://wizamart.shop/api/storefront/loyalty/program` |
|
|
|
|
|
| GET card | `https://orion.shop/api/storefront/loyalty/card` |
|
|
|
|
|
| GET transactions | `https://orion.shop/api/storefront/loyalty/transactions` |
|
|
|
|
|
| POST enroll | `https://orion.shop/api/storefront/loyalty/enroll` |
|
|
|
|
|
| GET program | `https://orion.shop/api/storefront/loyalty/program` |
|
|
|
|
|
|
|
|
|
|
**Store backend (staff/owner):**
|
|
|
|
|
|
|
|
|
|
| Page | Production URL |
|
|
|
|
|
|------|----------------|
|
|
|
|
|
| Store Login | `https://wizamart.shop/store/WIZAMART/login` |
|
|
|
|
|
| Terminal | `https://wizamart.shop/store/WIZAMART/loyalty/terminal` |
|
|
|
|
|
| Cards | `https://wizamart.shop/store/WIZAMART/loyalty/cards` |
|
|
|
|
|
| Card Detail | `https://wizamart.shop/store/WIZAMART/loyalty/cards/{card_id}` |
|
|
|
|
|
| Settings | `https://wizamart.shop/store/WIZAMART/loyalty/settings` |
|
|
|
|
|
| Stats | `https://wizamart.shop/store/WIZAMART/loyalty/stats` |
|
|
|
|
|
| Enroll Customer | `https://wizamart.shop/store/WIZAMART/loyalty/enroll` |
|
|
|
|
|
| Store Login | `https://orion.shop/store/ORION/login` |
|
|
|
|
|
| Terminal | `https://orion.shop/store/ORION/loyalty/terminal` |
|
|
|
|
|
| Cards | `https://orion.shop/store/ORION/loyalty/cards` |
|
|
|
|
|
| Card Detail | `https://orion.shop/store/ORION/loyalty/cards/{card_id}` |
|
|
|
|
|
| Settings | `https://orion.shop/store/ORION/loyalty/settings` |
|
|
|
|
|
| Stats | `https://orion.shop/store/ORION/loyalty/stats` |
|
|
|
|
|
| Enroll Customer | `https://orion.shop/store/ORION/loyalty/enroll` |
|
|
|
|
|
|
|
|
|
|
**Store API:**
|
|
|
|
|
|
|
|
|
|
| Method | Production URL |
|
|
|
|
|
|--------|----------------|
|
|
|
|
|
| GET program | `https://wizamart.shop/api/store/loyalty/program` |
|
|
|
|
|
| POST program | `https://wizamart.shop/api/store/loyalty/program` |
|
|
|
|
|
| POST stamp | `https://wizamart.shop/api/store/loyalty/stamp` |
|
|
|
|
|
| POST points | `https://wizamart.shop/api/store/loyalty/points` |
|
|
|
|
|
| POST enroll | `https://wizamart.shop/api/store/loyalty/cards/enroll` |
|
|
|
|
|
| POST lookup | `https://wizamart.shop/api/store/loyalty/cards/lookup` |
|
|
|
|
|
| GET program | `https://orion.shop/api/store/loyalty/program` |
|
|
|
|
|
| POST program | `https://orion.shop/api/store/loyalty/program` |
|
|
|
|
|
| POST stamp | `https://orion.shop/api/store/loyalty/stamp` |
|
|
|
|
|
| POST points | `https://orion.shop/api/store/loyalty/points` |
|
|
|
|
|
| POST enroll | `https://orion.shop/api/store/loyalty/cards/enroll` |
|
|
|
|
|
| POST lookup | `https://orion.shop/api/store/loyalty/cards/lookup` |
|
|
|
|
|
|
|
|
|
|
### Case 2: Store with merchant domain (e.g., `myloyaltyprogram.lu`)
|
|
|
|
|
|
|
|
|
|
@@ -345,7 +345,7 @@ The store has no entry in `store_domains` and the merchant has no registered dom
|
|
|
|
|
| Admin Merchant Settings | `https://loyalty.lu/admin/loyalty/merchants/{id}/settings` |
|
|
|
|
|
| Admin API - Programs | `GET https://loyalty.lu/api/admin/loyalty/programs` |
|
|
|
|
|
| Admin API - Stats | `GET https://loyalty.lu/api/admin/loyalty/stats` |
|
|
|
|
|
| Public API - Program | `GET https://loyalty.lu/api/loyalty/programs/WIZAMART` |
|
|
|
|
|
| Public API - Program | `GET https://loyalty.lu/api/loyalty/programs/ORION` |
|
|
|
|
|
| Apple Wallet Pass | `GET https://loyalty.lu/api/loyalty/passes/apple/{serial}.pkpass` |
|
|
|
|
|
|
|
|
|
|
### Domain configuration per store (current DB state)
|
|
|
|
|
@@ -362,7 +362,7 @@ The store has no entry in `store_domains` and the merchant has no registered dom
|
|
|
|
|
|
|
|
|
|
| Store | Merchant | Store Custom Domain | Effective Domain |
|
|
|
|
|
|-------|----------|---------------------|------------------|
|
|
|
|
|
| WIZAMART | WizaCorp | `wizamart.shop` | `wizamart.shop` (store override) |
|
|
|
|
|
| ORION | WizaCorp | `orion.shop` | `orion.shop` (store override) |
|
|
|
|
|
| FASHIONHUB | Fashion Group | `fashionhub.store` | `fashionhub.store` (store override) |
|
|
|
|
|
| WIZAGADGETS | WizaCorp | _(none)_ | `wizagadgets.loyalty.lu` (subdomain fallback) |
|
|
|
|
|
| WIZAHOME | WizaCorp | _(none)_ | `wizahome.loyalty.lu` (subdomain fallback) |
|
|
|
|
|
@@ -375,16 +375,16 @@ The store has no entry in `store_domains` and the merchant has no registered dom
|
|
|
|
|
|
|
|
|
|
| Store | Effective Domain | Reason |
|
|
|
|
|
|-------|------------------|--------|
|
|
|
|
|
| WIZAMART | `wizamart.shop` | Store custom domain takes priority |
|
|
|
|
|
| ORION | `orion.shop` | Store custom domain takes priority |
|
|
|
|
|
| WIZAGADGETS | `myloyaltyprogram.lu` | Inherits merchant domain |
|
|
|
|
|
| WIZAHOME | `myloyaltyprogram.lu` | Inherits merchant domain |
|
|
|
|
|
|
|
|
|
|
!!! info "`{store_domain}` in journey URLs"
|
|
|
|
|
In the journeys below, `{store_domain}` refers to the store's **effective domain**, resolved in priority order:
|
|
|
|
|
|
|
|
|
|
1. **Store custom domain**: `wizamart.shop` (from `store_domains` table) — highest priority
|
|
|
|
|
1. **Store custom domain**: `orion.shop` (from `store_domains` table) — highest priority
|
|
|
|
|
2. **Merchant domain**: `myloyaltyprogram.lu` (from `merchant_domains` table) — inherited default
|
|
|
|
|
3. **Subdomain fallback**: `wizamart.loyalty.lu` (from `Store.subdomain` + platform domain)
|
|
|
|
|
3. **Subdomain fallback**: `orion.loyalty.lu` (from `Store.subdomain` + platform domain)
|
|
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
@@ -418,9 +418,9 @@ flowchart TD
|
|
|
|
|
**Step 1: Subscribe to the platform**
|
|
|
|
|
|
|
|
|
|
1. Login as `john.owner@wizacorp.com` and navigate to billing:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/billing`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/store/WIZAMART/billing`
|
|
|
|
|
- Prod (subdomain): `https://wizamart.loyalty.lu/store/WIZAMART/billing`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/billing`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/store/ORION/billing`
|
|
|
|
|
- Prod (subdomain): `https://orion.loyalty.lu/store/ORION/billing`
|
|
|
|
|
2. View available subscription tiers:
|
|
|
|
|
- API Dev: `GET http://localhost:9999/platforms/loyalty/api/v1/store/billing/tiers`
|
|
|
|
|
- API Prod: `GET https://{store_domain}/api/v1/store/billing/tiers`
|
|
|
|
|
@@ -447,7 +447,7 @@ flowchart TD
|
|
|
|
|
3. Get DNS verification instructions:
|
|
|
|
|
- API Dev: `GET http://localhost:9999/platforms/loyalty/api/v1/admin/merchants/domains/merchant/{domain_id}/verification-instructions`
|
|
|
|
|
- API Prod: `GET https://loyalty.lu/api/v1/admin/merchants/domains/merchant/{domain_id}/verification-instructions`
|
|
|
|
|
4. Merchant adds a DNS TXT record: `_wizamart-verify.myloyaltyprogram.lu TXT {verification_token}`
|
|
|
|
|
4. Merchant adds a DNS TXT record: `_orion-verify.myloyaltyprogram.lu TXT {verification_token}`
|
|
|
|
|
5. Verify the domain:
|
|
|
|
|
- API Dev: `POST http://localhost:9999/platforms/loyalty/api/v1/admin/merchants/domains/merchant/{domain_id}/verify`
|
|
|
|
|
- API Prod: `POST https://loyalty.lu/api/v1/admin/merchants/domains/merchant/{domain_id}/verify`
|
|
|
|
|
@@ -459,7 +459,7 @@ flowchart TD
|
|
|
|
|
|
|
|
|
|
**Step 3: (Optional) Register store-specific domain override**
|
|
|
|
|
|
|
|
|
|
If a store needs its own domain (e.g., WIZAMART is a major brand and wants `mysuperloyaltyprogram.lu`):
|
|
|
|
|
If a store needs its own domain (e.g., ORION is a major brand and wants `mysuperloyaltyprogram.lu`):
|
|
|
|
|
|
|
|
|
|
1. Platform admin registers a store domain:
|
|
|
|
|
- API Dev: `POST http://localhost:9999/platforms/loyalty/api/v1/admin/stores/{store_id}/domains`
|
|
|
|
|
@@ -473,7 +473,7 @@ If a store needs its own domain (e.g., WIZAMART is a major brand and wants `mysu
|
|
|
|
|
|
|
|
|
|
| Store | Effective Domain | Source |
|
|
|
|
|
|-------|------------------|--------|
|
|
|
|
|
| WIZAMART | `mysuperloyaltyprogram.lu` | Store custom domain (override) |
|
|
|
|
|
| ORION | `mysuperloyaltyprogram.lu` | Store custom domain (override) |
|
|
|
|
|
| WIZAGADGETS | `myloyaltyprogram.lu` | Merchant domain (inherited) |
|
|
|
|
|
| WIZAHOME | `myloyaltyprogram.lu` | Merchant domain (inherited) |
|
|
|
|
|
|
|
|
|
|
@@ -507,13 +507,13 @@ flowchart TD
|
|
|
|
|
**Steps:**
|
|
|
|
|
|
|
|
|
|
1. Login as `john.owner@wizacorp.com` at:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/login`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/store/WIZAMART/login`
|
|
|
|
|
- Prod (subdomain): `https://wizamart.loyalty.lu/store/WIZAMART/login`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/login`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/store/ORION/login`
|
|
|
|
|
- Prod (subdomain): `https://orion.loyalty.lu/store/ORION/login`
|
|
|
|
|
2. Navigate to loyalty settings:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/settings`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/store/WIZAMART/loyalty/settings`
|
|
|
|
|
- Prod (subdomain): `https://wizamart.loyalty.lu/store/WIZAMART/loyalty/settings`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/settings`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/store/ORION/loyalty/settings`
|
|
|
|
|
- Prod (subdomain): `https://orion.loyalty.lu/store/ORION/loyalty/settings`
|
|
|
|
|
3. Create a new loyalty program:
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/program`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/program`
|
|
|
|
|
@@ -563,8 +563,8 @@ flowchart TD
|
|
|
|
|
**Steps:**
|
|
|
|
|
|
|
|
|
|
1. Login as `alice.manager@wizacorp.com` and open the terminal:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/terminal`
|
|
|
|
|
2. Scan customer QR code or enter card number:
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/cards/lookup`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/cards/lookup`
|
|
|
|
|
@@ -576,11 +576,11 @@ flowchart TD
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/stamp/redeem`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/stamp/redeem`
|
|
|
|
|
6. View updated card:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/cards/{card_id}`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/cards/{card_id}`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/cards/{card_id}`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/cards/{card_id}`
|
|
|
|
|
7. Browse all cards:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/cards`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/cards`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/cards`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/cards`
|
|
|
|
|
|
|
|
|
|
**Anti-fraud scenarios to test:**
|
|
|
|
|
|
|
|
|
|
@@ -611,8 +611,8 @@ flowchart TD
|
|
|
|
|
**Steps:**
|
|
|
|
|
|
|
|
|
|
1. Open the terminal:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/terminal`
|
|
|
|
|
2. Lookup card:
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/cards/lookup`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/cards/lookup`
|
|
|
|
|
@@ -624,8 +624,8 @@ flowchart TD
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/points/redeem`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/points/redeem`
|
|
|
|
|
6. Check store-level stats:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/stats`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/stats`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/stats`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/stats`
|
|
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
@@ -648,16 +648,16 @@ flowchart TD
|
|
|
|
|
|
|
|
|
|
1. Visit the public enrollment page:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/loyalty/join`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/loyalty/join`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/loyalty/join`
|
|
|
|
|
- Prod (subdomain): `https://bookstore.loyalty.lu/loyalty/join`
|
|
|
|
|
2. Fill in enrollment form (email, name)
|
|
|
|
|
3. Submit enrollment:
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/storefront/loyalty/enroll`
|
|
|
|
|
- Prod (custom domain): `POST https://wizamart.shop/api/storefront/loyalty/enroll`
|
|
|
|
|
- Prod (custom domain): `POST https://orion.shop/api/storefront/loyalty/enroll`
|
|
|
|
|
- Prod (subdomain): `POST https://bookstore.loyalty.lu/api/storefront/loyalty/enroll`
|
|
|
|
|
4. Redirected to success page:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/loyalty/join/success?card=XXXX-XXXX-XXXX`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/loyalty/join/success?card=XXXX-XXXX-XXXX`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/loyalty/join/success?card=XXXX-XXXX-XXXX`
|
|
|
|
|
- Prod (subdomain): `https://bookstore.loyalty.lu/loyalty/join/success?card=XXXX-XXXX-XXXX`
|
|
|
|
|
5. Optionally download Apple Wallet pass:
|
|
|
|
|
- Dev: `GET http://localhost:9999/platforms/loyalty/api/loyalty/passes/apple/{serial_number}.pkpass`
|
|
|
|
|
@@ -667,7 +667,7 @@ flowchart TD
|
|
|
|
|
|
|
|
|
|
### Journey 5: Customer - View Loyalty Status
|
|
|
|
|
|
|
|
|
|
**Persona:** Authenticated Customer (e.g., `customer1@wizamart.example.com`)
|
|
|
|
|
**Persona:** Authenticated Customer (e.g., `customer1@orion.example.com`)
|
|
|
|
|
**Goal:** Check loyalty balance and history
|
|
|
|
|
|
|
|
|
|
**Steps:**
|
|
|
|
|
@@ -675,22 +675,22 @@ flowchart TD
|
|
|
|
|
1. Login as customer at the storefront
|
|
|
|
|
2. View loyalty dashboard (card balance, available rewards):
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/account/loyalty`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/account/loyalty`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/account/loyalty`
|
|
|
|
|
- Prod (subdomain): `https://bookstore.loyalty.lu/account/loyalty`
|
|
|
|
|
- API Dev: `GET http://localhost:9999/platforms/loyalty/api/storefront/loyalty/card`
|
|
|
|
|
- API Prod: `GET https://wizamart.shop/api/storefront/loyalty/card`
|
|
|
|
|
- API Prod: `GET https://orion.shop/api/storefront/loyalty/card`
|
|
|
|
|
3. View full transaction history:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/account/loyalty/history`
|
|
|
|
|
- Prod (custom domain): `https://wizamart.shop/account/loyalty/history`
|
|
|
|
|
- Prod (custom domain): `https://orion.shop/account/loyalty/history`
|
|
|
|
|
- Prod (subdomain): `https://bookstore.loyalty.lu/account/loyalty/history`
|
|
|
|
|
- API Dev: `GET http://localhost:9999/platforms/loyalty/api/storefront/loyalty/transactions`
|
|
|
|
|
- API Prod: `GET https://wizamart.shop/api/storefront/loyalty/transactions`
|
|
|
|
|
- API Prod: `GET https://orion.shop/api/storefront/loyalty/transactions`
|
|
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
### Journey 6: Platform Admin - Oversight
|
|
|
|
|
|
|
|
|
|
**Persona:** Platform Admin (`admin@wizamart.com` or `samir.boulahtit@gmail.com`)
|
|
|
|
|
**Persona:** Platform Admin (`admin@orion.lu` or `samir.boulahtit@gmail.com`)
|
|
|
|
|
**Goal:** Monitor all loyalty programs across merchants
|
|
|
|
|
|
|
|
|
|
**Steps:**
|
|
|
|
|
@@ -725,13 +725,13 @@ flowchart TD
|
|
|
|
|
**Steps:**
|
|
|
|
|
|
|
|
|
|
1. Open terminal and lookup card:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/terminal`
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/cards/lookup`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/cards/lookup`
|
|
|
|
|
2. View the card's transaction history to find the transaction to void:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/cards/{card_id}`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/cards/{card_id}`
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/cards/{card_id}`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/cards/{card_id}`
|
|
|
|
|
- API Dev: `GET http://localhost:9999/platforms/loyalty/api/store/loyalty/cards/{card_id}/transactions`
|
|
|
|
|
- API Prod: `GET https://{store_domain}/api/store/loyalty/cards/{card_id}/transactions`
|
|
|
|
|
3. Void a stamp transaction:
|
|
|
|
|
@@ -756,9 +756,9 @@ flowchart TD
|
|
|
|
|
|
|
|
|
|
**Steps:**
|
|
|
|
|
|
|
|
|
|
1. Staff at WIZAMART adds stamps to customer's card:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/WIZAMART/loyalty/terminal`
|
|
|
|
|
1. Staff at ORION adds stamps to customer's card:
|
|
|
|
|
- Dev: `http://localhost:9999/platforms/loyalty/store/ORION/loyalty/terminal`
|
|
|
|
|
- Prod: `https://{store_domain}/store/ORION/loyalty/terminal`
|
|
|
|
|
- Dev: `POST http://localhost:9999/platforms/loyalty/api/store/loyalty/stamp`
|
|
|
|
|
- Prod: `POST https://{store_domain}/api/store/loyalty/stamp`
|
|
|
|
|
2. Customer visits WIZAGADGETS
|
|
|
|
|
@@ -785,7 +785,7 @@ flowchart TD
|
|
|
|
|
4. **Journey 2 or 3** - Process stamps/points
|
|
|
|
|
5. **Journey 5** - Verify customer can see their data
|
|
|
|
|
6. **Journey 7** - Test void/return
|
|
|
|
|
7. **Journey 8** - Test cross-store (enroll via WIZAMART, redeem via WIZAGADGETS)
|
|
|
|
|
7. **Journey 8** - Test cross-store (enroll via ORION, redeem via WIZAGADGETS)
|
|
|
|
|
8. **Journey 6** - Admin overview (verify data appears correctly)
|
|
|
|
|
|
|
|
|
|
!!! tip "Journey 0 and Journey 1 are independent"
|
|
|
|
|
|