Shopify-Store — Produkt-Mappings (Sub-Route)
Zweck
Sub-Route /shopify-stores/:id/product-mappings verknuepft SpeamCore-Produkte mit Shopify-Produkten. Sync-Job (siehe Sync-Konzept) verwendet die Mappings, um Bestand und Preise synchron zu halten.
Weitere Sub-Routen am Shopify-Store: /product-assignments, /order-mappings, /customer-mappings, /sync-logs.
Berechtigungen (CASL)
| Action | Subject | Wirkung | Keycloak-Rolle |
|---|---|---|---|
view | FE_ShopifyStore, ShopifyStore | Detail aufrufbar | — |
view/create | ShopifyProductMapping | Mappings pflegen | APP_SPEAMCORE_VIEW/CREATE_SHOPIFY_PRODUCT_MAPPING |
view | Product | Auswahl | APP_SPEAMCORE_VIEW_PRODUCT |
Schritt-für-Schritt-Anleitung
- Shopify-Store (
/shopify-stores/:id) → Tab Produkt-Mappings. - + Mapping verbindet ein SpeamCore-Produkt mit einem Shopify-Produkt.
- Sync-Job übernimmt das Mapping bei der nächsten Ausführung.
Anlege-Pattern
ShopifyStoreProductMapping haelt die Verknuepfung zwischen einem SpeamCore-Product und dem entsprechenden Eintrag im Shopify-Shop:
shopifyStoreId— welcher Shop.productId— SpeamCore-Produkt.shopifyProductId— Produkt-ID im Shopify-Shop (extern).lastSyncedAt— Zeitstempel des letzten Sync.
Sync-Logik laeuft via Hintergrund-Job (siehe Sync-Jobs) — Bestand und Preise werden zwischen SpeamCore (Master) und Shopify (Storefront) abgeglichen.
Wiederverwendbare Konzepte
Verknuepfungen zu anderen Modulen
- Shopify-Stores — Eltern-Modul.
- Produkte — Stamm.
- Shop-Bestellungen — beruhen auf gemappten Produkten.
API/Schnittstellen
| Methode | Endpoint | Zweck | CASL |
|---|---|---|---|
GET | /api/shopify-product-mappings?filter[storeId] | Liste | view ShopifyProductMapping |
POST | /api/shopify-product-mappings | Anlegen | create ShopifyProductMapping |
Versionshinweise
- 2026-04-30: Initiale Veroeffentlichung.