Skip to main content
A Task (Tarea in the app) is a piece of pending work that staff and client Members track for an Organization. A Task stands alone or relates to one or several records: Invoices, Bank Movements, or Ledger Entries. Use Tasks to leave yourself or your team a reminder, such as “Ask the client for the signed contract”, on the record it concerns. Tasks belong to the Organization, not to one Entity. A Task names an Entity only through the records it relates to, so one Task can relate to records of several Entities, and one list holds the Tasks of every Entity of the Organization. A Task moves through three states, can be assigned to a staff or client Member, can carry a due date and a description, and can hold subtasks. Tasks are independent of a record’s Follow-up. Setting or clearing one never changes the other.
Tasks replace To-dos. The routes moved from /api/entities/:entityId/todos to /api/organizations/:organizationId/tasks, the completed flag became status, and the error codes moved from TODO_* to TASK_*.
Every route below requires the staff or client Role in the Organization. A client Member works Tasks as staff does: they see every Task of the Organization and can create, edit, assign, and delete them. A viewer caller (session or API key) receives 403 with PERMISSION_DENIED_ERROR. An API key confined to one Entity also receives 403, because these routes act on the whole Organization. See Access and roles.
Open in the app. This resource has a page in the Sintropix web app at https://app.sintropix.com/organizations/{organizationId}/tasks, where each id in braces is the same UUID as in the API route or response. Add ?assignee=me for your own Tasks (Mías), ?view=board for the board (Tablero), or ?task={taskId} to open one Task in its detail panel. The sidebar offers Tareas both in an Entity and in Grupo. Related Tasks also appear in the panel of their Invoice, Bank Movement, or Ledger Entry. When you mention a record to a user, include that link. See Link to the App for the full URL grammar.

States

Sintropix sets completedAt for you. It stamps the moment a Task first becomes completed, keeps it when you send completed again, and clears it when the Task moves back to todo or in_progress.

Assignee and due date

A Task can be assigned to one staff or client Member of its Organization. A viewer can’t take a Task. List the Members a Task can take with GET /tasks/assignees. Assigning a User who isn’t a staff or client Member of the Organization is refused with 422 and TASK_ASSIGNEE_NOT_ASSIGNABLE_ERROR. When a Member leaves the Organization, their Tasks stay and become unassigned. dueDate is a calendar day, YYYY-MM-DD. Lists show the nearest due date first and the Tasks with no due date last. The assignee hears about their Tasks in the Bandeja:
  • Assigning a Task to another Member sends them a task_assigned Notification that names who assigned it. Assigning a Task to yourself, saving the same assignee again, or unassigning a Task notifies nobody.
  • When the due date of an assigned Task passes and the Task isn’t completed, the assignee gets one task_overdue Notification. Sintropix checks just after midnight in Santiago (Chile) time, so the Notification arrives on the day after the due date. If you move the due date and the new one passes too, the assignee is notified again.

Subtasks

A Task can hold subtasks (subtareas in the app), one level deep. Use them to split a piece of work into steps, such as one subtask per document you ask the client for. A subtask is an ordinary Task with a parent: it keeps its own state, assignee, due date, description, Task Links, and Notifications.
  • Create a subtask by sending parentTaskId when you create the Task. A Task can’t move under another parent later.
  • A subtask can’t hold subtasks. Naming a subtask as the parent is refused with 422 and TASK_PARENT_IS_SUBTASK_ERROR.
  • The parent must be a Task of the same Organization. Otherwise the create is refused with 404 and TASK_PARENT_NOT_FOUND_ERROR.
  • Deleting a Task deletes its subtasks too.
  • A parent and its subtasks change state independently. Completing a parent leaves its open subtasks as they are, and completing every subtask leaves the parent as it is. Read subtaskCount and completedSubtaskCount to show progress, such as “1/3”.
In the app, open a Task and type in Agregar subtarea to add one. In Todas, a parent shows its progress after its title, and clicking it unfolds its subtasks. In Mías, your subtasks sit under their parent too, and each top-level row falls in the band of its own state. A parent assigned to you starts folded and shows its full progress, and unfolding it shows only your subtasks. When none of its subtasks are yours, it shows its progress but doesn’t unfold. A parent assigned to someone else comes along to hold your subtasks: it starts unfolded, its title is muted, and you open and edit it like any other Task. To give a subtask a due date, hover its row in the Task’s panel and click the calendar beside its assignee. Completing a parent with open subtasks asks you to confirm, and deleting a parent tells you how many subtasks go with it.

The board

In the app, switch Tareas from Lista to Tablero to see the Tasks as a board, with one column per state: Por hacer, En progreso, and Completadas. Todas and Mías work the same on the board. The URL keeps the view, so a reload or a shared link opens the board again.
  • Each card shows the title and the assignee and, when the Task has them, its due date, its subtask progress, and its related records. A subtask is its own card, in the column of its own state, with its parent’s name above its title.
  • Drag a card to another column to change its state, or use the state menu on the card. A refused change shows the reason under the card. Moving a parent with open subtasks to Completadas asks you to confirm, as in the list.
  • You can’t reorder cards within a column. They keep the list’s order: nearest due date first.
  • Change a card’s due date or assignee on the card, delete it from the trash icon that shows on hover, and click it to open the Task’s detail panel.
A Task Link (Relación in the app) relates a Task to one record: an Invoice, a Bank Movement, or a Ledger Entry. A Task has any number of Task Links, and each record appears at most once per Task. Each Task Link names the Entity that holds its record, and that Entity must belong to the Task’s Organization. You relate records in two ways: When a related record goes away, Sintropix removes that Task Link and keeps the Task with its other links, or stand-alone if it has none left. This happens when you:
  • Delete the Invoice or the Bank Movement.
  • Unbook the Ledger Entry (its status becomes deleted).
  • Cancel the Scheduled Entry (its status becomes cancelled).
You cannot relate a Task to an Unbooked Ledger Entry or a cancelled Scheduled Entry. Task Links don’t change who the Task is assigned to or when it is due.
links replaces the single link a Task used to carry. The Task object no longer has entityId, invoiceId, bankMovementId, ledgerEntryId, or link, and a create sends its records in links instead of top-level ids.

The Task object

Each item of links describes one related record. kind tells you which kind of record it is, and id is the record’s id. Each kind carries the fields you need to display the record and open it in the app. Every kind carries these fields: Each kind adds its own fields:

GET /api/organizations/:organizationId/tasks

List the Tasks of the Organization, in every state and across every Entity. Subtasks are listed like any other Task, each with its parentTask. Pass one record filter to list only the Tasks related to that record. Pass assignee=me to keep only the Tasks assigned to you, the User of the session or of the API key. Tasks come ordered by dueDate, nearest first, with the Tasks that have no due date last. Ties go to the oldest Task first. Query parameters Send at most one record filter. Sending two returns 400. A Task matches when any of its Task Links names the record. assignee combines with a record filter. Response 200: an array of Task objects.

GET /api/organizations/:organizationId/tasks/assignees

List the staff and client Members of the Organization, the Users a Task can be assigned to. Viewers are not listed. Response 200: an array of { userId, name, image }, where image is a photo URL or null.

POST /api/organizations/:organizationId/tasks

Create a Task. It starts in todo, unassigned, with no due date and an empty description. You supply the id, so a retried request with the same id returns 409 instead of creating a duplicate. Body Each item of links names one record: Each item sends exactly one of invoiceId, bankMovementId, or ledgerEntryId. An item with none or several, or two items that name the same record, return 400. The items can name records of different Entities of the Organization. If one record is refused, no Task is created. Response 201: the created Task object, including links.

PATCH /api/organizations/:organizationId/tasks/:taskId

Edit the text or description of a Task, move it to another state, assign or unassign it, or set or clear its due date. Send at least one field. Body Response 200: the updated Task object.

POST /api/organizations/:organizationId/tasks/:taskId/links

Relate a Task to one more record. The body is one Task Link item, as in the links of a create: the entityId of the record’s Entity and exactly one of invoiceId, bankMovementId, or ledgerEntryId. Relating a record the Task already relates to changes nothing and returns the Task as it is. Response 201: the Task object, with every Task Link.

DELETE /api/organizations/:organizationId/tasks/:taskId/links/:taskLinkId

Remove one relation from a Task. Read taskLinkId from the Task’s links. The Task and the record stay. Response 200: the Task object, with its remaining Task Links.

DELETE /api/organizations/:organizationId/tasks/:taskId

Delete a Task permanently, with its subtasks and its Notifications. Response 200: the deleted Task object.

Errors

Task domain errors carry a code and a params object in the body.

Status codes