{"openapi":"3.1.0","info":{"title":"Cerclen API","description":"Deals, their requests, answers and files, for your tools and AI agents. Authenticate with `Authorization: Bearer <key>`, a key from your organization's API Keys page in Cerclen: it acts as you, within its limits. About 600 calls a minute per key; past that, 429 with Retry-After.","version":"1"},"servers":[{"url":"https://app.cerclen.com"}],"paths":{"/api/v1/me":{"get":{"tags":["Account"],"summary":"Who the key acts as","description":"Who the key acts as, its organization, and the key itself.","operationId":"getMe","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Me"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Content","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"ApiKey":[]}]}},"/api/v1/deals":{"get":{"tags":["Deals"],"summary":"List deals","description":"The deals the key reaches: its owner's, or the ones the key is limited to. An\narchived deal is listed only for its project admins.","operationId":"listDeals","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Deal"},"type":"array","title":"Response Listdeals"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"409":{"description":"Conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Content","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"security":[{"ApiKey":[]}]}},"/api/v1/deals/{deal_id}":{"get":{"tags":["Deals"],"summary":"Get a deal","operationId":"getDeal","security":[{"ApiKey":[]}],"parameters":[{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealDetail"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}},"/api/v1/deals/{deal_id}/people":{"get":{"tags":["Deals"],"summary":"List a deal's people","description":"Everyone on the deal, both sides.","operationId":"listPeople","security":[{"ApiKey":[]}],"parameters":[{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Person"},"title":"Response Listpeople"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}},"/api/v1/deals/{deal_id}/requests":{"get":{"tags":["Requests"],"summary":"List requests","description":"The whole list, sections and requests, in its order.","operationId":"listRequests","security":[{"ApiKey":[]}],"parameters":[{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DealRequest"},"title":"Response Listrequests"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}},"post":{"tags":["Requests"],"summary":"Create a request","description":"The owning side's admins and editors raise requests. 403 `cannot_create_request`.","operationId":"createRequest","security":[{"ApiKey":[]}],"parameters":[{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealRequestCreate"},"examples":{"request":{"summary":"A request","value":{"title":"Audited financial statements, last three years","body":"Including the auditor's management letters.","number":"3.2","priority":"high","category":"accounting","due_date":"2026-11-30"}},"section":{"summary":"A section","value":{"title":"Financial information","kind":"section","number":"3"}}}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealRequest"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}},"/api/v1/deals/{deal_id}/requests/{request_id}":{"get":{"tags":["Requests"],"summary":"Get a request","operationId":"getRequest","security":[{"ApiKey":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealRequest"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}},"patch":{"tags":["Requests"],"summary":"Update a request","description":"Edit, assign, and move the status, in one call or apart. Editing is the owning\nside's admins' and editors'; the status, anyone's on the deal but a viewer. 403\n`cannot_edit_request` / `cannot_transition`; 409 when the status can't go there.","operationId":"updateRequest","security":[{"ApiKey":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealRequestUpdate"},"examples":{"status":{"summary":"Move the status","value":{"status":"complete"}},"assign":{"summary":"Assign, with a due date","value":{"assignee_id":"01a1d6c0-5f4e-7c1b-9a2d-3e4f5a6b7c8d","due_date":"2026-11-30"}}}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DealRequest"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}},"/api/v1/deals/{deal_id}/requests/{request_id}/messages":{"get":{"tags":["Conversations"],"summary":"List a request's messages","description":"The request's conversation as the key's owner sees it, oldest first.","operationId":"listMessages","security":[{"ApiKey":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Message"},"title":"Response Listmessages"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}},"post":{"tags":["Conversations"],"summary":"Post a message","description":"An answer, a question, a reference or an internal note, in Markdown, with links.\nMarked \"via API\" for everyone who sees it. 403 `cannot_post`; 400 `empty_message`.","operationId":"postMessage","security":[{"ApiKey":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Request Id"}},{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageCreate"},"examples":{"answer":{"summary":"An answer with a link","value":{"text":"The FY2025 audited accounts are in the data room.","links":[{"url":"https://dataroom.example.com/f/123","label":"FY2025 audit"}]}},"partial":{"summary":"A partial answer","value":{"text":"FY2023 and FY2024 attached; FY2025 follows on signing.","partial":true}},"note":{"summary":"A note for your side","value":{"text":"Draft: check the figures before we send.","kind":"internal_note"}}}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Message"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}},"/api/v1/deals/{deal_id}/files/{version_id}/download-link":{"post":{"tags":["Files"],"summary":"Get a download link","description":"A short-lived link to a file's bytes. Read keys may ask for one too.","operationId":"createDownloadLink","security":[{"ApiKey":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"deal_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deal Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DownloadLink"}}}},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"403":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Forbidden"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"422":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unprocessable Content"},"500":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Internal Server Error"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"}}}}},"components":{"schemas":{"Access":{"type":"string","enum":["admin","editor","viewer"],"title":"Access","description":"What a person may do on their side of a deal (ADR-0044). Admins also manage their\nside's people; editors work the requests; viewers only look."},"AnswerPreview":{"properties":{"message_id":{"type":"string","title":"Message Id"},"preview":{"type":"string","title":"Preview"},"partial":{"type":"boolean","title":"Partial"},"source":{"$ref":"#/components/schemas/MessageSource"},"author":{"anyOf":[{"$ref":"#/components/schemas/Author"},{"type":"null"}]},"posted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Posted At"}},"type":"object","required":["message_id","preview","partial","source","author","posted_at"],"title":"AnswerPreview","description":"The newest answer to a request, shortened."},"ApiKeyAccess":{"type":"string","enum":["read","write"],"title":"ApiKeyAccess","description":"What an API key may do, within its owner's access (ADR-0050)."},"Author":{"properties":{"id":{"type":"string","title":"Id","description":"Their person id on the deal."},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"type":"string","title":"Email"}},"type":"object","required":["id","name","email"],"title":"Author"},"BodyFormat":{"type":"string","enum":["text","markdown"],"title":"BodyFormat","description":"How `messages.body_text` is meant to be read: an email's stripped reply as plain\ntext, or a web-authored answer as Markdown — rendered by the SPA with raw HTML off,\nso no server-supplied markup ever reaches the browser."},"Deal":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name","description":"The project name, such as Project Kestrel."},"codename":{"type":"string","title":"Codename"},"timezone":{"type":"string","title":"Timezone","description":"The IANA time zone its due dates fall due in."},"archived":{"type":"boolean","title":"Archived","description":"Archived deals are read-only, and listed only for their project admins."},"parties":{"items":{"$ref":"#/components/schemas/Party"},"type":"array","title":"Parties"}},"type":"object","required":["id","name","codename","timezone","archived","parties"],"title":"Deal"},"DealDetail":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name","description":"The project name, such as Project Kestrel."},"codename":{"type":"string","title":"Codename"},"timezone":{"type":"string","title":"Timezone","description":"The IANA time zone its due dates fall due in."},"archived":{"type":"boolean","title":"Archived","description":"Archived deals are read-only, and listed only for their project admins."},"parties":{"items":{"$ref":"#/components/schemas/Party"},"type":"array","title":"Parties"},"me":{"$ref":"#/components/schemas/Seat"}},"type":"object","required":["id","name","codename","timezone","archived","parties","me"],"title":"DealDetail"},"DealRequest":{"properties":{"id":{"type":"string","title":"Id"},"parent_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Id","description":"The section it sits under; null at the top level."},"kind":{"$ref":"#/components/schemas/RequestKind"},"number":{"type":"string","title":"Number","description":"Its number on the list, such as 3.2."},"title":{"type":"string","title":"Title"},"body":{"type":"string","title":"Body","description":"The request in full, in Markdown."},"status":{"$ref":"#/components/schemas/RequestStatus"},"allowed_statuses":{"items":{"$ref":"#/components/schemas/RequestStatus"},"type":"array","title":"Allowed Statuses","description":"The statuses you may move it to from here."},"priority":{"$ref":"#/components/schemas/Priority"},"category":{"$ref":"#/components/schemas/RequestCategory"},"requester":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requester","description":"The advisor firm raising it; null for the Financial Sponsor."},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date","description":"A calendar day in the deal's time zone."},"assignee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assignee Id","description":"The person id of whoever is to answer it."},"status_changed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Status Changed At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"latest_answer":{"anyOf":[{"$ref":"#/components/schemas/AnswerPreview"},{"type":"null"}]},"files":{"items":{"$ref":"#/components/schemas/File"},"type":"array","title":"Files","description":"Every file and link given in answer to it."},"can":{"$ref":"#/components/schemas/RequestCan"}},"type":"object","required":["id","parent_id","kind","number","title","body","status","allowed_statuses","priority","category","requester","due_date","assignee_id","status_changed_at","created_at","updated_at","latest_answer","files","can"],"title":"DealRequest","description":"A request on the deal's list. A `section` is a heading over requests: it has no\nstatus, assignee or answers of its own."},"DealRequestCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"pattern":"\\S","title":"Title"},"body":{"type":"string","maxLength":20000,"title":"Body","description":"The request in full, in Markdown.","default":""},"number":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"pattern":"^\\S(.*\\S)?$"},{"type":"null"}],"title":"Number","description":"Its number on the list. Omitted: the next number under its parent."},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id","description":"The section to put it under."},"kind":{"$ref":"#/components/schemas/RequestKind","default":"request"},"priority":{"$ref":"#/components/schemas/Priority","default":"medium"},"category":{"$ref":"#/components/schemas/RequestCategory","default":"business"},"requester":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Requester","description":"The advisor firm raising it; null for the Financial Sponsor."},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"assignee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assignee Id","description":"A person id from the deal's people."}},"type":"object","required":["title"],"title":"DealRequestCreate","description":"A new request (or section). Raised by the owning side's admins and editors."},"DealRequestUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1,"pattern":"\\S"},{"type":"null"}],"title":"Title"},"body":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}],"title":"Body"},"number":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"pattern":"^\\S(.*\\S)?$"},{"type":"null"}],"title":"Number","description":"Its number on the list. Omitted: the next number under its parent."},"priority":{"anyOf":[{"$ref":"#/components/schemas/Priority"},{"type":"null"}]},"category":{"anyOf":[{"$ref":"#/components/schemas/RequestCategory"},{"type":"null"}]},"requester":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Requester"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"assignee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assignee Id"},"status":{"anyOf":[{"$ref":"#/components/schemas/RequestStatus"},{"type":"null"}],"description":"One of the request's `allowed_statuses`."}},"type":"object","title":"DealRequestUpdate","description":"Only the fields you send change; `null` clears `requester`, `due_date` and\n`assignee_id`. Editing is the owning side's admins' and editors'; moving the status,\nanyone's on the deal but a viewer."},"DownloadLink":{"properties":{"url":{"type":"string","title":"Url","description":"Fetch it soon, without your key: it expires."},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"filename":{"type":"string","title":"Filename"},"size":{"type":"integer","title":"Size"},"content_type":{"type":"string","title":"Content Type"}},"type":"object","required":["url","expires_at","filename","size","content_type"],"title":"DownloadLink"},"ErrorCode":{"type":"string","enum":["bad_request","validation_failed","unauthenticated","forbidden","not_found","method_not_allowed","conflict","conflict_stale","rate_limited","payload_too_large","internal"],"title":"ErrorCode"},"ErrorResponse":{"properties":{"code":{"$ref":"#/components/schemas/ErrorCode"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/FieldError"},"type":"array"},{"type":"null"}],"title":"Fields"}},"type":"object","required":["code"],"title":"ErrorResponse"},"FieldError":{"properties":{"path":{"type":"string","title":"Path"},"code":{"type":"string","title":"Code"},"params":{"additionalProperties":true,"type":"object","title":"Params"}},"type":"object","required":["path","code"],"title":"FieldError"},"File":{"properties":{"version_id":{"type":"string","title":"Version Id","description":"What a download link is asked for with."},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"The file name or link label; null while it is withheld from you."},"kind":{"type":"string","enum":["file","link"],"title":"Kind"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url","description":"A link's target; never set for a file."},"size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size","description":"Bytes, for a file."},"content_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content Type"},"downloadable":{"type":"boolean","title":"Downloadable","description":"A download link can be issued now (a file scanned and confirmed)."}},"type":"object","required":["version_id","name","kind","url","downloadable"],"title":"File","description":"A file or a link given with an answer. A file's bytes come from its download link."},"Key":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"prefix":{"type":"string","title":"Prefix","description":"The first characters of the secret, as the API Keys page shows them."},"access":{"$ref":"#/components/schemas/ApiKeyAccess","description":"`read`: GET calls and download links only. `write`: everything."},"deal_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Deal Ids","description":"The deals it is limited to; null for every deal you are on."},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"type":"object","required":["id","name","prefix","access","deal_ids","expires_at"],"title":"Key","description":"The key itself. Its secret is never shown again."},"Link":{"properties":{"url":{"type":"string","maxLength":2048,"title":"Url"},"label":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Label"}},"type":"object","required":["url"],"title":"Link","description":"An https link to a document elsewhere: a data room, a drive."},"Me":{"properties":{"user":{"$ref":"#/components/schemas/User"},"organization":{"$ref":"#/components/schemas/Organization"},"key":{"$ref":"#/components/schemas/Key"}},"type":"object","required":["user","organization","key"],"title":"Me","description":"Who the key acts as."},"Message":{"properties":{"id":{"type":"string","title":"Id"},"kind":{"$ref":"#/components/schemas/MessageKind"},"partial":{"type":"boolean","title":"Partial","description":"A partial answer: more is to come."},"internal":{"type":"boolean","title":"Internal","description":"Seen by its author's side only."},"source":{"$ref":"#/components/schemas/MessageSource","description":"Where it came from: `web`, `email`, `import` or `api`."},"text":{"type":"string","title":"Text"},"format":{"$ref":"#/components/schemas/BodyFormat","description":"`markdown`, or `plain` for an emailed reply."},"posted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Posted At"},"author":{"anyOf":[{"$ref":"#/components/schemas/Author"},{"type":"null"}]},"on_behalf":{"type":"boolean","title":"On Behalf","description":"Confirmed by a colleague for the person who emailed it."},"files":{"items":{"$ref":"#/components/schemas/File"},"type":"array","title":"Files"}},"type":"object","required":["id","kind","partial","internal","source","text","format","posted_at","author","on_behalf","files"],"title":"Message","description":"An answer, a question, a reference or a note in a request's conversation."},"MessageCreate":{"properties":{"text":{"type":"string","maxLength":20000,"title":"Text","description":"In Markdown.","default":""},"kind":{"$ref":"#/components/schemas/MessageKind","default":"response"},"partial":{"type":"boolean","title":"Partial","description":"Answers the request in part; it moves to `partial`.","default":false},"internal":{"type":"boolean","title":"Internal","description":"Keep it to your side, such as a draft for a colleague to check; an `internal_note` is kept to your side anyway. Only the side that runs the list keeps anything to itself: everything the other side posts is shared.","default":false},"update_status":{"type":"boolean","title":"Update Status","description":"A response moves the request to `partial` or `complete`; false leaves it.","default":true},"links":{"items":{"$ref":"#/components/schemas/Link"},"type":"array","maxItems":20,"title":"Links"}},"type":"object","title":"MessageCreate"},"MessageKind":{"type":"string","enum":["response","question","reference","internal_note"],"title":"MessageKind","description":"Drives triage and the UI, never the status machine (ADR-0003)."},"MessageSource":{"type":"string","enum":["email","web","import","api"],"title":"MessageSource","description":"Where content came from: an email confirmed on the web, the web itself, a\nspreadsheet an owning-party member imported (shown as imported, never as the words\nof whoever the sheet quotes), or the external API — a person's key, marked \"via API\"\nfor both sides (ADR-0050)."},"Organization":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"Organization","description":"The registered organization the key was made in."},"ParticipantRole":{"type":"string","enum":["principal","counsel","banker","advisor","other"],"title":"ParticipantRole"},"Party":{"properties":{"id":{"type":"string","title":"Id"},"side":{"$ref":"#/components/schemas/Side"},"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label","description":"The side's name; null for a Financial Sponsor not known yet."},"is_owner":{"type":"boolean","title":"Is Owner","description":"The side that runs the request list: it raises and edits requests."}},"type":"object","required":["id","side","label","is_owner"],"title":"Party","description":"A side of the deal: `buy` is the Financial Sponsor, `sell` the Target."},"Person":{"properties":{"id":{"type":"string","title":"Id","description":"Their person id on the deal: what a request's `assignee_id` names."},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"type":"string","title":"Email"},"party_id":{"type":"string","title":"Party Id","description":"Their side."},"access":{"$ref":"#/components/schemas/Access"},"role":{"$ref":"#/components/schemas/ParticipantRole"},"is_project_admin":{"type":"boolean","title":"Is Project Admin"},"joined":{"type":"boolean","title":"Joined","description":"Has accepted their invitation."}},"type":"object","required":["id","name","email","party_id","access","role","is_project_admin","joined"],"title":"Person","description":"Someone on the deal."},"Priority":{"type":"string","enum":["low","medium","high"],"title":"Priority","description":"A request's urgency. Ordering for display is client-side (never `ORDER BY`)."},"RequestCan":{"properties":{"edit":{"type":"boolean","title":"Edit","description":"Change its title, body, number, priority, category or requester."},"assign":{"type":"boolean","title":"Assign","description":"Change its assignee and due date."},"change_status":{"type":"boolean","title":"Change Status"},"answer":{"type":"boolean","title":"Answer","description":"Post an answer, a question, a reference or an internal note."}},"type":"object","required":["edit","assign","change_status","answer"],"title":"RequestCan","description":"What you may do to this request."},"RequestCategory":{"type":"string","enum":["business","legal","tax","accounting","technology","human_resources"],"title":"RequestCategory","description":"The DRL's workstreams (ADR-0031). Shown with the firm raising the request —\n\"Legal - Kirkland & Ellis\" — or \"Financial Sponsor\" when none is named."},"RequestKind":{"type":"string","enum":["request","section"],"title":"RequestKind","description":"A row of the list (ADR-0017): a request, or a section heading that groups the\nrequests under it — a number and a title, never a status, an assignee or an answer."},"RequestStatus":{"type":"string","enum":["open","partial","complete"],"title":"RequestStatus"},"Seat":{"properties":{"participant_id":{"type":"string","title":"Participant Id","description":"Your person id on the deal."},"party_id":{"type":"string","title":"Party Id"},"access":{"$ref":"#/components/schemas/Access","description":"What you may do on your side: `admin`, `editor` or `viewer`."},"is_project_admin":{"type":"boolean","title":"Is Project Admin"}},"type":"object","required":["participant_id","party_id","access","is_project_admin"],"title":"Seat","description":"Your place on the deal."},"Side":{"type":"string","enum":["buy","sell"],"title":"Side","description":"Which side of the transaction a party is on: `buy` is the Financial Sponsor, `sell`\nthe Target (ADR-0039). Visibility never keys on this — it keys on owner vs\ncounterparty (ADR-0023)."},"User":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","required":["id","name","email"],"title":"User","description":"The person the key acts as."}},"securitySchemes":{"ApiKey":{"type":"http","description":"An API key from your organization's API Keys page in Cerclen.","scheme":"bearer","bearerFormat":"ck_…"}}}}