Shopify Integration
Compiled RobotRoss knowledge page generated from RobotRoss source code, architecture notes, and operational documentation.
Contents
Shopify Integration
1. Overview
The RobotRoss ecosystem integrates with a Shopify storefront (robotross.art) to provide a familiar e-commerce experience for human customers.
2. Webhook Workflow
- Order Creation: A customer completes a purchase on Shopify.
- Webhook: Shopify sends a
POSTrequest tohttps://api.robotross.art/salesman/webhooks/order-created. - Validation: The Salesman API validates the Shopify HMAC signature using a shared secret.
- Parsing: The server extracts
type,content,slot, andbuyerfrom the order line items. - Queue Entry: The order is added to the
orders.jsonqueue withstatus: "new".
3. Proof of Work Write-back
Once the Artist (robot) completes a drawing and reports the YouTube URL:
- Metafield Update: The Salesman API calls the Shopify API to write the
proof_of_work_urlinto thecustom.proof_of_workmetafield on the specific Shopify order. - Fulfilment: The order is marked as fulfilled on Shopify, triggering any customer notification emails.
4. Key Configurations
- Shop Domain:
robot-ross.myshopify.com - Webhook HMAC Secret: Stored as an environment variable (
SHOPIFY_WEBHOOK_SECRET) insalesman-api.service. - API Version: 2026-01
5. Notes and Open Points
- Token Refresh: A
refresh-shopify-token.shcron job is mentioned in the documentation, but its exact implementation and failure recovery are not fully documented. - Line Item Mapping: The logic for extracting
typeandcontentfrom Shopify line items is currently subject to a known issue (Ticket #13) to ensure it handles complex orders with multiple variants correctly.
Sources:
AGENTS/CONTEXT/robot_ross_salesman.mdsalesman-cloud-infra/opt/salesman-api/server.mjs