{"openapi":"3.1.0","info":{"title":"Meibo API","version":"1.0.0"},"servers":[{"url":"https://app.meibolabs.com/api/v1"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"Record":{"type":"object","required":["kind","name","status"],"properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["team","talent","companies","people","deals","campaigns","tasks","notes","emails"]},"name":{"type":"string","minLength":1,"maxLength":200},"status":{"type":"string"},"version":{"type":"integer","minimum":1},"company":{"type":"string"},"talent":{"type":"string"},"owner":{"type":"string"},"related":{"type":"string"},"collaborators":{"type":"array","items":{"type":"string"}},"body":{"type":"string"}}},"Enquiry":{"type":"object","additionalProperties":false,"required":["name","email","subject","message"],"properties":{"name":{"type":"string","maxLength":200},"email":{"type":"string","format":"email","maxLength":254},"subject":{"type":"string","maxLength":200},"message":{"type":"string","maxLength":10000},"owner":{"type":"string"}}}}},"paths":{"/records":{"get":{"summary":"List records (records:read)","parameters":[{"name":"kind","in":"query","schema":{"type":"string","enum":["team","talent","companies","people","deals","campaigns","tasks","notes","emails"]}},{"name":"cursor","in":"query","schema":{"type":"string"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":50}}],"responses":{"200":{"description":"Records and next_cursor"},"400":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"401":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"403":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"409":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"429":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"503":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}}}},"post":{"summary":"Create or replace a record (records:write)","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Record"}}}},"responses":{"200":{"description":"Updated record"},"201":{"description":"Created record"},"400":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"401":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"403":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"409":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"429":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"503":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}}}},"delete":{"summary":"Delete a record (records:write)","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["id","version"],"properties":{"id":{"type":"string"},"version":{"type":"integer","minimum":1}}}}}},"responses":{"204":{"description":"Deleted"},"400":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"401":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"403":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"409":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"429":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"503":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}}}}},"/enquiries":{"post":{"summary":"Create a contact, deal and follow-up (enquiries:write)","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","pattern":"^[a-zA-Z0-9_-]{8,128}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Enquiry"}}}},"responses":{"201":{"description":"Contact, deal and task IDs; retries return the same IDs"},"400":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"401":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"403":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"409":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"429":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}},"503":{"description":"Request rejected","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"integer"}}}}}}}}}}}}}