Inventory JSONL - Webhook Flow Diagram
Below is an outline of the overall flow of current inventory data being made available to retrieve via API
%%{init: { "theme": "base", "themeVariables": { "fontSize": "18px", "background": "transparent", "actorBkg": "#038851", "actorTextColor": "#ffffff", "actorBorder": "#026139", "actorLineColor": "#94a3b8", "signalColor": "#64748b", "signalTextColor": "#059669", "noteBkgColor": "#e6f4ee", "noteTextColor": "#02502f", "noteBorderColor": "#038851", "activationBkgColor": "#c6ebdc", "activationBorderColor": "#026139", "sequenceNumberColor": "#ffffff" }, "sequence": { "useMaxWidth": true, "actorMargin": 70, "width": 150, "height": 60, "boxMargin": 12, "noteMargin": 14, "messageMargin": 50, "diagramMarginX": 20, "diagramMarginY": 20, "actorFontSize": 18, "actorFontWeight": 700, "noteFontSize": 15, "noteFontFamily": "ui-monospace, SFMono-Regular, Menlo, Consolas, monospace", "messageFontSize": 16, "messageFontWeight": 700, "noteAlign": "left", "mirrorActors": false } }}%%
sequenceDiagram
autonumber
participant Cron as Daily Cron/Trigger
participant FG as Feed Generator
participant GCS as Google Cloud Storage
participant Webhook as Partner Webhook Endpoint
participant Partner as Partner Integration
Cron->>FG: Trigger daily feed generation (per location)
rect rgb(255,248,210)
Note over FG,GCS: 1. Feed Generation & Storage
loop For each locationId
FG->>FG: Compile product data for [locationId]
end
FG->>GCS: Upload product_feed_[date].csv/jsonl
GCS-->>FG: Confirm successful upload
end
rect rgb(255,248,210)
Note over FG,GCS: 2. Security & URL Generation
FG->>GCS: Request Signed URL (Valid for 24 hours)
GCS-->>FG: Return Signed URL
end
rect rgb(255,248,210)
Note over FG,Webhook: 3. Notification
FG->>Webhook: POST /your-webhook-endpoint\n{\n "locationId":"...",\n "url":"Signed_URL"\n}
Webhook-->>FG: 200 OK (Acknowledge receipt)
end
rect rgb(255,248,210)
Note over Webhook,Partner: 4. Data Consumption (Within 24h)
Partner->>GCS: HTTP GET request using Signed URL
GCS-->>Partner: Return product feed file
end
