{"openapi":"3.1.0","info":{"title":"Villámpiac network — public buyer discovery","version":"1.0.0","description":"Anonymous product and vendor search. The hostname selects the vendor country; there is no country query parameter. Products require a public, future pickup event with remaining stock covering its entire window and sufficient preparation time (produced stock is exempt). Private pickup and home-delivery zones are omitted from these generic results. Checkout currently accepts HUF products only. Prices are decimal strings in the stated currency; never infer currency from the hostname. No order creation or reservation is offered by this API. Product links lead to the buyer checkout flow, which revalidates price, options, stock and fulfillment. Responses may be cached for 30 seconds and served stale for another 60 seconds; fetchedAt identifies when the response was generated, not when inventory was modified."},"servers":[{"url":"https://www.villampiac.hu","description":"Villámpiac (HU)"},{"url":"https://www.flashmob.market","description":"Flashmob Market (US)"},{"url":"https://www.reilutori.fi","description":"Reilutori (FI)"},{"url":"https://www.rejaltorg.se","description":"Rejaltorg (SE)"},{"url":"https://www.piatavie.ro","description":"Piața Vie (RO)"},{"url":"https://www.erntetreff.de","description":"Erntetreff (DE)"}],"security":[],"paths":{"/api/search":{"get":{"operationId":"searchBuyerAutocomplete","summary":"Find orderable products and active vendors","description":"Hungarian-accent-insensitive substring matching. Product names, descriptions and tag names are searched; vendors are searched by name. Returns at most 3 vendors. Product limit does not affect vendor count. This autocomplete endpoint has no pagination.","parameters":[{"name":"q","in":"query","required":true,"description":"Trimmed search text.","schema":{"type":"string","minLength":2,"maxLength":100}},{"name":"limit","in":"query","required":false,"description":"Maximum product results.","schema":{"type":"integer","minimum":1,"maximum":10,"default":5}}],"responses":{"200":{"description":"Search results.","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"const":true},"data":{"type":"object","required":["products","vendors","fetchedAt"],"properties":{"products":{"type":"array","maxItems":10,"items":{"$ref":"#/components/schemas/Product"}},"vendors":{"type":"array","maxItems":3,"items":{"$ref":"#/components/schemas/Vendor"}},"fetchedAt":{"type":"string","format":"date-time"}}}}}}}},"400":{"description":"Invalid query parameters.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Shared IP search limit exceeded (60 requests per minute across both endpoints).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"description":"Wait at least this many seconds before retrying.","schema":{"type":"integer","example":60}}}},"500":{"description":"Search temporarily unavailable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/products/search":{"get":{"operationId":"searchBuyerProducts","summary":"Browse orderable products with filters and pagination","description":"Sort: promoted vendors first, then product name and numeric product ID ascending. Stable for an unchanged catalog; stock changes between requests can still shift offset pages. hasMore uses a lookahead row. Follow nextOffset until null. Unknown query parameters are ignored.","parameters":[{"name":"search","in":"query","required":false,"description":"Optional trimmed substring matched against product name, description and tag names; Hungarian accents are folded.","schema":{"type":"string","maxLength":100}},{"name":"tags","in":"query","required":false,"description":"Comma-separated tag slugs. Whitespace and duplicates are removed; ALL distinct tags must match.","schema":{"type":"string","maxLength":500}},{"name":"sale","in":"query","required":false,"description":"Only products with a currently active discounted price. Omit to include regular prices too.","schema":{"type":"string","enum":["1"]}},{"name":"limit","in":"query","required":false,"description":"Maximum product results.","schema":{"type":"integer","minimum":1,"maximum":50,"default":50}},{"name":"offset","in":"query","required":false,"description":"Number of matching products to skip.","schema":{"type":"integer","minimum":0,"default":0}}],"responses":{"200":{"description":"One page of products.","content":{"application/json":{"schema":{"type":"object","required":["success","data"],"properties":{"success":{"const":true},"data":{"type":"object","required":["products","count","hasMore","offset","limit","nextOffset","fetchedAt"],"properties":{"products":{"type":"array","maxItems":50,"items":{"$ref":"#/components/schemas/Product"}},"count":{"type":"integer","minimum":0,"description":"Number returned on this page, not total matches."},"hasMore":{"type":"boolean"},"offset":{"type":"integer","minimum":0},"limit":{"type":"integer","minimum":1,"maximum":50},"nextOffset":{"type":["integer","null"],"minimum":0},"fetchedAt":{"type":"string","format":"date-time"}}}}}}}},"400":{"description":"Invalid query parameters.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Shared IP search limit exceeded (60 requests per minute across both endpoints).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"description":"Wait at least this many seconds before retrying.","schema":{"type":"integer","example":60}}}},"500":{"description":"Search temporarily unavailable.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Error":{"type":"object","required":["success","error"],"properties":{"success":{"const":false},"error":{"type":"string"}}},"Tag":{"type":"object","required":["id","name","slug"],"properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"slug":{"type":"string"}}},"Vendor":{"type":"object","required":["id","name","slug","imageUrl","logoUrl"],"properties":{"id":{"type":"integer"},"name":{"type":"string"},"slug":{"type":["string","null"]},"imageUrl":{"type":["string","null"]},"logoUrl":{"type":["string","null"]}}},"PickupEvent":{"type":"object","required":["id","startTime","endTime","locationId","locationName","locationAddress","fulfillmentMode","availableQuantity","variantAvailability","hasProducedSupply"],"properties":{"id":{"type":"integer"},"startTime":{"type":"string","format":"date-time"},"endTime":{"type":"string","format":"date-time"},"locationId":{"type":"integer"},"locationName":{"type":"string"},"locationAddress":{"type":"string","description":"Public pickup address; never a buyer delivery address."},"fulfillmentMode":{"type":"string","enum":["pickup"]},"availableQuantity":{"type":"integer","minimum":0},"hasProducedSupply":{"type":"boolean"},"variantAvailability":{"type":["array","null"],"description":"Null means a shared pool; otherwise stock is fixed per selected form.","items":{"type":"object","required":["selectedOptions","availableQuantity"],"properties":{"selectedOptions":{"type":"object","additionalProperties":{"type":"string"}},"availableQuantity":{"type":"integer","minimum":0}}}}}},"Product":{"type":"object","required":["id","name","slug","description","price","salePrice","saleEndsAt","currency","vendorCountryCode","unit","options","imageUrl","vendorId","vendorName","vendorSlug","tags","availableQuantity","pickupEvents","url"],"properties":{"id":{"type":"integer"},"name":{"type":"string"},"slug":{"type":["string","null"]},"description":{"type":["string","null"]},"price":{"type":"string","description":"Regular unit price as a decimal major-unit amount, in currency."},"salePrice":{"type":["string","null"],"description":"Optional configured discount. Applies only when below price and saleEndsAt is null or in the future."},"saleEndsAt":{"type":["string","null"],"format":"date-time"},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"vendorCountryCode":{"type":"string","pattern":"^[A-Z]{2}$"},"unit":{"type":["string","null"]},"options":{"type":["object","null"],"description":"Product option groups; checkout validates selected choices and option preparation requirements.","additionalProperties":true},"imageUrl":{"type":["string","null"]},"vendorId":{"type":"integer"},"vendorName":{"type":"string"},"vendorSlug":{"type":["string","null"]},"tags":{"type":"array","items":{"$ref":"#/components/schemas/Tag"}},"url":{"type":["string","null"],"format":"uri","description":"Absolute product URL; null for a legacy product with no slug."},"availableQuantity":{"type":"integer","minimum":0,"description":"Largest stock quantity at one eligible event. Do not add quantities across events: a production pool can be shared."},"pickupEvents":{"type":"array","maxItems":20,"items":{"$ref":"#/components/schemas/PickupEvent"},"description":"Earliest eligible public pickup events, ordered by start time then ID; bounded subset, not an exhaustive fulfillment list."}}}}}}