{"openapi":"3.1.0","info":{"title":"GET /api/v1/notes","version":"1.0.0","description":"List notes for a business"},"servers":[{"url":"https://api.ondayzero.com","description":"Production"}],"paths":{"/api/v1/notes":{"get":{"tags":["notes"],"summary":"List notes for a business","description":"Retrieve all notes for the current business, ordered by pinned then most recently updated.","operationId":"list_notes_api_v1_notes_get","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-business-id","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Business-Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NoteListResponse"}}}},"401":{"description":"Unauthorized - Authentication required","content":{"application/json":{"example":{"detail":"Not authenticated"}}}},"403":{"description":"Forbidden - Insufficient permissions","content":{"application/json":{"example":{"detail":"Not enough permissions"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AttachmentResponse":{"properties":{"id":{"type":"string","title":"Id"},"note_id":{"type":"string","title":"Note Id"},"file_name":{"type":"string","title":"File Name"},"file_size":{"type":"integer","title":"File Size"},"mime_type":{"type":"string","title":"Mime Type"},"uploaded_by":{"type":"string","title":"Uploaded By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","note_id","file_name","file_size","mime_type","uploaded_by","created_at"],"title":"AttachmentResponse","description":"A file attachment for a note."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"NoteListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/NoteResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total","default":0}},"type":"object","title":"NoteListResponse","description":"List of notes for a business."},"NoteResponse":{"properties":{"id":{"type":"string","title":"Id"},"title":{"type":"string","title":"Title"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"pinned":{"type":"boolean","title":"Pinned","default":false},"author_id":{"type":"string","title":"Author Id"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"author_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Email"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"attachments":{"items":{"$ref":"#/components/schemas/AttachmentResponse"},"type":"array","title":"Attachments"}},"type":"object","required":["id","title","author_id","created_at","updated_at"],"title":"NoteResponse","description":"Single note returned from the API."},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API Token","description":"API token authentication. Format: `Bearer dz_...`"}}},"security":[{"BearerAuth":[]}]}