{"openapi":"3.1.0","info":{"title":"OfferClerk","version":"1.0.0","description":"the offer replaces the ad. Conditional checkout quotes for Fernhouse, Halfcourt, Cold Front, and Morrowkiln Coffee in USD. channel and customer_status are claimed, verified at checkout. Unknown request fields and enum values return 400 with a Did you mean hint. Quotes do not place orders."},"servers":[{"url":"https://offerclerk.ai"}],"paths":{"/api/stores":{"get":{"operationId":"listStores","summary":"List the four demo stores","responses":{"200":{"description":"Store cards and the MCP URL","content":{"application/json":{"schema":{"type":"object","properties":{"service":{"const":"OfferClerk"}}}}}}}}},"/api/offers":{"get":{"operationId":"searchOffers","summary":"Search offers across the four stores","parameters":[{"name":"product","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Matching offers in USD. An unmatched query returns an empty offers array."}}}},"/api/stores/{slug}":{"get":{"operationId":"getStore","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","enum":["fernhouse","halfcourt","coldfront","morrowkiln"]}}],"responses":{"200":{"description":"One store"},"404":{"description":"Unknown store"}}}},"/api/stores/{slug}/catalog":{"get":{"operationId":"getCatalog","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","enum":["fernhouse","halfcourt","coldfront","morrowkiln"]}}],"responses":{"200":{"description":"Products, shipping, and offers"}}}},"/api/stores/{slug}/offers":{"get":{"operationId":"listStoreOffers","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","enum":["fernhouse","halfcourt","coldfront","morrowkiln"]}},{"name":"product","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Offers with structured conditions and a redeem example"}}}},"/api/stores/{slug}/quote":{"post":{"operationId":"quoteCart","summary":"Price a cart","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","enum":["fernhouse","halfcourt","coldfront","morrowkiln"]}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["lines"],"properties":{"lines":{"type":"array","minItems":1,"maxItems":30,"items":{"type":"object","additionalProperties":false,"required":["product_id"],"properties":{"product_id":{"type":"string"},"variant_id":{"type":"string"},"qty":{"type":"integer","minimum":1,"maximum":8,"default":1}}}},"channel":{"type":"string","enum":["agent","card"],"default":"card"},"delivery":{"type":"string","enum":["standard","express","patient"],"default":"standard"},"customer_status":{"type":"string","enum":["new","returning","unknown"],"default":"unknown"},"shade_profile":{"type":"object","additionalProperties":false,"nullable":true,"properties":{"undertone":{"type":"string"}}}}}}}},"responses":{"200":{"description":"Quote in USD. verification.channel and verification.customer_status are claimed, verified at checkout."},"400":{"description":"Invalid cart, unknown field, or unknown enum value. errors[] includes Did you mean when a near miss is recognized. items, cart, and line_items are not accepted."}}}},"/api/stores/{slug}/preview":{"post":{"operationId":"previewDraft","summary":"Price a seller draft without publishing it","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","enum":["fernhouse","halfcourt","coldfront","morrowkiln"]}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["setup","cart"],"properties":{"setup":{"type":"object","additionalProperties":false,"required":["product_id","percent","min_qty","audience"],"properties":{"product_id":{"type":"string","description":"Product ID from this store catalog."},"percent":{"type":"integer","minimum":1,"maximum":30},"min_qty":{"type":"integer","minimum":1,"maximum":8},"audience":{"type":"string","enum":["everyone","returning","new"]}}},"cart":{"type":"object","additionalProperties":false,"required":["lines"],"properties":{"lines":{"type":"array","minItems":1,"maxItems":30,"items":{"type":"object","additionalProperties":false,"required":["product_id"],"properties":{"product_id":{"type":"string"},"variant_id":{"type":"string"},"qty":{"type":"integer","minimum":1,"maximum":8,"default":1}}}},"channel":{"type":"string","enum":["agent","card"],"default":"card"},"delivery":{"type":"string","enum":["standard","express","patient"],"default":"standard"},"customer_status":{"type":"string","enum":["new","returning","unknown"],"default":"unknown"},"shade_profile":{"type":"object","additionalProperties":false,"nullable":true,"properties":{"undertone":{"type":"string"}}}}}}},"example":{"setup":{"product_id":"lumen-serum","percent":10,"min_qty":2,"audience":"returning"},"cart":{"channel":"agent","customer_status":"returning","lines":[{"product_id":"lumen-serum","qty":2}]}}}}},"responses":{"200":{"description":"Preview quote"},"400":{"description":"Invalid setup or cart"}}}},"/mcp":{"post":{"operationId":"mcp","summary":"MCP endpoint: search_offers and quote for the four USD stores","responses":{"200":{"description":"JSON-RPC result"}}}},"/llms.txt":{"get":{"operationId":"llmsTxt","responses":{"200":{"description":"Agent guide"}}}},"/openapi.json":{"get":{"operationId":"openApi","responses":{"200":{"description":"This document"}}}},"/.well-known/api-catalog":{"get":{"operationId":"apiCatalog","responses":{"200":{"description":"Linkset pointing at this document and llms.txt"}}}}}}