Rolebase Developers
API Reference

task

Represents a task or to-do item in Rolebase. Tasks are associated with circles, can be assigned to members, and support tracking progress with statuses and due dates.

Fields

FieldTypeDescription
iduuidUnique identifier for the task (auto-generated)
orgIduuidReference to the organization this task belongs to
circleIduuidReference to the circle this task is associated with
memberIduuidReference to the assigned member (optional)
titleStringTitle of the task
descriptionStringDetailed description of the task
statusTask_Status_EnumCurrent status: Open, InProgress, InReview, Blocked, or Done
dueDateTimestampWhen the task is due (optional)
createdAtTimestampWhen the task was created (defaults to current timestamp)
archivedBooleanWhether the task is archived (defaults to false)
privateBooleanWhether the task is private (defaults to false)

Task Status

The status field accepts the following enum values:

  • Open β€” Task is open and active
  • InProgress β€” Task is currently being worked on
  • InReview β€” Task is under review
  • Blocked β€” Task is blocked by another task or issue
  • Done β€” Task has been completed

Relationships

Object Relationships

  • org β€” The organization this task belongs to
  • circle β€” The circle this task is associated with
  • member β€” The member assigned to this task (if any)

Array Relationships

  • logs β€” Activity logs tracking changes to this task

Query Examples

List Tasks for an Organization

query GetTasks($orgId: uuid!) {
  task(where: { orgId: { _eq: $orgId } }) {
    id
    title
    description
    status
    dueDate
    circle {
      role {
        name
      }
    }
    member {
      name
    }
    logs {
      createdAt
      display
      changes
    }
  }
}

Get a Specific Task

query GetTask($id: uuid!) {
  task_by_pk(id: $id) {
    id
    title
    description
    status
    dueDate
    circle {
      role {
        name
      }
    }
    member {
      name
    }
  }
}

Mutation Examples

Create a Task

mutation CreateTask {
  insert_task_one(
    object: {
      orgId: "your-org-id"
      circleId: "circle-id"
      title: "Implement new feature"
      description: "Add user authentication to the app"
      status: Open
      dueDate: "2024-01-15T00:00:00Z"
      memberId: "assigned-member-id"
    }
  ) {
    id
    title
    status
  }
}

Update a Task

mutation UpdateTask {
  update_task_by_pk(
    pk_columns: { id: "task-id" }
    _set: { status: InProgress, description: "Updated task description" }
  ) {
    id
    status
    description
  }
}

Permissions

Task access is controlled by several factors:

  • Circle membership β€” Circle participants can access their circle’s tasks
  • Privacy settings β€” Private tasks are only visible to assigned members and circle participants
  • Organization role β€” Organization members can access non-private tasks
  • Assignment β€” Assigned members always have access to their tasks

Tasks can be organized into custom views using the task_view entity. Activity logs automatically track changes to task status and assignments.