{"openapi":"3.1.0","info":{"title":"SelfManager API","version":"1.0.0","description":"Read and change your SelfManager tables from your own scripts and automations.\n\n**Keys.** Make a personal API key in SelfManager, under My Profile, Connected apps, and send it with every request as `Authorization: Bearer <key>`. A key acts as you, with the permissions you gave it: `read` (read your tables, tasks, notes and comments); `write` (create tables and tasks, and change them); `shared` (add tasks, comments and notes in tables other people can see, and set deadlines there); `journal` (read your journal, and add to it with `write`). Keep it out of web pages and apps other people run: the API sends no CORS headers.\n\n**Ids.** A table is addressed by the `table_id` every answer gives it: `/v1/tables/` followed by that id. URL-encode each part.\n\n**Answers** are JSON. A range of days, totals, the journal, a search and most lists answer a page at a time, and a range can be any length, years too: an answer with a `cursor` has more, so send the same request with that `cursor` for the next page. Other lists are bounded: what didn't fit is left out, and the answer says `truncated: true` with a `hint`. Text that people wrote (names, notes, comments) is plain text.\n\n**Changes** take their values as one JSON object in the body, sent as `application/json`, at most 1 MiB. What a change writes is what SelfManager itself would write, and the table's log says it came through the API.\n\n**Retries.** Send an `Idempotency-Key` header of your choosing (up to 200 characters) with a request that changes something. Sent again with the same key after the first has finished, the same request answers what it answered first and changes nothing twice. A first attempt that failed before it changed anything is forgotten, so sending it again runs it. A key is remembered for 24 hours, for the API key it came with and the kind of change (a table's two addresses are one kind). The same key with a different request is a `409`, and so is one sent while the first is still running.\n\n**Limits.** 120 requests a minute for an account, refused requests included, and within them, a minute: 10 searches; 10 requests that make or change many tables at once (making several tables, copying, moving or deleting a table, editing a repeating table, resetting a table's task times, opening a day); 20 deletes of one thing; 20 downloads; 30 docs read. Also 10,000 requests a day (UTC), and 8 at once. Past them the answer is `429` with `Retry-After`: the seconds to wait, until midnight UTC for the day's, 5 for too many at once. Each of SelfManager's servers counts on its own, so under load a burst may get further before a `429`: don't count on it.\n\n**Prices,** while Integration Credits are charged: Reading a day, a table or a list, ticking or editing tasks, pinning tables, editing a repeating table, opening a day's repeating tables, deleting, and reading a recording's transcript or a doc's text are free. Reading several days, which days have tables, or totals, searching, downloading a file, copying or moving a table (once it is done), and adding tables, repeating tables, tasks, comments, notes or a conversation saved to AI History, or adding to or rewriting a journal line, use 1 Integration Credit a request (each page of a long range is one). Tasks use 1 Integration Credit for every 25 added or part of 25, a new table's first 25 included, and making many tables at once 1 Integration Credit for every 10 tables or part of 10. Weekly credits reset on Monday (UTC). Each endpoint below says its own.\n\n**Errors** are `{\"error\": {\"code\", \"message\"}}`; the message is written for a person. Every answer the API gives has an `X-Request-Id` header. A request that can't be taken at all (a body larger than 1 MiB, a compressed body, a path whose `%` doesn't begin a UTF-8 character) can be turned away before it reaches the API, with a plain-text `400`, `413` or `415` and neither.\n\n| Status | `code` | When |\n|---|---|---|\n| 400 | `invalid_request` | A parameter is missing, wrong or unknown, or the address isn't well formed. |\n| 401 | `unauthorized` | No key was sent, or it has expired, was revoked, or its account is gone. |\n| 402 | `insufficient_credits` | Requests use Integration Credits, and fewer are left than this one costs. |\n| 403 | `forbidden` | SelfManager's access rules refused it, or it is a change the API doesn't make (such as renaming a task in a table other people can see). |\n| 403 | `insufficient_scope` | The key lacks a permission the request needs. |\n| 403 | `not_in_beta` | The API, or its webhooks, are in a private beta that doesn't include this account yet. |\n| 403 | `plan_inactive` | The account has no active plan. |\n| 403 | `viewer_role` | You are a viewer on that table, so you can't change it. |\n| 403 | `writes_off` | Changes through the API aren't switched on. |\n| 404 | `not_found` | No such table, task, file or webhook, or you can't see it; or no such endpoint. |\n| 405 | `method_not_allowed` | The endpoint doesn't take that method. `Allow` lists those it takes. |\n| 409 | `conflict` | That Idempotency-Key was used before, with another request. |\n| 409 | `request_in_progress` | The request with that Idempotency-Key is still running. |\n| 413 | `too_large` | The body is larger than 1 MiB; usually turned away before it reaches the API, as plain text. |\n| 415 | `unsupported_media_type` | The body isn't sent as `application/json`. |\n| 422 | `cannot_apply` | The request is fine, but the data's state prevents it. |\n| 429 | `rate_limited` | Too many requests in a minute or in a day, or the credits left are held by requests still running or webhook events still being sent. `Retry-After` says how long to wait. |\n| 500 | `server_error` | Something failed on SelfManager's side. Quote `request_id` when you report it. |\n| 503 | `unavailable` | The API, or its webhooks, are switched off. |\n| 504 | `timed_out` | A change stopped before it could run out of time. Nothing was half written: a request that makes many tables made some of them whole, and says how many. Send it again with the same `Idempotency-Key` to make the rest. |"},"servers":[{"url":"https://api.selfmanager.ai"}],"security":[{"apiKey":[]}],"paths":{"/v1/me":{"get":{"operationId":"get_account","summary":"Your SelfManager account","description":"Whose key this is: display name, plan, today's date and the timezone used, what the key may do, and the Integration Credits its requests spend. When requests use them, it also says how many are left.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["scopes","connection"],"properties":{"display_name":{"type":"string"},"plan":{"type":"string","enum":["Individual","Team","Trial","Team credits"]},"today":{"type":"string","description":"Today's date in your timezone, as YYYY-MM-DD. Absent when the timezone isn't known."},"timezone":{"type":"string","description":"The IANA timezone in use. Absent when none is known."},"timezone_note":{"type":"string"},"scopes":{"type":"array","items":{"type":"string","enum":["read","write","shared","delete","journal","media","docs","webhooks"]},"description":"What this connection may do."},"connection":{"type":"string","enum":["assistant","personal_api_key"]},"ai_credits_left":{"type":"integer","description":"Only while requests use AI credits, which the API's no longer do: see integration_credits_left."},"ai_credits_note":{"type":"string"},"credits":{"type":"object","required":["weekly_left","weekly_allowance","used_this_week","purchased","total","renews_on","pool"],"properties":{"weekly_left":{"type":"integer","description":"This week's AI credits left."},"weekly_allowance":{"type":"integer","description":"The plan's AI credits each week."},"used_this_week":{"type":"integer","description":"Weekly AI credits used this week."},"purchased":{"type":"integer","description":"Bought AI credits left. They never expire."},"total":{"type":"integer","description":"All AI credits left: weekly, then purchased."},"renews_on":{"type":"string","description":"The Monday (UTC) the weekly AI credits renew, as YYYY-MM-DD."},"pool":{"type":"string","enum":["yours","team_owner"],"description":"Your own credits, or a Team owner's you spend."}},"description":"Your AI credits, which SelfManager's AI features and AI assistants spend; the API's requests spend Integration Credits. Absent when they can't be read, or there are none to spend."},"integration_credits_left":{"type":"integer","description":"Only while requests use Integration Credits."},"integration_credits_note":{"type":"string"},"integration_credits":{"type":"object","required":["weekly_left","weekly_allowance","used_this_week","purchased","total","renews_on","pool"],"properties":{"weekly_left":{"type":"integer","description":"This week's Integration Credits left."},"weekly_allowance":{"type":"integer","description":"The plan's Integration Credits each week."},"used_this_week":{"type":"integer","description":"Weekly Integration Credits used this week."},"purchased":{"type":"integer","description":"Bought Integration Credits left. They never expire."},"total":{"type":"integer","description":"All Integration Credits left: weekly, then purchased."},"renews_on":{"type":"string","description":"The Monday (UTC) the weekly Integration Credits renew, as YYYY-MM-DD."},"pool":{"type":"string","enum":["yours","team_owner"],"description":"Your own credits, or a Team owner's you spend."}},"description":"The credits the API's requests spend. Absent when they can't be read, or there are none to spend."},"storage":{"type":"object","required":["used_bytes","allowance_bytes","used_percent","used"],"properties":{"used_bytes":{"type":"integer","description":"What your own docs take, in bytes."},"allowance_bytes":{"type":["integer","null"],"description":"What you may hold in docs, in bytes: your plan's, plus any extra space bought; null without a plan."},"used_percent":{"type":"integer","description":"The share used, 0 to 100."},"used":{"type":"string","description":"In words, as the app's meter says it: \"1.2 GB of 5 GB used\"."}},"description":"Your docs storage. What you add to someone else's table counts on its owner, not here. Absent when it can't be read."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/days":{"get":{"operationId":"get_days","summary":"Tables over several days","description":"Tables over a range of any length (years too), by day, with progress and tracked time, a page at a time: when the answer has a cursor, ask again with the same arguments and that cursor for the next page. Days with no tables are left out. Set detail to tasks for their tasks too. Repeating tables that haven't been created yet appear with planned: true. For totals over a long range, `GET /v1/totals` is shorter.\n\nA key needs: `read`. Price: 1 Integration Credit.","x-permissions":["read"],"parameters":[{"name":"start_date","in":"query","required":true,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"end_date","in":"query","required":true,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"scope","in":"query","required":false,"description":"Whose tables: all (default), only yours, or only those shared with you.","schema":{"type":"string","enum":["all","mine","shared"]}},{"name":"detail","in":"query","required":false,"description":"summary (default): tables only; tasks: their tasks too; full: their tasks with every field (when each was created and started, and by whom).","schema":{"type":"string","enum":["summary","tasks","full"]}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave, with the same other arguments: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":20}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["start_date","end_date","days","truncated"],"properties":{"start_date":{"type":"string"},"end_date":{"type":"string"},"days":{"type":"array","items":{"type":"object","required":["date","tables"],"properties":{"date":{"type":"string"},"tables":{"type":"array","items":{"type":"object","required":["table_id","name","date"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}}}}}}}},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"today":{"type":["string","null"],"description":"Today's date in that timezone, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"cursor":{"type":"string","description":"Present when there is more: ask again with the same arguments and this cursor for the next page. Absent on the last page."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/totals":{"get":{"operationId":"get_totals","summary":"Totals over a range","description":"Totals over a range of any length (years too), per week or month: tables, tasks, completed tasks, completion and tracked time, also by table name. Every task counts as in `GET /v1/days`; repeating tables not created yet don't. Weeks or months with no tables are left out. A page at a time: when the answer has a cursor, ask again with the same arguments and that cursor. A period marked partial is split across pages: add up the parts with the same start.\n\nA key needs: `read`. Price: 1 Integration Credit.","x-permissions":["read"],"parameters":[{"name":"start_date","in":"query","required":true,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"end_date","in":"query","required":true,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"scope","in":"query","required":false,"description":"Whose tables: all (default), only yours, or only those shared with you.","schema":{"type":"string","enum":["all","mine","shared"]}},{"name":"group_by","in":"query","required":false,"description":"week (Monday to Sunday) or month (the default).","schema":{"type":"string","enum":["week","month"]}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave, with the same other arguments: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":20}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["start_date","end_date","group_by","periods","truncated"],"properties":{"start_date":{"type":"string"},"end_date":{"type":"string"},"group_by":{"type":"string","enum":["week","month"]},"periods":{"type":"array","items":{"type":"object","required":["start","end","tables","task_count","completed_count","completion_percent","by_name"],"properties":{"start":{"type":"string","description":"The period's first day in the range, as YYYY-MM-DD."},"end":{"type":"string","description":"Its last day in the range."},"tables":{"type":"integer"},"too_big_tables":{"type":"integer","description":"Of them, tables with more than 1,000 tasks: too many to read here, so their tasks aren't in these counts."},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"completion_percent":{"type":"integer","description":"Progress of the tasks that count (canceled ones don't), by the same weights as a table's."},"tracked_minutes":{"type":"integer","description":"Where a table counts time: one that tracks time, or one with tasks timed one by one."},"by_name":{"type":"array","items":{"type":"object","required":["name","tables"],"properties":{"name":{"type":"string"},"tables":{"type":"integer"},"too_big_tables":{"type":"integer","description":"Of them, tables with more than 1,000 tasks: too many to read here, so their tasks aren't in these counts."},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"completion_percent":{"type":"integer","description":"Progress of the tasks that count (canceled ones don't), by the same weights as a table's."},"tracked_minutes":{"type":"integer","description":"Where a table counts time: one that tracks time, or one with tasks timed one by one."}}},"description":"The 10 table names with the most tables, most first."},"other_names":{"type":"object","required":["names"],"properties":{"names":{"type":"integer","description":"How many other names."},"tables":{"type":"integer"},"too_big_tables":{"type":"integer","description":"Of them, tables with more than 1,000 tasks: too many to read here, so their tasks aren't in these counts."},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"completion_percent":{"type":"integer","description":"Progress of the tasks that count (canceled ones don't), by the same weights as a table's."},"tracked_minutes":{"type":"integer","description":"Where a table counts time: one that tracks time, or one with tasks timed one by one."}},"description":"Every other name, added up."},"partial":{"type":"boolean","description":"True when another page holds the rest of this period."}}}},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"cursor":{"type":"string","description":"Present when there is more: ask again with the same arguments and this cursor for the next page. Absent on the last page."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/dates":{"get":{"operationId":"list_dates","summary":"Days with tables","description":"The days that have tables, each once with how many tables it has, over any range: all time when no dates are given. Days from today on also count the repeating tables planned there and not made yet (planned), through end_date; without end_date, only today's: give end_date to see repeats planned ahead. Without start_date it starts at your first day with a table, or today if that's earlier (end_date, if earlier still); without end_date it runs through your last day with a table, or today if that's later. A page at a time: when the answer has a cursor, ask again with the same arguments and that cursor, and add up the pages' counts. `GET /v1/days` lists the tables themselves.\n\nA key needs: `read`. Price: 1 Integration Credit.","x-permissions":["read"],"parameters":[{"name":"start_date","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"end_date","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"scope","in":"query","required":false,"description":"Whose tables: all (default), only yours, or only those shared with you.","schema":{"type":"string","enum":["all","mine","shared"]}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave, with the same other arguments: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":20}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["start_date","end_date","dates","date_count","table_count","planned_count","truncated"],"properties":{"start_date":{"type":"string","description":"The first day read, as YYYY-MM-DD: the one asked for, or your first day with a table, or today if earlier (end_date, if earlier still)."},"end_date":{"type":"string","description":"The last day read: the one asked for, or your last day with a table (today, if later)."},"dates":{"type":"array","items":{"type":"object","required":["date","tables"],"properties":{"date":{"type":"string","description":"The day, as YYYY-MM-DD."},"tables":{"type":"integer","description":"How many tables it has."},"planned":{"type":"integer","description":"How many repeating tables are planned on it and not made yet, through end_date or, without one, today; absent when none."}}}},"date_count":{"type":"integer","description":"How many days this answer lists."},"table_count":{"type":"integer","description":"Their tables, added up."},"planned_count":{"type":"integer","description":"Their planned repeating tables, added up."},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"today":{"type":["string","null"],"description":"Today's date in that timezone, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"cursor":{"type":"string","description":"Present when there is more: ask again with the same arguments and this cursor for the next page. Absent on the last page."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/days/{date}":{"get":{"operationId":"get_day","summary":"Tables on a day","description":"The tables on one day, with their tasks, progress and tracked time. Repeating tables that haven't been created yet appear with planned: true.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD. Or `today`, which needs your timezone to be known (see `GET /v1/me`).","schema":{"type":"string"}},{"name":"scope","in":"query","required":false,"description":"Whose tables: all (default), only yours, or only those shared with you.","schema":{"type":"string","enum":["all","mine","shared"]}},{"name":"detail","in":"query","required":false,"description":"normal (default) keeps the answer small; full allows more tables, tasks and text.","schema":{"type":"string","enum":["normal","full"]}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["date","tables","truncated"],"properties":{"date":{"type":"string","description":"The day, as YYYY-MM-DD."},"tables":{"type":"array","items":{"type":"object","required":["table_id","name","date"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}}}}},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"today":{"type":["string","null"],"description":"Today's date in that timezone, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/days/{date}/open":{"post":{"operationId":"open_day","summary":"Open a day","description":"Make the repeating tables planned for a day (planned: true in `GET /v1/days/{date}`), exactly as opening that day in SelfManager does, and answer with the day's tables and every task's id. Only your own repeating tables, only from today on; nothing else changes, and a table already made is left as it is.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD. Or `today`, which needs your timezone to be known (see `GET /v1/me`).","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["date","changed","made","tables","truncated"],"properties":{"date":{"type":"string","description":"The day, as YYYY-MM-DD."},"tables":{"type":"array","items":{"type":"object","required":["table_id","name","date"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}}}}},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"today":{"type":["string","null"],"description":"Today's date in that timezone, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"changed":{"type":"boolean","description":"True: this request made at least one repeating table."},"made":{"type":"array","items":{"type":"object","required":["table_id","name"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string","description":"The table's name."}}},"description":"The repeating tables this request made."},"not_made":{"type":"array","description":"Planned ones SelfManager can't make from here, and why.","items":{"type":"object","required":["table_id","name","reason"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string","description":"The table's name."},"reason":{"type":"string"}}}},"note":{"type":"string","description":"Something worth knowing: a day that has passed, or more to make."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}":{"get":{"operationId":"get_table","summary":"One table","description":"One table with every task, your deadlines on it, its notes, and its comments if asked. Completion times are kept on tables that track time, and for tasks timed one by one on others.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"include_notes","in":"query","required":false,"description":"Include the notes (default true).","schema":{"type":"boolean"}},{"name":"include_comments","in":"query","required":false,"description":"Include comments (default false).","schema":{"type":"boolean"}},{"name":"comments_limit","in":"query","required":false,"description":"Comments per page (default 20).","schema":{"type":"integer","minimum":1,"maximum":50}},{"name":"cursor","in":"query","required":false,"description":"comments_cursor from a previous answer.","schema":{"type":"string","maxLength":10}},{"name":"detail","in":"query","required":false,"description":"normal (default) keeps the answer small; full allows more tables, tasks and text.","schema":{"type":"string","enum":["normal","full"]}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","name","date","tasks","timezone","truncated"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}},"description":{"type":"string"},"notes":{"type":"string","description":"The table's notes, as plain text."},"comments":{"type":"array","items":{"type":"object","required":["comment_id","by_you","text"],"properties":{"comment_id":{"type":"string"},"author_name":{"type":"string"},"by_you":{"type":"boolean"},"written_via":{"type":"string","description":"The connected app that wrote it for its author, when one did."},"text":{"type":"string"},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"image_ids":{"type":"array","items":{"type":"string"},"description":"Its images, when it has any, while this connection may delete or see them."},"recording_ids":{"type":"array","items":{"type":"string"},"description":"Its voice recordings, when it has any, while this connection may delete or listen to them."}}}},"comments_cursor":{"type":"string","description":"Pass it as cursor for the next page of comments. Absent on the last page."},"images":{"type":"array","items":{"type":"object","required":["image_id"],"properties":{"image_id":{"type":"string"},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."}}},"description":"The table's own images, newest first, while this connection may delete or see them."},"recordings":{"type":"array","items":{"type":"object","required":["recording_id","where"],"properties":{"recording_id":{"type":"string"},"where":{"type":"string","enum":["audio","notes"],"description":"The table's Audio section, or its notes."},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"length_seconds":{"type":"integer"}}},"description":"Voice recordings in its Audio section and notes, newest first, while this connection may delete or listen to them."},"docs":{"type":"array","items":{"type":"object","required":["doc_id","file_name","kind","has_text"],"properties":{"doc_id":{"type":"string"},"file_name":{"type":"string"},"kind":{"type":"string"},"has_text":{"type":"boolean","description":"Whether `GET /v1/tables/{date}/{table_key}/docs/{doc_id}` has its text."},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."}}},"description":"The files in its Docs section, newest first, while this connection may read them."},"people":{"type":"array","items":{"type":"object","required":["person_id","name","role"],"properties":{"person_id":{"type":"string","description":"The id a comment's mentions name them by."},"name":{"type":"string","description":"Write @ and this name in a comment that mentions them."},"role":{"type":"string","enum":["owner","admin","member","viewer"]}}},"description":"Who a comment of yours can @mention on this table, while this connection may mention people."},"planned_note":{"type":"string"},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}":{"get":{"operationId":"get_table_shared","summary":"One table (a table someone else owns)","description":"One table with every task, your deadlines on it, its notes, and its comments if asked. Completion times are kept on tables that track time, and for tasks timed one by one on others.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"x-variant-of":"get_table","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"include_notes","in":"query","required":false,"description":"Include the notes (default true).","schema":{"type":"boolean"}},{"name":"include_comments","in":"query","required":false,"description":"Include comments (default false).","schema":{"type":"boolean"}},{"name":"comments_limit","in":"query","required":false,"description":"Comments per page (default 20).","schema":{"type":"integer","minimum":1,"maximum":50}},{"name":"cursor","in":"query","required":false,"description":"comments_cursor from a previous answer.","schema":{"type":"string","maxLength":10}},{"name":"detail","in":"query","required":false,"description":"normal (default) keeps the answer small; full allows more tables, tasks and text.","schema":{"type":"string","enum":["normal","full"]}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","name","date","tasks","timezone","truncated"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}},"description":{"type":"string"},"notes":{"type":"string","description":"The table's notes, as plain text."},"comments":{"type":"array","items":{"type":"object","required":["comment_id","by_you","text"],"properties":{"comment_id":{"type":"string"},"author_name":{"type":"string"},"by_you":{"type":"boolean"},"written_via":{"type":"string","description":"The connected app that wrote it for its author, when one did."},"text":{"type":"string"},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"image_ids":{"type":"array","items":{"type":"string"},"description":"Its images, when it has any, while this connection may delete or see them."},"recording_ids":{"type":"array","items":{"type":"string"},"description":"Its voice recordings, when it has any, while this connection may delete or listen to them."}}}},"comments_cursor":{"type":"string","description":"Pass it as cursor for the next page of comments. Absent on the last page."},"images":{"type":"array","items":{"type":"object","required":["image_id"],"properties":{"image_id":{"type":"string"},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."}}},"description":"The table's own images, newest first, while this connection may delete or see them."},"recordings":{"type":"array","items":{"type":"object","required":["recording_id","where"],"properties":{"recording_id":{"type":"string"},"where":{"type":"string","enum":["audio","notes"],"description":"The table's Audio section, or its notes."},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"length_seconds":{"type":"integer"}}},"description":"Voice recordings in its Audio section and notes, newest first, while this connection may delete or listen to them."},"docs":{"type":"array","items":{"type":"object","required":["doc_id","file_name","kind","has_text"],"properties":{"doc_id":{"type":"string"},"file_name":{"type":"string"},"kind":{"type":"string"},"has_text":{"type":"boolean","description":"Whether `GET /v1/tables/{date}/{table_key}/docs/{doc_id}` has its text."},"added_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."}}},"description":"The files in its Docs section, newest first, while this connection may read them."},"people":{"type":"array","items":{"type":"object","required":["person_id","name","role"],"properties":{"person_id":{"type":"string","description":"The id a comment's mentions name them by."},"name":{"type":"string","description":"Write @ and this name in a comment that mentions them."},"role":{"type":"string","enum":["owner","admin","member","viewer"]}}},"description":"Who a comment of yours can @mention on this table, while this connection may mention people."},"planned_note":{"type":"string"},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/search":{"get":{"operationId":"search_tables","summary":"Search your tables","description":"Search the tables you own for a word or phrase (the exact text, in any case, not each word apart) in their name, description, tasks or notes, and in comments when fields includes comments, within a date window of any length (the last 30 days by default), newest first. One call looks through up to 1,000 tables: when the answer has a cursor, older tables in the window are left, so ask again with the same arguments and that cursor. It searches only tables you own: `GET /v1/days/{date}` and `GET /v1/days` read the ones others share with you.\n\nA key needs: `read`. Price: 1 Integration Credit.","x-permissions":["read"],"parameters":[{"name":"query","in":"query","required":true,"description":"The words to find.","schema":{"type":"string","minLength":1,"maxLength":100}},{"name":"fields","in":"query","required":false,"description":"Where to look (default name, description, tasks and notes).","schema":{"type":"array","items":{"type":"string","enum":["name","description","tasks","notes","comments"]},"maxItems":5},"style":"form","explode":false},{"name":"date_from","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"date_to","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"limit","in":"query","required":false,"description":"At most this many tables (default 10).","schema":{"type":"integer","minimum":1,"maximum":20}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave, with the same other arguments: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":20}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["query","date_from","date_to","results","searched","truncated"],"properties":{"query":{"type":"string"},"date_from":{"type":"string"},"date_to":{"type":"string"},"results":{"type":"array","items":{"type":"object","required":["table_id","name","date","matched_in","matching_tasks"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string"},"matched_in":{"type":"array","items":{"type":"string","enum":["name","description","tasks","notes","comments"]}},"matching_tasks":{"type":"array","items":{"type":"object","required":["task_id","name"],"properties":{"task_id":{"type":"string"},"name":{"type":"string"}}}}}}},"searched":{"type":"string","description":"Which tables were searched."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"cursor":{"type":"string","description":"Present when there is more: ask again with the same arguments and this cursor for the next page. Absent on the last page."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/pins":{"get":{"operationId":"list_pinned_tables","summary":"Pinned tables","description":"Your pinned tables, in their order, with their date and progress.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["pins","truncated"],"properties":{"pins":{"type":"array","items":{"type":"object","required":["table_id","name","date"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string"},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"shared":{"type":"boolean","description":"True when other people can see the table."},"your_role":{"type":"string","enum":["owner","admin","member","viewer"]},"completion_percent":{"type":"integer"},"task_count":{"type":"integer"},"completed_count":{"type":"integer"},"tracked_minutes":{"type":"integer","description":"Only for a table that tracks time, or one with tasks timed one by one (those alone count)."},"has_notes":{"type":"boolean"},"planned":{"type":"boolean","description":"True for a repeating table that hasn't been created for that day yet."},"too_big":{"type":"boolean","description":"True for a table with more than 1,000 tasks: too many to read here, so neither its tasks nor its progress are given. Open it in SelfManager."},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"task_id":{"type":"string","description":"The task's id. A task of a repeating table not created yet has none."},"name":{"type":"string"},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"]},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"duration_minutes":{"type":"integer","description":"Tracked time of a completed task: in a table that tracks time, or a task timed one by one."},"created_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"started_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"created_by_name":{"type":"string"},"completed_by_name":{"type":"string"},"deadline":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"deadline_met":{"type":"boolean"}}}}}}},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/deadlines":{"get":{"operationId":"list_deadlines","summary":"Deadlines","description":"Your deadlines, as the Deadlines page shows them: overdue, today, the next 7 days, later, or met. Grouping needs your timezone.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"filter","in":"query","required":false,"description":"Which deadlines (default all).","schema":{"type":"string","enum":["overdue","today","week","later","completed","all"]}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["filter","timezone","deadlines","truncated"],"properties":{"filter":{"type":"string","enum":["overdue","today","week","later","completed","all"]},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"deadlines":{"type":"array","items":{"type":"object","required":["task_name","table_name"],"properties":{"task_name":{"type":"string"},"table_name":{"type":"string"},"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"due_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."},"group":{"type":"string","enum":["overdue","today","week","later","completed"],"description":"Absent for an open deadline when the timezone isn't known."},"completed_at":{"type":"string","description":"A time as ISO 8601 with the timezone's offset, or in UTC (ending in Z) when the timezone isn't known."}}}},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/repeats":{"get":{"operationId":"list_repeating_tables","summary":"Repeating tables","description":"Your repeating tables: what repeats, how often, the next date, and whether it is paused. Each date it repeats on gets its own copy; changing one day's copy doesn't change the repeat. `GET /v1/repeats/{repeat_id}` reads one whole, and `PATCH /v1/repeats/{repeat_id}` changes it.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["repeats_enabled","repeats","timezone","truncated"],"properties":{"repeats_enabled":{"type":"boolean","description":"False when repeating tables are switched off in Settings."},"repeats":{"type":"array","items":{"type":"object","required":["repeat_id","name","cadence","status"],"properties":{"repeat_id":{"type":"string","description":"Its id, for `GET /v1/repeats/{repeat_id}` and `PATCH /v1/repeats/{repeat_id}`."},"name":{"type":"string"},"cadence":{"type":"string","description":"How often, in words."},"status":{"type":"string","enum":["active","paused"]},"next_date":{"type":"string"},"start_date":{"type":"string"},"end_date":{"type":"string"}}}},"timezone":{"type":["string","null"],"description":"The IANA timezone the answer was worked out in, or null when none is known."},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"note":{"type":"string"}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/repeats/{repeat_id}":{"get":{"operationId":"get_repeating_table","summary":"One repeating table","description":"One of your repeating tables whole: its schedule, and the name, description, tasks and notes each copy starts with, plus how many tables it has already made for today on. Its id comes from `GET /v1/repeats`.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"repeat_id","in":"path","required":true,"description":"The repeating table's id, as `GET /v1/repeats` gives it.","schema":{"type":"string"}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["repeat_id","name","status","cadence","schedule","start_date","tasks","future_tables","repeats_enabled","editable","timezone","truncated"],"properties":{"repeat_id":{"type":"string"},"name":{"type":"string","description":"The name each copy gets."},"status":{"type":"string","enum":["active","paused"]},"cadence":{"type":"string","description":"How often, in words."},"start_date":{"type":"string"},"end_date":{"type":"string"},"next_date":{"type":"string"},"schedule":{"type":"object","required":["frequency","interval"],"properties":{"frequency":{"type":"string","enum":["daily","weekly","monthly"]},"interval":{"type":"integer","description":"Every this many days, weeks or months."},"weekdays":{"type":"array","items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]}},"month_days":{"type":"array","items":{"type":"integer"}}}},"description":{"type":"string"},"tasks":{"type":"array","items":{"type":"object","required":["name","priority"],"properties":{"name":{"type":"string"},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]}}}},"too_big":{"type":"boolean","description":"True when its blueprint has more than 1,000 tasks: too many to read here, so none are given."},"notes":{"type":"string","description":"Its notes, as plain text."},"future_tables":{"type":"integer","description":"Tables it has already made, for today on."},"repeats_enabled":{"type":"boolean","description":"False when repeating tables are switched off in Settings."},"editable":{"type":"boolean","description":"Whether `PATCH /v1/repeats/{repeat_id}` can change it."},"timezone":{"type":["string","null"]},"truncated":{"type":"boolean"}}}}}},"default":{"$ref":"#/components/responses/Error"}}},"patch":{"operationId":"update_repeating_table","summary":"Change a repeating table","description":"Change a repeating table as SelfManager's Repeats page does: what each new copy starts with (name, description, the whole task list, notes as plain text that replaces them), the schedule, the end date (null removes it), or pause and resume it. Tables already made keep the old version unless `also_update_future` is true: then those for today on that nobody worked in, and nobody else can see, are updated too, never their notes. It never deletes a repeat or changes its start date.\n\nGive at least one of `name`, `description`, `tasks`, `notes`, `schedule`, `end_date`, `status` and `also_update_future`.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"parameters":[{"name":"repeat_id","in":"path","required":true,"description":"The repeating table's id, as `GET /v1/repeats` gives it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600},"description":{"type":"string","maxLength":20000,"description":"\"\" removes it."},"tasks":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional (the default)."}},"required":["name"],"additionalProperties":false},"maxItems":100,"description":"The whole new task list, in order: tasks left out are removed."},"notes":{"type":"string","maxLength":100000,"description":"Plain text that replaces the notes (each line a paragraph; their formatting isn't kept); \"\" removes them."},"schedule":{"type":"object","properties":{"frequency":{"type":"string","enum":["daily","weekly","monthly"]},"interval":{"type":"integer","minimum":1,"maximum":366,"description":"Every this many days, weeks or months (default 1)."},"weekdays":{"type":"array","minItems":1,"maxItems":7,"items":{"type":"string","enum":["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]},"description":"Weekly only: the days."},"month_days":{"type":"array","minItems":1,"maxItems":31,"items":{"type":"integer","minimum":1,"maximum":31},"description":"Monthly only: the days of the month (the 31st falls on a short month's last day)."}},"required":["frequency"],"additionalProperties":false},"end_date":{"type":["string","null"],"pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"The last date it repeats on, as YYYY-MM-DD; null removes the end."},"status":{"type":"string","enum":["active","paused"],"description":"paused stops new copies; active resumes."},"also_update_future":{"type":"boolean","description":"Also update the tables it already made for today on that nobody worked in (default false)."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"anyOf":[{"required":["name"]},{"required":["description"]},{"required":["tasks"]},{"required":["notes"]},{"required":["schedule"]},{"required":["end_date"]},{"required":["status"]},{"required":["also_update_future"]}],"additionalProperties":false},"example":{"name":"Call the bank"}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["repeat_id","name","changed","changed_fields","status","cadence","start_date","truncated"],"properties":{"repeat_id":{"type":"string"},"name":{"type":"string","description":"The name each copy gets."},"status":{"type":"string","enum":["active","paused"]},"cadence":{"type":"string","description":"How often, in words."},"start_date":{"type":"string"},"end_date":{"type":"string"},"next_date":{"type":"string"},"changed":{"type":"boolean"},"changed_fields":{"type":"array","items":{"type":"string","enum":["name","description","tasks","notes","schedule","end_date","status"]}},"future_tables":{"type":"object","description":"With also_update_future: what happened to the tables already made for today on.","properties":{"updated":{"type":"integer"},"already_current":{"type":"integer"},"left_alone_worked_in":{"type":"integer"},"left_alone_shared":{"type":"integer"},"not_updated":{"type":"integer"},"not_reached":{"type":"integer"}}},"note":{"type":"string"},"truncated":{"type":"boolean"}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/journal":{"get":{"operationId":"get_journal","summary":"Journal","description":"Your daily journal (self messages) for one date, or a range of any length, a page at a time: when the answer has a cursor, ask again with the same arguments and that cursor. Without a date it uses today, which needs your timezone.\n\nA key needs: `read`, `journal`. Price: free.","x-permissions":["read","journal"],"parameters":[{"name":"date","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"start_date","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"end_date","in":"query","required":false,"description":"A date as YYYY-MM-DD, from 2000 to 2099.","schema":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$"}},{"name":"detail","in":"query","required":false,"description":"normal (default) keeps the answer small; full allows more tables, tasks and text.","schema":{"type":"string","enum":["normal","full"]}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave, with the same other arguments: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":20}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["start_date","end_date","entries","truncated"],"properties":{"start_date":{"type":"string"},"end_date":{"type":"string"},"entries":{"type":"array","items":{"type":"object","required":["date","text"],"properties":{"date":{"type":"string"},"text":{"type":"string"}}}},"truncated":{"type":"boolean","description":"True when something was left out or cut to keep the answer small."},"hint":{"type":"string","description":"What to ask for instead, when something was left out."},"cursor":{"type":"string","description":"Present when there is more: ask again with the same arguments and this cursor for the next page. Absent on the last page."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/ai-history":{"get":{"operationId":"list_ai_history","summary":"Your AI History","description":"The conversations saved in your AI History, newest first: SelfManager's AI Reviews, tables' AI chats, and those an assistant saved. Titles, kinds, dates and a short preview, a page at a time: when the answer has a cursor, ask again with it for older ones. `GET /v1/ai-history/{conversation_id}` reads one.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":16}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["conversations","truncated"],"properties":{"conversations":{"type":"array","items":{"type":"object","required":["conversation_id","title","kind","type","created_at","entry_count"],"properties":{"conversation_id":{"type":"string"},"title":{"type":"string"},"kind":{"type":"string","enum":["ai_review","table_chat","pinned_tables","assistant","other"],"description":"ai_review: SelfManager's AI Review; table_chat: a table's AI chat; pinned_tables: the pinned tables' chat; assistant: one an assistant saved."},"type":{"type":"string","enum":["summary","chat","follow_up"]},"created_at":{"type":"string"},"entry_count":{"type":"integer"},"app":{"type":"string","description":"The assistant that saved it, for kind assistant."},"period":{"type":"string","description":"The period a review covers."},"table_name":{"type":"string"},"preview":{"type":"string"}}}},"truncated":{"type":"boolean"},"cursor":{"type":"string"},"hint":{"type":"string"}}}}}},"default":{"$ref":"#/components/responses/Error"}}},"post":{"operationId":"save_to_ai_history","summary":"Save to AI History","description":"Save a review or a chat to your AI History in SelfManager, where it shows beside the app's own AI Reviews, marked as the API's. Plain text: entries in order, each `user` or `assistant`. It can't be changed or deleted through the API afterwards.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit.","x-permissions":["read","write"],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200,"description":"A short title."},"kind":{"type":"string","enum":["review","chat"]},"period":{"type":"object","properties":{"start_date":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"A date as YYYY-MM-DD, from 2000 to 2099."},"end_date":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"A date as YYYY-MM-DD, from 2000 to 2099."}},"required":["start_date","end_date"],"additionalProperties":false},"entries":{"type":"array","minItems":1,"maxItems":100,"items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"text":{"type":"string","minLength":1,"maxLength":20000}},"required":["role","text"],"additionalProperties":false}}},"required":["title","kind","entries"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["conversation_id","title","entry_count","saved_at"],"properties":{"conversation_id":{"type":"string"},"title":{"type":"string"},"entry_count":{"type":"integer"},"saved_at":{"type":"string"}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/ai-history/{conversation_id}":{"get":{"operationId":"get_ai_conversation","summary":"One AI History conversation","description":"One conversation from your AI History, its entries in order as plain text (role user or assistant), a page of them at a time: when the answer has a cursor, ask again with it.\n\nA key needs: `read`. Price: free.","x-permissions":["read"],"parameters":[{"name":"conversation_id","in":"path","required":true,"description":"The conversation's id, as `GET /v1/ai-history` gives it.","schema":{"type":"string"}},{"name":"cursor","in":"query","required":false,"description":"The cursor an earlier answer gave: where the next page starts.","schema":{"type":"string","minLength":1,"maxLength":16}},{"name":"timezone","in":"query","required":false,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you.","schema":{"type":"string","maxLength":64}}],"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["conversation_id","title","kind","type","created_at","entry_count","entries","truncated"],"properties":{"conversation_id":{"type":"string"},"title":{"type":"string"},"kind":{"type":"string","enum":["ai_review","table_chat","pinned_tables","assistant","other"],"description":"ai_review: SelfManager's AI Review; table_chat: a table's AI chat; pinned_tables: the pinned tables' chat; assistant: one an assistant saved."},"type":{"type":"string","enum":["summary","chat","follow_up"]},"created_at":{"type":"string"},"entry_count":{"type":"integer"},"app":{"type":"string","description":"The assistant that saved it, for kind assistant."},"period":{"type":"string","description":"The period a review covers."},"table_name":{"type":"string"},"updated_at":{"type":"string"},"entries":{"type":"array","items":{"type":"object","required":["role","text"],"properties":{"role":{"type":"string","enum":["user","assistant"]},"text":{"type":"string"}}}},"truncated":{"type":"boolean"},"cursor":{"type":"string"},"hint":{"type":"string"}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables":{"post":{"operationId":"create_table","summary":"Create a table","description":"Create one table of yours on a day, with up to 200 tasks and optional notes. For several tables, or one table on many days, use `POST /v1/tables/batch`: one call. To add tasks to a table that exists, use `POST /v1/tables/{date}/{table_key}/tasks`. Time isn't tracked unless track_time is true, as in the app. Give an `Idempotency-Key` header to make a retry safe.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit or more, by what it makes (**Prices**).","x-permissions":["read","write"],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"date":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"A date as YYYY-MM-DD, from 2000 to 2099."},"name":{"type":"string","minLength":1,"maxLength":600,"description":"The table's name."},"description":{"type":"string","maxLength":20000,"description":"Optional description."},"tasks":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"What to do."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional (the default)."}},"required":["name"],"additionalProperties":false},"maxItems":200},"notes":{"type":"string","maxLength":100000,"description":"Optional notes, as plain text: each line becomes a paragraph."},"track_time":{"type":"boolean","description":"Track time on its tasks (default false)."}},"required":["date","name"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","name","date","tasks","has_notes","tracks_time"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"name":{"type":"string","description":"The table's name."},"date":{"type":"string","description":"The table's day, as YYYY-MM-DD."},"tasks":{"type":"array","items":{"type":"object","required":["task_id","name","priority"],"properties":{"task_id":{"type":"string"},"name":{"type":"string"},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]}}}},"has_notes":{"type":"boolean"},"tracks_time":{"type":"boolean"}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/batch":{"post":{"operationId":"create_tables","summary":"Create many tables","description":"Create up to 1,000 tables of yours in one request, on any days, several on one day too. Each entry is one table on its `date`, or the same table on each of its `dates`, with up to 200 tasks and optional notes, as `POST /v1/tables` makes them. The `Idempotency-Key` header is required: when a request times out, or answers 504 having run out of time, send it again with the same key to make what is missing, never anything twice.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit or more, by what it makes (**Prices**).","x-permissions":["read","write"],"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Required here. An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"tables":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"The day, as YYYY-MM-DD. Give date or dates."},"dates":{"type":"array","items":{"type":"string","pattern":"^20\\d{2}-\\d{2}-\\d{2}$","description":"A date as YYYY-MM-DD, from 2000 to 2099."},"minItems":1,"maxItems":1000,"description":"The same table on each of these days, each day once. Give date or dates."},"name":{"type":"string","minLength":1,"maxLength":600,"description":"The table's name."},"description":{"type":"string","maxLength":20000,"description":"Optional description."},"tasks":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"What to do."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional (the default)."}},"required":["name"],"additionalProperties":false},"maxItems":200,"description":"Up to 200 tasks."},"notes":{"type":"string","maxLength":100000,"description":"Optional notes, as plain text: each line becomes a paragraph."},"track_time":{"type":"boolean","description":"Track time on its tasks (default false)."}},"required":["name"],"additionalProperties":false},"minItems":1,"maxItems":1000,"description":"The tables, in the order to make them."}},"required":["tables"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_count","first_date","last_date","tables"],"properties":{"table_count":{"type":"integer","description":"How many tables the request made, in all."},"first_date":{"type":"string","description":"The first day a table was made on."},"last_date":{"type":"string","description":"The last day a table was made on."},"tables":{"type":"array","items":{"type":"object","required":["name","table_ids"],"properties":{"name":{"type":"string"},"table_ids":{"type":"array","items":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"description":"One per date, in the order sent."}}},"description":"Each entry's tables, in the order sent. `GET /v1/tables/{date}/{table_key}` shows a table's tasks."},"note":{"type":"string","description":"Something worth knowing, such as tables an earlier attempt made."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/tasks":{"post":{"operationId":"add_tasks","summary":"Add tasks","description":"Add up to 200 tasks at the end of a table. A repeating table that hasn't been created for that day yet is created first. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit or more, by what it makes (**Prices**).","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"tasks":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"What to do."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional (the default)."}},"required":["name"],"additionalProperties":false},"maxItems":200,"minItems":1},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["tasks"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","tasks"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"tasks":{"type":"array","items":{"type":"object","required":["task_id","name","priority"],"properties":{"task_id":{"type":"string"},"name":{"type":"string"},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]}}}},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/tasks":{"post":{"operationId":"add_tasks_shared","summary":"Add tasks (a table someone else owns)","description":"Add up to 200 tasks at the end of a table. A repeating table that hasn't been created for that day yet is created first. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`, `shared`. Price: 1 Integration Credit or more, by what it makes (**Prices**).","x-permissions":["read","write","shared"],"x-variant-of":"add_tasks","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"tasks":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"What to do."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional (the default)."}},"required":["name"],"additionalProperties":false},"maxItems":200,"minItems":1},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["tasks"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","tasks"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"tasks":{"type":"array","items":{"type":"object","required":["task_id","name","priority"],"properties":{"task_id":{"type":"string"},"name":{"type":"string"},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]}}}},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/tasks/{task_id}":{"patch":{"operationId":"update_task","summary":"Update a task","description":"Rename a task, change its priority, or set its progress short of completed (`POST /v1/tables/{date}/{table_key}/tasks/{task_id}/complete` and `POST /v1/tables/{date}/{table_key}/tasks/{task_id}/reopen` change that). Progress canceled leaves a task out of the table's progress, and keeps it; deleting it is `DELETE /v1/tables/{date}/{table_key}/tasks/{task_id}`'s, where that is listed. Renaming works only in tables nobody else can read.\n\nGive at least one of `name`, `priority` and `progress`.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"The new name."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional."},"progress":{"type":"string","enum":["not_started","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"How far along it is, short of completed."}},"anyOf":[{"required":["name"]},{"required":["priority"]},{"required":["progress"]}],"additionalProperties":false},"example":{"name":"Call the bank"}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"changed_fields":{"type":"array","items":{"type":"string","enum":["status","name","priority"]},"description":"What was changed, when something was."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/tasks/{task_id}":{"patch":{"operationId":"update_task_shared","summary":"Update a task (a table someone else owns)","description":"Rename a task, change its priority, or set its progress short of completed (`POST /v1/tables/{date}/{table_key}/tasks/{task_id}/complete` and `POST /v1/tables/{date}/{table_key}/tasks/{task_id}/reopen` change that). Progress canceled leaves a task out of the table's progress, and keeps it; deleting it is `DELETE /v1/tables/{date}/{table_key}/tasks/{task_id}`'s, where that is listed. Renaming works only in tables nobody else can read.\n\nGive at least one of `name`, `priority` and `progress`.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"x-variant-of":"update_task","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":600,"description":"The new name."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"],"description":"critical, high, medium, low, minor or optional."},"progress":{"type":"string","enum":["not_started","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"How far along it is, short of completed."}},"anyOf":[{"required":["name"]},{"required":["priority"]},{"required":["progress"]}],"additionalProperties":false},"example":{"name":"Call the bank"}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"priority":{"type":"string","enum":["critical","high","medium","low","minor","optional"]},"changed_fields":{"type":"array","items":{"type":"string","enum":["status","name","priority"]},"description":"What was changed, when something was."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/tasks/{task_id}/complete":{"post":{"operationId":"complete_task","summary":"Complete a task","description":"Mark a task completed, as ticking it in SelfManager does: its time, who completed it, its deadline and the table's log. Works on your tables and on tables shared with you where you're an admin or member, not a viewer. A task of a table with planned: true has no task_id until `POST /v1/days/{date}/open` makes that day's copies. A task already completed is left as it is.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","status","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"deadline":{"type":"string","enum":["met","restored"],"description":"What happens to the task's deadline, when it has one: met, for everyone it reminds, or back."},"tracked_time_deleted":{"type":"boolean","description":"True when reopening deleted the time recorded for the task."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/tasks/{task_id}/complete":{"post":{"operationId":"complete_task_shared","summary":"Complete a task (a table someone else owns)","description":"Mark a task completed, as ticking it in SelfManager does: its time, who completed it, its deadline and the table's log. Works on your tables and on tables shared with you where you're an admin or member, not a viewer. A task of a table with planned: true has no task_id until `POST /v1/days/{date}/open` makes that day's copies. A task already completed is left as it is.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"x-variant-of":"complete_task","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","status","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"deadline":{"type":"string","enum":["met","restored"],"description":"What happens to the task's deadline, when it has one: met, for everyone it reminds, or back."},"tracked_time_deleted":{"type":"boolean","description":"True when reopening deleted the time recorded for the task."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/tasks/{task_id}/reopen":{"post":{"operationId":"reopen_task","summary":"Reopen a task","description":"Mark a completed task as not started again, as unticking it in SelfManager does. This deletes the time recorded for it, and brings its deadline back.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","status","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"deadline":{"type":"string","enum":["met","restored"],"description":"What happens to the task's deadline, when it has one: met, for everyone it reminds, or back."},"tracked_time_deleted":{"type":"boolean","description":"True when reopening deleted the time recorded for the task."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/tasks/{task_id}/reopen":{"post":{"operationId":"reopen_task_shared","summary":"Reopen a task (a table someone else owns)","description":"Mark a completed task as not started again, as unticking it in SelfManager does. This deletes the time recorded for it, and brings its deadline back.\n\nA key needs: `read`, `write`. Price: free.","x-permissions":["read","write"],"x-variant-of":"reopen_task","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"task_id","in":"path","required":true,"description":"The task's id, as the table's tasks give it.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","task_id","name","status","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"task_id":{"type":"string"},"name":{"type":"string","description":"The task's name."},"status":{"type":"string","enum":["not_started","completed","almost_completed","done_something","checked_a_little","did_overview","canceled"],"description":"The task's progress as it reads now."},"changed":{"type":"boolean","description":"False when the task already read that way, so nothing was written."},"note":{"type":"string","description":"Something worth knowing about what happened, or why nothing did."},"deadline":{"type":"string","enum":["met","restored"],"description":"What happens to the task's deadline, when it has one: met, for everyone it reminds, or back."},"tracked_time_deleted":{"type":"boolean","description":"True when reopening deleted the time recorded for the task."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/comments":{"post":{"operationId":"add_comment","summary":"Add a comment","description":"Add a comment, as you, to a table. Plain text; @mentions aren't sent. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":60000,"description":"The comment."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["text"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","comment_id"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"comment_id":{"type":"string"},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."},"mentioned":{"type":"integer","description":"How many of the people it mentions were told."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/comments":{"post":{"operationId":"add_comment_shared","summary":"Add a comment (a table someone else owns)","description":"Add a comment, as you, to a table. Plain text; @mentions aren't sent. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`, `shared`. Price: 1 Integration Credit.","x-permissions":["read","write","shared"],"x-variant-of":"add_comment","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":60000,"description":"The comment."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["text"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","comment_id"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"comment_id":{"type":"string"},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."},"mentioned":{"type":"integer","description":"How many of the people it mentions were told."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/notes":{"post":{"operationId":"append_table_notes","summary":"Add to a table's notes","description":"Add text at the end of a table's notes: each line becomes a paragraph. The version before stays one undo away in SelfManager. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`. Price: 1 Integration Credit.","x-permissions":["read","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":100000,"description":"The text, as plain text."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["text"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"changed":{"type":"boolean","description":"True: the text is at the end of the notes."},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/tables/{date}/{table_key}/{owner_tag}/notes":{"post":{"operationId":"append_table_notes_shared","summary":"Add to a table's notes (a table someone else owns)","description":"Add text at the end of a table's notes: each line becomes a paragraph. The version before stays one undo away in SelfManager. In a table other people can see (one shared with you, one of yours you share, or one with an invitation waiting), the key needs the `shared` permission.\n\nA key needs: `read`, `write`, `shared`. Price: 1 Integration Credit.","x-permissions":["read","write","shared"],"x-variant-of":"append_table_notes","parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD.","schema":{"type":"string"}},{"name":"table_key","in":"path","required":true,"description":"The second part of the table's id, as every answer gives it (`table_id` is `date/table_key`).","schema":{"type":"string"}},{"name":"owner_tag","in":"path","required":true,"description":"The third part of the id of a table someone else owns.","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":100000,"description":"The text, as plain text."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["text"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["table_id","table_name","changed"],"properties":{"table_id":{"type":"string","description":"The table's id: YYYY-MM-DD/tableKey, with a third part when someone else owns the table."},"table_name":{"type":"string","description":"The table's name."},"changed":{"type":"boolean","description":"True: the text is at the end of the notes."},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}},"/v1/journal/{date}":{"post":{"operationId":"append_journal","summary":"Add to your journal","description":"Add text to a day's journal line (your self message for that day), after a space; line breaks become spaces.\n\nA key needs: `read`, `journal`, `write`. Price: 1 Integration Credit.","x-permissions":["read","journal","write"],"parameters":[{"name":"date","in":"path","required":true,"description":"The day, as YYYY-MM-DD. Or `today`, which needs your timezone to be known (see `GET /v1/me`).","schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"description":"An id of your choosing for this request. Sent again with the same one, the request answers what it answered first and changes nothing twice.","schema":{"type":"string","minLength":1,"maxLength":200}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":60000,"description":"The text to add."},"timezone":{"type":"string","maxLength":64,"description":"Optional IANA timezone, such as Europe/Bucharest. Defaults to the one SelfManager stored for you."}},"required":["text"],"additionalProperties":false}}}},"responses":{"200":{"description":"The answer.","content":{"application/json":{"schema":{"type":"object","required":["date","changed","entry","truncated"],"properties":{"date":{"type":"string","description":"The day written to, as YYYY-MM-DD."},"changed":{"type":"boolean"},"entry":{"type":"string","description":"That day's journal line as it reads now, cut when it is long."},"truncated":{"type":"boolean","description":"True when the line shown was cut."},"note":{"type":"string","description":"Something worth knowing about what happened: a repeating table created first, or an earlier attempt of the same request found to have done it already."}}}}}},"default":{"$ref":"#/components/responses/Error"}}}}},"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"A personal API key, made in SelfManager under My Profile, Connected apps."}},"responses":{"Error":{"description":"An error, with a code and a message written for a person.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["cannot_apply","conflict","forbidden","insufficient_credits","insufficient_scope","invalid_request","method_not_allowed","not_found","not_in_beta","plan_inactive","rate_limited","request_in_progress","server_error","timed_out","too_large","unauthorized","unavailable","unsupported_media_type","viewer_role","writes_off"]},"message":{"type":"string"}}},"request_id":{"type":"string","description":"Only on a 500: quote it when you report the failure."}}}}}}