{"openapi":"3.0.3","info":{"title":"Neurotic PM API","version":"1","description":"A JSON API over everything in Neurotic PM: spaces, projects, epics, tasks, perpetuals, comments and task attachments.\n\nA token acts as the person it was issued to: same spaces, same visibility, same rights. Admins issue tokens in the back office. Changes made here notify people and are audited exactly like changes made in the app."},"servers":[{"url":"https://pm.neurotic.co/api/v1"}],"security":[{"bearer":[]}],"tags":[{"name":"Me","description":"Who the token belongs to."},{"name":"Spaces","description":"Spaces, their columns and people."},{"name":"Tasks"},{"name":"Projects"},{"name":"Epics"},{"name":"Comments","description":"Threads on tasks, projects and epics."},{"name":"Attachments","description":"Files on tasks: the same files the app shows, with the same 15 MB cap."},{"name":"Perpetuals","description":"Recurring deliverables: a schedule that opens a run each period, with a task per assignee."}],"paths":{"/me":{"get":{"tags":["Me"],"summary":"Who am I","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Me"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces":{"get":{"tags":["Spaces"],"summary":"Spaces I can see","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"spaces":{"type":"array","items":{"$ref":"#/components/schemas/SpaceSummary"}}}}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}":{"get":{"tags":["Spaces"],"summary":"One space with its columns and people","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Space"}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/columns":{"get":{"tags":["Spaces"],"summary":"Status columns in board order","description":"Use these keys wherever a status is sent. Five are built in (backlog, todo, in_progress, in_review, done); spaces may add their own.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"columns":{"type":"array","items":{"$ref":"#/components/schemas/Column"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/tasks":{"get":{"tags":["Tasks"],"summary":"List tasks","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."},{"name":"status","in":"query","schema":{"type":"string"},"description":"A column key."},{"name":"project","in":"query","schema":{"type":"string","format":"uuid"}},{"name":"epic","in":"query","schema":{"type":"string","format":"uuid"}},{"name":"assignee","in":"query","schema":{"type":"string","format":"uuid"},"description":"A user id."},{"name":"type","in":"query","schema":{"$ref":"#/components/schemas/TaskType"}},{"name":"size","in":"query","schema":{"type":"string","enum":["xs","s","m","l","xl","none"]},"description":"none = unsized tasks."},{"name":"priority","in":"query","schema":{"$ref":"#/components/schemas/Priority"}},{"name":"due","in":"query","schema":{"type":"string","enum":["overdue","today","soon","ok","none"]},"description":"Where the end date stands; soon = within three days; none = no end date."},{"name":"visibility","in":"query","schema":{"$ref":"#/components/schemas/Visibility"},"description":"Neurotic team tokens only."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"tasks":{"type":"array","items":{"$ref":"#/components/schemas/Task"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Tasks"],"summary":"Create a task","description":"Every column is filled on the way in: title, type, size, priority, dueDate and assignees are required; status defaults to todo and visibility to client.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskCreate"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"task":{"$ref":"#/components/schemas/Task"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/tasks/{id}":{"get":{"tags":["Tasks"],"summary":"One task","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The task id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"task":{"$ref":"#/components/schemas/Task"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"tags":["Tasks"],"summary":"Change a task","description":"Only the fields you send change. project and epic take null to detach; size, dueDate and assignees can be changed but not cleared, so a task keeps every column filled. Moving status into done stamps the completion time.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The task id."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskPatch"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"task":{"$ref":"#/components/schemas/Task"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"delete":{"tags":["Tasks"],"summary":"Delete a task","description":"Neurotic team tokens only. The task is archived: it disappears from the space but an admin can restore it from Back office → Archived.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The task id."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"string","format":"uuid"},"archived":{"type":"boolean"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Clients cannot delete.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/tasks/{id}/attachments":{"get":{"tags":["Attachments"],"summary":"Files on a task","description":"Newest first. Clients see client- and vendor-shared files; vendors only what was shared with vendors. Download a file at its url with the same Bearer token or a signed-in browser.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The task id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"attachments":{"type":"array","items":{"$ref":"#/components/schemas/Attachment"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Attachments"],"summary":"Attach a file to a task","description":"Send multipart/form-data with the file in a part named file (optional name to rename it, visibility for Neurotic team tokens), or a JSON object with name and the bytes as base64 content (optional contentType, visibility). Any type; files are capped at 15 MB and may not be empty. The token's owner is the uploader; the people on the task are notified and the upload is audited, exactly as in the app.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The task id."}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"},"name":{"type":"string","maxLength":200},"visibility":{"$ref":"#/components/schemas/Visibility"}}}},"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentCreate"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"attachment":{"$ref":"#/components/schemas/Attachment"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"The file is over 15 MB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/projects":{"get":{"tags":["Projects"],"summary":"List projects","description":"With open and done task counts in the token's view.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"projects":{"type":"array","items":{"$ref":"#/components/schemas/Project"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Projects"],"summary":"Create a project","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreate"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"project":{"$ref":"#/components/schemas/Project"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/projects/{id}":{"get":{"tags":["Projects"],"summary":"One project","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The project id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"project":{"$ref":"#/components/schemas/Project"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"tags":["Projects"],"summary":"Change a project","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The project id."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectPatch"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"project":{"$ref":"#/components/schemas/Project"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/epics":{"get":{"tags":["Epics"],"summary":"List epics","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."},{"name":"project","in":"query","schema":{"type":"string","format":"uuid"},"description":"Only epics under this project."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"epics":{"type":"array","items":{"$ref":"#/components/schemas/Epic"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Epics"],"summary":"Create an epic","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EpicCreate"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"epic":{"$ref":"#/components/schemas/Epic"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/epics/{id}":{"get":{"tags":["Epics"],"summary":"One epic","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The epic id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"epic":{"$ref":"#/components/schemas/Epic"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"tags":["Epics"],"summary":"Change an epic","description":"project takes null to detach the epic.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The epic id."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EpicPatch"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"epic":{"$ref":"#/components/schemas/Epic"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/{kind}/{id}/comments":{"get":{"tags":["Comments"],"summary":"Threads on an item","description":"Root comments oldest first, each with its replies. Clients never see internal-only threads.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["tasks","projects","epics"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The item id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"comments":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/Comment"},{"type":"object","properties":{"replies":{"type":"array","items":{"$ref":"#/components/schemas/Comment"}}}}]}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Comments"],"summary":"Add a comment or reply","description":"Mention people with @their@email or @First Last to notify them. parentId makes it a reply (one level). visibility is for Neurotic team tokens; replies inherit the root's.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["tasks","projects","epics"]}},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The item id."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["body"],"properties":{"body":{"type":"string","maxLength":5000},"parentId":{"type":"string","format":"uuid","nullable":true},"visibility":{"$ref":"#/components/schemas/Visibility"}}}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"comment":{"$ref":"#/components/schemas/Comment"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/perpetuals":{"get":{"tags":["Perpetuals"],"summary":"List perpetuals","description":"With each one's owner, assignees, next due moment and open run. Clients see client- and vendor-shared ones.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"perpetuals":{"type":"array","items":{"$ref":"#/components/schemas/Perpetual"}}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Perpetuals"],"summary":"Create a perpetual","description":"Neurotic team tokens only. Defaults: weekly on Friday (dueDay 5) at 17:00, reminders 3 days, 1 day and 2 hours before, owned by the caller, internal. The first run opens straight away.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PerpetualCreate"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"perpetual":{"$ref":"#/components/schemas/Perpetual"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Clients cannot create perpetuals.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/spaces/{slug}/perpetuals/{id}":{"get":{"tags":["Perpetuals"],"summary":"One perpetual","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The perpetual id."},{"name":"view","in":"query","schema":{"type":"string"},"description":"Neurotic team tokens only: view=client sees what the client sees; view=vendor what every vendor sees; view=vendor:Company what one vendor company sees."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"perpetual":{"$ref":"#/components/schemas/Perpetual"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"tags":["Perpetuals"],"summary":"Change a perpetual","description":"Neurotic team tokens only. Only the fields you send change; status pauses, ends or reactivates it. A changed schedule moves the open run when nothing has happened in it yet.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The perpetual id."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PerpetualPatch"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"perpetual":{"$ref":"#/components/schemas/Perpetual"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Clients cannot change perpetuals.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"delete":{"tags":["Perpetuals"],"summary":"Delete a perpetual","description":"Neurotic team tokens only. Removes it and its runs for good; tasks already created stay. Usually you want status: ended instead.","parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string"},"description":"The space's URL slug, e.g. acme."},{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"},"description":"The perpetual id."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"deleted":{"type":"string","format":"uuid"}}}}}},"400":{"description":"Bad input; the message names the field.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or revoked token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Clients cannot delete.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such item, or a space you are not on.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"An API token issued in the back office. Starts with npm_."}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"string"}},"example":{"error":"title is required."}},"Visibility":{"type":"string","enum":["internal","client","vendor"],"description":"internal: Neurotic only. client: Neurotic and the client. vendor: Neurotic, the client and the vendors in scope (see vendors). Clients and vendors cannot create internal items."},"Vendors":{"oneOf":[{"type":"array","items":{"type":"string"},"description":"Vendor company names that see the item."},{"type":"string","enum":["all"]}],"nullable":true,"description":"Only with visibility vendor: which vendor companies see it; \"all\" (or omitted) means every vendor on the space."},"Priority":{"type":"string","enum":["low","medium","high","urgent"]},"TaskType":{"type":"string","enum":["code","debug","design","document","research","meeting","other"]},"TaskSize":{"type":"string","enum":["xs","s","m","l","xl"],"nullable":true,"description":"Rough effort: xs hours, s a day, m days, l a week, xl weeks."},"Me":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"email":{"type":"string"},"name":{"type":"string","nullable":true},"kind":{"type":"string","enum":["internal","external"]},"internal":{"type":"boolean"},"admin":{"type":"boolean"}}},"SpaceSummary":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"slug":{"type":"string"},"name":{"type":"string"}}},"Column":{"type":"object","properties":{"key":{"type":"string"},"label":{"type":"string"},"hidden":{"type":"boolean"},"builtIn":{"type":"boolean"}}},"Person":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"email":{"type":"string"},"name":{"type":"string","nullable":true},"kind":{"type":"string","enum":["internal","external"],"nullable":true},"title":{"type":"string","nullable":true},"isManager":{"type":"boolean"},"isPrimaryContact":{"type":"boolean"}}},"Space":{"type":"object","properties":{"space":{"$ref":"#/components/schemas/SpaceSummary"},"columns":{"type":"array","items":{"$ref":"#/components/schemas/Column"}},"people":{"type":"array","items":{"$ref":"#/components/schemas/Person"}}}},"Parent":{"type":"object","nullable":true,"properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string","nullable":true}}},"Hold":{"type":"object","description":"A dated pause because the wait is on someone else (a late payment, a vendor, a client decision). Set and released in the app by the Neurotic team.","properties":{"reason":{"type":"string","enum":["client_payment","vendor","client_decision","other"]},"waitingOn":{"type":"string","example":"payment","description":"The reason in words."},"note":{"type":"string"},"since":{"type":"string","format":"date-time"}}},"Task":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"key":{"type":"string","example":"ACME-12","description":"Human key: space slug and number. For display; use id in URLs."},"number":{"type":"integer"},"title":{"type":"string"},"description":{"type":"string"},"status":{"type":"string"},"priority":{"$ref":"#/components/schemas/Priority"},"type":{"$ref":"#/components/schemas/TaskType"},"size":{"$ref":"#/components/schemas/TaskSize"},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"dueDate":{"type":"string","format":"date-time","nullable":true},"runner":{"type":"boolean","description":"A runner's dueDate is an estimate that rolls forward day by day while the task is open, so it is never late; once done, dueDate is the day it finished."},"estimateDueDate":{"type":"string","format":"date-time","nullable":true,"description":"The end date someone last set by hand. For a runner, the gap between this and today (or completedAt) is how far it has slipped; sending a new dueDate resets it."},"startedAt":{"type":"string","format":"date-time","nullable":true},"completedAt":{"type":"string","format":"date-time","nullable":true},"hold":{"allOf":[{"$ref":"#/components/schemas/Hold"}],"nullable":true,"description":"The open hold, or null. While held the item is waiting on someone else: it reads Held instead of Overdue, no warning or digest names it, and the days are not counted as late."},"heldDays":{"type":"integer","description":"Calendar days of finished holds. A fixed-date item's dueDate was moved forward by them on release; a runner's slip subtracts them."},"progress":{"type":"array","description":"Every column the task has landed in, newest first; the first entry is where it is now. from is null for the column it was created in.","items":{"type":"object","properties":{"from":{"type":"string","nullable":true},"to":{"type":"string"},"at":{"type":"string","format":"date-time"},"by":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/Person"}]}}}},"project":{"$ref":"#/components/schemas/Parent"},"epic":{"$ref":"#/components/schemas/Parent"},"perpetual":{"$ref":"#/components/schemas/Parent"},"assignees":{"type":"array","items":{"$ref":"#/components/schemas/Person"}},"reviewer":{"allOf":[{"$ref":"#/components/schemas/Person"}],"nullable":true,"description":"The one person who reviews the work, or null."},"attachments":{"type":"array","items":{"$ref":"#/components/schemas/Attachment"},"description":"Only on GET /tasks/{id}; lists leave it out."},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}},"TaskCreate":{"type":"object","description":"A task arrives with every column filled: title, type, size, priority, dueDate and at least one assignee are all required. Everything missing or wrong is reported in one error.","required":["title","type","size","priority","dueDate","assignees"],"properties":{"title":{"type":"string","maxLength":200},"description":{"type":"string"},"status":{"type":"string","default":"todo","description":"A column key from /columns."},"priority":{"$ref":"#/components/schemas/Priority"},"type":{"$ref":"#/components/schemas/TaskType"},"size":{"$ref":"#/components/schemas/TaskSize"},"visibility":{"allOf":[{"$ref":"#/components/schemas/Visibility"}],"default":"client","description":"Ignored for client and vendor tokens, which always create items at their own level."},"vendors":{"$ref":"#/components/schemas/Vendors"},"dueDate":{"type":"string","format":"date-time","description":"2026-11-09 or 2026-11-09T17:00:00Z. For a runner, the current estimate."},"runner":{"type":"boolean","description":"true when the end date is an estimate that should roll forward day by day until the task is done, so it is never late. Default true; send false for a fixed-date task."},"startedAt":{"type":"string","format":"date-time","description":"When work really started, for tasks logged after the fact. Otherwise stamped when the task first leaves To do."},"completedAt":{"type":"string","format":"date-time","description":"When it was really finished; only with status done. Otherwise stamped when it reaches Done. This is what On time / Late is judged on."},"project":{"type":"string","format":"uuid","nullable":true},"epic":{"type":"string","format":"uuid","nullable":true},"assignees":{"type":"array","minItems":1,"items":{"type":"string"},"description":"User ids or emails of people on the space's team (not suspended). At least one."},"reviewer":{"type":"string","nullable":true,"description":"User id or email of the one person on the space's team who reviews the work. Optional."}},"example":{"title":"Rotate the API keys","type":"code","priority":"high","size":"s","dueDate":"2026-11-15","assignees":["james@neurotic.co"]}},"TaskPatch":{"type":"object","properties":{"title":{"type":"string","maxLength":200},"description":{"type":"string"},"status":{"type":"string"},"priority":{"$ref":"#/components/schemas/Priority"},"type":{"$ref":"#/components/schemas/TaskType"},"size":{"$ref":"#/components/schemas/TaskSize"},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"dueDate":{"type":"string","format":"date-time","nullable":true},"runner":{"type":"boolean","description":"Make the task a runner (true) or a fixed-date task (false)."},"startedAt":{"type":"string","format":"date-time","description":"Sets when work really started."},"completedAt":{"type":"string","format":"date-time","description":"Sets when it was really finished; the task must be done."},"project":{"type":"string","format":"uuid","nullable":true},"epic":{"type":"string","format":"uuid","nullable":true},"assignees":{"type":"array","items":{"type":"string"}},"reviewer":{"type":"string","nullable":true,"description":"User id or email of the reviewer; null takes them off."}},"example":{"status":"in_progress"}},"Project":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string"},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"hold":{"allOf":[{"$ref":"#/components/schemas/Hold"}],"nullable":true,"description":"The open hold, or null. While held the item is waiting on someone else: it reads Held instead of Overdue, no warning or digest names it, and the days are not counted as late."},"heldDays":{"type":"integer","description":"Calendar days of finished holds. A fixed-date item's dueDate was moved forward by them on release; a runner's slip subtracts them."},"tasks":{"type":"object","properties":{"open":{"type":"integer"},"done":{"type":"integer"}}},"assignees":{"type":"array","items":{"$ref":"#/components/schemas/Person"}},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}},"ProjectCreate":{"type":"object","required":["name"],"properties":{"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","description":"A column key from /columns."},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"assignees":{"type":"array","items":{"type":"string"},"description":"User ids or emails of people on the space's team."}},"example":{"name":"Website redesign","status":"in_progress","visibility":"client","dueDate":"2026-12-14"}},"ProjectPatch":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","description":"A column key from /columns."},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"assignees":{"type":"array","items":{"type":"string"},"description":"User ids or emails of people on the space's team."}}},"Epic":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string"},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"project":{"$ref":"#/components/schemas/Parent"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"hold":{"allOf":[{"$ref":"#/components/schemas/Hold"}],"nullable":true,"description":"The open hold, or null. While held the item is waiting on someone else: it reads Held instead of Overdue, no warning or digest names it, and the days are not counted as late."},"heldDays":{"type":"integer","description":"Calendar days of finished holds. A fixed-date item's dueDate was moved forward by them on release; a runner's slip subtracts them."},"tasks":{"type":"object","properties":{"open":{"type":"integer"},"done":{"type":"integer"}}},"assignees":{"type":"array","items":{"$ref":"#/components/schemas/Person"}},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}},"EpicCreate":{"type":"object","required":["name"],"properties":{"name":{"type":"string"},"project":{"type":"string","format":"uuid","nullable":true},"description":{"type":"string"},"status":{"type":"string","description":"A column key from /columns."},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"assignees":{"type":"array","items":{"type":"string"},"description":"User ids or emails of people on the space's team."}}},"EpicPatch":{"type":"object","properties":{"name":{"type":"string"},"project":{"type":"string","format":"uuid","nullable":true},"description":{"type":"string"},"status":{"type":"string","description":"A column key from /columns."},"visibility":{"$ref":"#/components/schemas/Visibility"},"vendors":{"$ref":"#/components/schemas/Vendors"},"startDate":{"type":"string","format":"date-time","nullable":true},"dueDate":{"type":"string","format":"date-time","nullable":true},"assignees":{"type":"array","items":{"type":"string"},"description":"User ids or emails of people on the space's team."}}},"Cadence":{"type":"string","enum":["weekly","monthly","quarterly","biannual","annual"]},"Perpetual":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","enum":["active","paused","ended"]},"visibility":{"$ref":"#/components/schemas/Visibility"},"cadence":{"$ref":"#/components/schemas/Cadence"},"checkinCadence":{"allOf":[{"$ref":"#/components/schemas/Cadence"}],"nullable":true,"description":"A shorter cadence on which assignees check in; null means no separate check-ins."},"dueDay":{"type":"integer","description":"Weekly: 1 Monday … 7 Sunday. Otherwise the day of the month, 1–28."},"dueMonth":{"type":"integer","description":"Monthly and longer: the month (1–12) the cadence is anchored on."},"dueTime":{"type":"string","example":"17:00"},"timezone":{"type":"string","example":"Europe/London"},"schedule":{"type":"string","description":"The schedule in words.","example":"every Friday at 17:00"},"reminderOffsets":{"type":"array","items":{"type":"integer"},"description":"Minutes before the due moment a reminder goes out."},"remindByEmail":{"type":"boolean"},"notifyClient":{"type":"boolean"},"taskPerAssignee":{"type":"boolean"},"owner":{"allOf":[{"$ref":"#/components/schemas/Person"}],"nullable":true},"assignees":{"type":"array","items":{"$ref":"#/components/schemas/Person"}},"nextDueAt":{"type":"string","format":"date-time"},"currentCycle":{"type":"object","nullable":true,"properties":{"id":{"type":"string","format":"uuid"},"status":{"type":"string","enum":["open","done","missed"]},"periodStart":{"type":"string","format":"date-time"},"dueAt":{"type":"string","format":"date-time"}}},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}},"PerpetualCreate":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":120},"description":{"type":"string"},"cadence":{"allOf":[{"$ref":"#/components/schemas/Cadence"}],"default":"weekly"},"checkinCadence":{"allOf":[{"$ref":"#/components/schemas/Cadence"}],"nullable":true},"dueDay":{"type":"integer","default":5},"dueMonth":{"type":"integer","default":1},"dueTime":{"type":"string","default":"17:00"},"timezone":{"type":"string","default":"Europe/London"},"reminderOffsets":{"type":"array","items":{"type":"integer"},"default":[4320,1440,120]},"remindByEmail":{"type":"boolean","default":true},"notifyClient":{"type":"boolean","default":false},"taskPerAssignee":{"type":"boolean","default":true},"visibility":{"allOf":[{"$ref":"#/components/schemas/Visibility"}],"default":"internal"},"owner":{"type":"string","nullable":true,"description":"User id or email of someone on the space's team; null for nobody. Defaults to the caller."},"assignees":{"type":"array","items":{"type":"string"},"description":"User ids or emails of people on the space's team."}},"example":{"name":"Weekly status report","cadence":"weekly","dueDay":5,"dueTime":"16:00","assignees":["james@neurotic.co"]}},"PerpetualPatch":{"type":"object","properties":{"name":{"type":"string","maxLength":120},"description":{"type":"string"},"status":{"type":"string","enum":["active","paused","ended"]},"cadence":{"$ref":"#/components/schemas/Cadence"},"checkinCadence":{"allOf":[{"$ref":"#/components/schemas/Cadence"}],"nullable":true},"dueDay":{"type":"integer"},"dueMonth":{"type":"integer"},"dueTime":{"type":"string"},"timezone":{"type":"string"},"reminderOffsets":{"type":"array","items":{"type":"integer"}},"remindByEmail":{"type":"boolean"},"notifyClient":{"type":"boolean"},"taskPerAssignee":{"type":"boolean"},"visibility":{"$ref":"#/components/schemas/Visibility"},"owner":{"type":"string","nullable":true},"assignees":{"type":"array","items":{"type":"string"}}},"example":{"status":"paused"}},"Attachment":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"contentType":{"type":"string","example":"application/pdf"},"size":{"type":"integer","description":"Bytes."},"visibility":{"$ref":"#/components/schemas/Visibility"},"uploadedBy":{"allOf":[{"$ref":"#/components/schemas/Person"}],"nullable":true},"url":{"type":"string","example":"/api/attachments/8d0f…","description":"Path on this host that serves the bytes (Content-Disposition: attachment)."},"createdAt":{"type":"string","format":"date-time"}}},"AttachmentCreate":{"type":"object","required":["name","content"],"properties":{"name":{"type":"string","maxLength":200,"description":"The file name, extension included."},"content":{"type":"string","format":"byte","description":"The file's bytes as base64, 15 MB at most once decoded."},"contentType":{"type":"string","description":"MIME type; application/octet-stream when omitted."},"visibility":{"$ref":"#/components/schemas/Visibility"}},"example":{"name":"notes.txt","contentType":"text/plain","content":"SGVsbG8gd29ybGQ="}},"Comment":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"body":{"type":"string"},"status":{"type":"string","enum":["open","in_progress","stuck","resolved","cancelled"],"description":"Set in the app; read-only here."},"visibility":{"$ref":"#/components/schemas/Visibility"},"parentId":{"type":"string","format":"uuid","nullable":true},"author":{"allOf":[{"$ref":"#/components/schemas/Person"}],"nullable":true},"createdAt":{"type":"string","format":"date-time"}}}}}}