{"openapi":"3.1.0","info":{"title":"Loomivo agent API","version":"1.0.0","description":"Find verified local businesses and send booking, order or quote requests for a customer. The business confirms each request. No key needed; rate limited."},"servers":[{"url":"https://loomivoai.com"}],"paths":{"/agent/v1/businesses":{"get":{"operationId":"searchBusinesses","parameters":[{"name":"q","in":"query","schema":{"type":"string"}},{"name":"city","in":"query","schema":{"type":"string"}},{"name":"country","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Matching businesses"}}}},"/agent/v1/businesses/{slug}":{"get":{"operationId":"getBusiness","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Verified facts and what customers can do"},"404":{"description":"Not found"}}}},"/agent/v1/businesses/{slug}/times":{"get":{"operationId":"getAvailableTimes","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}},{"name":"date","in":"query","required":true,"schema":{"type":"string","format":"date"}},{"name":"staff_id","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"Free times (local)"}}}},"/agent/v1/businesses/{slug}/requests":{"post":{"operationId":"createRequest","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["kind","customer"],"properties":{"kind":{"type":"string","enum":["book","order","quote"]},"slot":{"type":"string","description":"YYYY-MM-DDTHH:MM, local time (book)"},"staff_id":{"type":"string"},"items":{"type":"array","items":{"type":"object","properties":{"offer_id":{"type":"string"},"qty":{"type":"integer"}}}},"fulfilment":{"type":"string","enum":["pickup","delivery"]},"address":{"type":"string"},"details":{"type":"string"},"agent":{"type":"string","description":"Your agent's name"},"customer":{"type":"object","required":["name","phone"],"properties":{"name":{"type":"string"},"phone":{"type":"string"},"email":{"type":"string"}}}}}}}},"responses":{"201":{"description":"Request sent: ref and status_url"},"400":{"description":"Not possible (error explains why)"}}}},"/agent/v1/requests/{ref}":{"get":{"operationId":"getRequestStatus","parameters":[{"name":"ref","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"new | confirmed | declined"}}}}}}