{"openapi":"3.1.0","info":{"title":"Sabai System API","version":"1.0.0","description":"Search and open everything the signed-in person may read: tasks, documents, decisions, meetings, emails, code, people and companies. The same operations as the MCP server's search and fetch tools, with the same access: a token acts as the person who signed in. Each object also has its own routes, generated from its entry: a list, and one row by id where rows have one, giving only the rows and columns the person may read; a live object's list and one item (emails, meetings) are read from its source, as a search reads them. Errors are problem details (RFC 9457). It lists the routes a person at a client may call."},"servers":[{"url":"https://api.sabaisystem.com"}],"security":[{"oauth":["mcp:read"]}],"paths":{"/v1/search":{"get":{"operationId":"search","summary":"Search everything the person may read, by kind","description":"Results come by kind, each kind at most `limit` per page. An item that is several kinds lists them all; a document kept in several places lists every place.","parameters":[{"name":"q","in":"query","required":true,"description":"A few words.","schema":{"type":"string","minLength":2,"maxLength":200}},{"name":"kinds","in":"query","description":"Only these kinds, comma-separated.","schema":{"type":"string","example":"documents,meetings"}},{"name":"where","in":"query","description":"Only these places, comma-separated: linear, drive, meetings, email (the emails the person is on), slack (the Slack messages a person at Sabai can read, once they connected Slack), discord (the messages of Sabai's Discord server a person at Sabai may read; never a client's), repository, database, docs (the documentation's pages). Every other source is not asked.","schema":{"type":"string","example":"drive"}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the one client searched, its teams, records and repository, by its short name (`sabai` for work that is no client's). A search answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}},{"name":"since","in":"query","description":"Only what changed or took place on or after this day. Places without dates are not asked.","schema":{"type":"string","format":"date"}},{"name":"until","in":"query","description":"Only what changed or took place on or before this day.","schema":{"type":"string","format":"date"}},{"name":"limit","in":"query","description":"Results per kind on a page.","schema":{"type":"integer","minimum":1,"maximum":20,"default":5}},{"name":"page","in":"query","description":"Which page, from 1.","schema":{"type":"integer","minimum":1,"maximum":4,"default":1}}],"responses":{"200":{"description":"The results.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchResults"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/items/{id}":{"get":{"operationId":"fetch","summary":"Open one result in full","parameters":[{"name":"id","in":"path","required":true,"description":"A result's id from search: task:…, document:…, meeting:…, event:…, email:…, slack:…, discord:…, file:…, repo:…, docs:…, company:…, company_document:…, person:…, project:…, mission:…, contract:…, invoice:…, subscription:…, bank_account:…, invoice_payment:…, intercompany_transfer:…, transaction:…, vendor:…, note:…, content_post:…, content_idea:…, tool:…, or folder:<path> for a repository folder.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the item must belong to (another client's answers 404; a repository's repo: and folder: ids open only with their client named), or `all` for any client they may read.","schema":{"type":"string"}}],"responses":{"200":{"description":"The item, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/bank_accounts":{"get":{"operationId":"list_bank_accounts","summary":"List bank accounts","description":"The bank accounts the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of bank accounts.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/BankAccounts"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/bank_accounts/{id}":{"get":{"operationId":"get_bank_accounts","summary":"Open one of the bank accounts","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the bank accounts.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BankAccounts"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/companies":{"get":{"operationId":"list_companies","summary":"List companies","description":"The companies the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of companies.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Companies"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/companies/{id}":{"get":{"operationId":"get_companies","summary":"Open one of the companies","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the companies.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Companies"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/company_documents":{"get":{"operationId":"list_company_documents","summary":"List company documents","description":"The company documents the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of company documents.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/CompanyDocuments"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/company_documents/{id}":{"get":{"operationId":"get_company_documents","summary":"Open one of the company documents","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the company documents.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyDocuments"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/company_portal_settings":{"get":{"operationId":"list_company_portal_settings","summary":"List company portal settings","description":"The company portal settings the signed-in person may read, 25 a page by default, ordered by the database. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of company portal settings.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/CompanyPortalSettings"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/consultant_missions":{"get":{"operationId":"list_consultant_missions","summary":"List consultant missions","description":"The consultant missions the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of consultant missions.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/ConsultantMissions"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/consultant_missions/{id}":{"get":{"operationId":"get_consultant_missions","summary":"Open one of the consultant missions","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the consultant missions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConsultantMissions"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/contracts":{"get":{"operationId":"list_contracts","summary":"List contracts","description":"The contracts the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of contracts.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Contracts"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/contracts/{id}":{"get":{"operationId":"get_contracts","summary":"Open one of the contracts","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the contracts.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Contracts"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/invoices":{"get":{"operationId":"list_invoices","summary":"List invoices","description":"The invoices the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of invoices.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Invoices"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/invoices/{id}":{"get":{"operationId":"get_invoices","summary":"Open one of the invoices","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the invoices.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Invoices"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/mission_projects":{"get":{"operationId":"list_mission_projects","summary":"List mission projects","description":"The mission projects the signed-in person may read, 25 a page by default, ordered by mission_id, project_id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of mission projects.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/MissionProjects"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/missions":{"get":{"operationId":"list_missions","summary":"List missions","description":"The missions the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of missions.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Missions"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/missions/{id}":{"get":{"operationId":"get_missions","summary":"Open one of the missions","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the missions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Missions"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/project_users":{"get":{"operationId":"list_project_users","summary":"List project users","description":"The project users the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of project users.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/ProjectUsers"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/project_users/{id}":{"get":{"operationId":"get_project_users","summary":"Open one of the project users","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the project users.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectUsers"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/projects":{"get":{"operationId":"list_projects","summary":"List projects","description":"The projects the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of projects.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Projects"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/projects/{id}":{"get":{"operationId":"get_projects","summary":"Open one of the projects","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","pattern":"^[0-9]+$","maxLength":100}}],"responses":{"200":{"description":"One of the projects.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Projects"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/subscriptions":{"get":{"operationId":"list_subscriptions","summary":"List subscriptions","description":"The subscriptions the signed-in person may read, 25 a page by default, ordered by id. A column only some readers may see is null for the others.","parameters":[{"name":"limit","in":"query","description":"Rows on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}}],"responses":{"200":{"description":"A page of subscriptions.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Subscriptions"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/subscriptions/{id}":{"get":{"operationId":"get_subscriptions","summary":"Open one of the subscriptions","parameters":[{"name":"id","in":"path","required":true,"description":"The row's id.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"One of the subscriptions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Subscriptions"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/deliverables":{"get":{"operationId":"list_deliverables","summary":"List deliverables","description":"The deliverables the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/deliverables/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the deliverables must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of deliverables.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/deliverables/{id}":{"get":{"operationId":"get_deliverables","summary":"Open one of the deliverables","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/deliverables gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the deliverables must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the deliverables, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/emails":{"get":{"operationId":"list_emails","summary":"List emails","description":"The emails the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/emails/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the emails must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of emails.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/emails/{id}":{"get":{"operationId":"get_emails","summary":"Open one of the emails","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/emails gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the emails must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the emails, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/engagement_documents":{"get":{"operationId":"list_engagement_documents","summary":"List engagement documents","description":"The engagement documents the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/engagement_documents/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the engagement documents must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of engagement documents.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/engagement_documents/{id}":{"get":{"operationId":"get_engagement_documents","summary":"Open one of the engagement documents","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/engagement_documents gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the engagement documents must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the engagement documents, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/features":{"get":{"operationId":"list_features","summary":"List features","description":"The features the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/features/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the features must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of features.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/features/{id}":{"get":{"operationId":"get_features","summary":"Open one of the features","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/features gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the features must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the features, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/linear_documents":{"get":{"operationId":"list_linear_documents","summary":"List linear documents","description":"The linear documents the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/linear_documents/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the linear documents must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of linear documents.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/linear_documents/{id}":{"get":{"operationId":"get_linear_documents","summary":"Open one of the linear documents","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/linear_documents gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the linear documents must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the linear documents, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/meetings":{"get":{"operationId":"list_meetings","summary":"List meetings","description":"The meetings the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/meetings/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the meetings must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of meetings.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/meetings/{id}":{"get":{"operationId":"get_meetings","summary":"Open one of the meetings","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/meetings gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the meetings must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the meetings, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/shared_files":{"get":{"operationId":"list_shared_files","summary":"List shared files","description":"The shared files the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/shared_files/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the shared files must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of shared files.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/shared_files/{id}":{"get":{"operationId":"get_shared_files","summary":"Open one of the shared files","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/shared_files gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the shared files must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the shared files, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/tasks":{"get":{"operationId":"list_tasks","summary":"List tasks","description":"The tasks the signed-in person may read, newest first where they have a date, 25 a page by default: read live from its source, through the same rules as a search. Each id is what /v1/tasks/{id} takes.","parameters":[{"name":"limit","in":"query","description":"Items on a page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"page","in":"query","description":"Which page, 1 to 100.","schema":{"type":"integer","minimum":1,"maximum":100,"default":1}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the tasks must be with, by its short name (`sabai` for work that is no client's). A list answers from one client, never a mix: `all` is refused here.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of tasks.","content":{"application/json":{"schema":{"type":"object","required":["items","page","next"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null on the last."}}}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"},"502":{"$ref":"#/components/responses/Problem"}}}},"/v1/tasks/{id}":{"get":{"operationId":"get_tasks","summary":"Open one of the tasks","parameters":[{"name":"id","in":"path","required":true,"description":"Its id, as /v1/tasks gives it. Another object's id, or one the person may not read, answers 404.","schema":{"type":"string","minLength":3,"maxLength":300}},{"name":"client","in":"query","description":"Staff only, and required of staff who may read several clients: the client the tasks must be with, by its short name (`sabai` for work that is no client's), or `all` for any client they may read; another client's answers 404.","schema":{"type":"string"}}],"responses":{"200":{"description":"One of the tasks, as Markdown.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Item"}}}},"400":{"$ref":"#/components/responses/Problem"},"401":{"$ref":"#/components/responses/Problem"},"403":{"$ref":"#/components/responses/Problem"},"404":{"$ref":"#/components/responses/Problem"},"429":{"$ref":"#/components/responses/Problem"}}}},"/v1/openapi.json":{"get":{"operationId":"openapi","summary":"This description","security":[],"responses":{"200":{"description":"The OpenAPI description.","content":{"application/json":{"schema":{"type":"object"}}}}}}}},"components":{"securitySchemes":{"oauth":{"type":"oauth2","description":"OAuth 2.1 with PKCE; clients register dynamically. Ask for the token without a resource, or with resource https://api.sabaisystem.com/v1: a token bound to the MCP is refused here.","flows":{"authorizationCode":{"authorizationUrl":"https://api.sabaisystem.com/authorize","tokenUrl":"https://api.sabaisystem.com/oauth/token","refreshUrl":"https://api.sabaisystem.com/oauth/token","scopes":{"mcp:read":"Read what the person may read"}}}}},"responses":{"Problem":{"description":"A problem (RFC 9457).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"schemas":{"Kind":{"type":"string","enum":["tasks","projects","documents","decisions","meetings","emails","messages","code","people","companies","billing","tools"]},"Place":{"type":"object","required":["id"],"properties":{"id":{"type":"string"},"url":{"type":"string","format":"uri"},"line":{"type":"integer"}}},"Result":{"type":"object","required":["id","kind","kinds","title","places"],"properties":{"id":{"type":"string","description":"What /v1/items/{id} takes; a deliverable's or a feature's, only its own route (/v1/deliverables/{id}, /v1/features/{id})."},"kind":{"$ref":"#/components/schemas/Kind"},"kinds":{"type":"array","items":{"$ref":"#/components/schemas/Kind"},"description":"Every kind it is, its main kind first."},"title":{"type":"string"},"excerpt":{"type":"string"},"url":{"type":"string","format":"uri"},"at":{"type":"string","description":"When it last changed or took place."},"public":{"type":"boolean","const":true,"description":"Product documentation that is no company's: a public page of the documentation, which may be quoted to anyone. Left out otherwise."},"places":{"type":"array","items":{"$ref":"#/components/schemas/Place"},"description":"Every place it lives, its own first."}}},"SearchResults":{"type":"object","required":["results","searched","failed","counts","total","page"],"properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/Result"}},"searched":{"type":"array","items":{"$ref":"#/components/schemas/Kind"}},"failed":{"type":"array","items":{"$ref":"#/components/schemas/Kind"},"description":"Kinds a source did not answer for in time: results of those kinds may be missing."},"counts":{"type":"object","additionalProperties":{"$ref":"#/components/schemas/Count"},"description":"How many matched in each kind searched: an item that is several kinds counts in each, a document in two sources once."},"total":{"$ref":"#/components/schemas/Count"},"page":{"type":"integer"},"next":{"type":["string","null"],"description":"The next page's address, or null."}}},"Count":{"type":"object","required":["matched","more"],"properties":{"matched":{"type":"integer","description":"How many matched, each item once."},"more":{"type":"boolean","description":"A source knows of more than it read."}}},"Item":{"type":"object","required":["id","kind","title","markdown"],"properties":{"id":{"type":"string"},"kind":{"oneOf":[{"$ref":"#/components/schemas/Kind"},{"type":"null"}]},"title":{"type":"string"},"markdown":{"type":"string"}}},"Problem":{"type":"object","required":["type","title","status"],"properties":{"type":{"type":"string"},"title":{"type":"string"},"status":{"type":"integer"},"detail":{"type":"string"}}},"BankAccounts":{"type":"object","properties":{"account_holder_name":{"type":["string","null"]},"account_number":{"type":["string","null"]},"bank_address":{"type":["string","null"]},"bank_branch":{"type":["string","null"]},"bank_code":{"type":["string","null"]},"bank_country":{"type":["string","null"]},"bank_name":{"type":["string","null"]},"bank_number":{"type":["string","null"]},"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"currency":{"type":["string","null"],"enum":["EUR","USD","THB","HKD",null]},"iban":{"type":["string","null"]},"id":{"type":["number","null"]},"note":{"type":["string","null"]},"status":{"type":["string","null"],"enum":["Submitted","Validated",null]},"swift_code":{"type":["string","null"]},"type":{"type":["string","null"],"enum":["Business","Personal",null]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"user_id":{"type":["number","null"]}}},"Companies":{"type":"object","properties":{"address_address":{"type":["string","null"]},"address_address_2":{"type":["string","null"]},"address_city":{"type":["string","null"]},"address_country":{"type":["string","null"]},"address_zipcode":{"type":["string","null"]},"bank_account_id":{"type":["number","null"]},"company_type":{"type":["string","null"],"enum":["Lead","Customer","Partner","Freelance","Demo","Vendor","SaaS","Accountant","Lawyer","Bank","Travel",null]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"id":{"type":["number","null"]},"is_demo":{"type":["boolean","null"]},"legal_name":{"type":["string","null"]},"name":{"type":["string","null"]},"organisation_id":{"type":["string","null"]},"payment_term_days":{"type":["number","null"]},"phone":{"type":["string","null"]},"registration_number":{"type":["string","null"]},"relationships":{"type":["array","null"],"items":{"type":"string"}},"tax_id":{"type":["string","null"]},"type":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"CompanyDocuments":{"type":"object","properties":{"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"doc_type":{"type":["string","null"]},"expiry_date":{"type":["string","null"]},"file_name":{"type":["string","null"]},"gdrive_file_id":{"type":["string","null"]},"id":{"type":["number","null"]},"issue_date":{"type":["string","null"]},"notes":{"type":["string","null"]},"period":{"type":["string","null"]},"title":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"CompanyPortalSettings":{"type":"object","properties":{"can_submit_requests":{"type":["boolean","null"]},"closed_at":{"type":["string","null"]},"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"display_name":{"type":["string","null"]},"expose_comments":{"type":["boolean","null"]},"github_repo":{"type":["string","null"]},"logo":{"type":["string","null"]},"slug":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"ConsultantMissions":{"type":"object","properties":{"consultant_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"end_date":{"type":["string","null"]},"id":{"type":["number","null"]},"mission_id":{"type":["number","null"]},"price":{"type":["number","null"]},"price_currency":{"type":["string","null"],"enum":["EUR","USD",null]},"price_unit":{"type":["string","null"],"enum":["hour","day",null]},"start_date":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"Contracts":{"type":"object","properties":{"buyer_company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"end_date":{"type":["string","null"]},"file_id":{"type":["string","null"]},"id":{"type":["number","null"]},"name":{"type":["string","null"]},"seller_company_id":{"type":["number","null"]},"start_date":{"type":["string","null"]},"type":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"Invoices":{"type":"object","properties":{"activity_report_id":{"type":["number","null"]},"amount":{"type":["number","null"]},"buyer_company_id":{"type":["number","null"]},"counterparty_name":{"type":["string","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"currency":{"type":["string","null"],"enum":["USD","EUR","HKD","CHF","THB","GBP","JPY","VND","MXN","SGD","AUD","CAD","CNY","INR","AED","MYR","IDR","PHP","KRW","NZD","SEK","NOK","DKK",null]},"date":{"type":["string","null"]},"description":{"type":["string","null"]},"file_id":{"type":["string","null"]},"gdrive_file_id":{"type":["string","null"]},"id":{"type":["number","null"]},"reference":{"type":["string","null"]},"seller_company_id":{"type":["number","null"]},"subscription_id":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"xero_connection_id":{"type":["number","null"]},"xero_id":{"type":["string","null"]},"state":{"type":["string","null"]},"balance":{"type":["number","null"]},"last_paid":{"type":["string","null"]},"other_currency_payments":{"type":["number","null"]}}},"MissionProjects":{"type":"object","properties":{"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"mission_id":{"type":["number","null"]},"project_id":{"type":["number","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"Missions":{"type":"object","properties":{"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"customer_id":{"type":["number","null"]},"end_date":{"type":["string","null"]},"id":{"type":["number","null"]},"name":{"type":["string","null"]},"start_date":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"ProjectUsers":{"type":"object","properties":{"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"id":{"type":["number","null"]},"project_id":{"type":["number","null"]},"role":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"user_id":{"type":["number","null"]},"state":{"type":["string","null"]}}},"Projects":{"type":"object","properties":{"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"drive_folder_id":{"type":["string","null"]},"granola_folder_id":{"type":["string","null"]},"id":{"type":["number","null"]},"linear_team_id":{"type":["string","null"]},"name":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"state":{"type":["string","null"]}}},"Subscriptions":{"type":"object","properties":{"account":{"type":["string","null"]},"auto_renew":{"type":["boolean","null"]},"billing_cycle":{"type":["string","null"]},"card_id":{"type":["string","null"]},"company_id":{"type":["number","null"]},"created_at":{"type":["string","null"]},"created_by":{"type":["string","null"]},"currency":{"type":["string","null"]},"drive_name_hint":{"type":["string","null"]},"email_from":{"type":["string","null"]},"ended_on":{"type":["string","null"]},"expected_amount":{"type":["number","null"]},"expected_day":{"type":["number","null"]},"id":{"type":["string","null"]},"name":{"type":["string","null"]},"notes":{"type":["string","null"]},"plan":{"type":["string","null"]},"renews_on":{"type":["string","null"]},"seats":{"type":["number","null"]},"source":{"type":["string","null"]},"source_id":{"type":["string","null"]},"started_on":{"type":["string","null"]},"tool_id":{"type":["string","null"]},"updated_at":{"type":["string","null"]},"updated_by":{"type":["string","null"]},"vendor_company_id":{"type":["number","null"]},"vendor_name":{"type":["string","null"]},"state":{"type":["string","null"]}}}}}}