API Docs

Lists

How to create, update, delete and query lists in Blue.

List all Lists

To get a list of all lists in a project, you can use the following query:

query TodoLists {
  todoLists(projectId: "project-id") {
    id
    title
    position
  }
}

Create a List

You have to first query the project to get the list of lists and get the max position and then increment by a magic number (65535.0) to get the new position.

The magic number means that each list will be spaced out by a value of 65535.0, so the first list will be 65535.0, the second list will be 131070.0, and so on.

You can use the following mutation to create a new list:

mutation CreateTodoList {
  createTodoList(input: { projectId: "project-id", title: "New List", position: 65535 }) {
    id
  }
}

Update a List Name

To update a list name, you can use the following mutation:

mutation EditTodoList {
  todoList: editTodoList(input: { todoListId: "list-id", title: "new name" }) {
    id
    title
  }
}

Delete a List

To delete a list, you can use the following mutation:

mutation DeleteTodoList {
  deleteTodoList(input: { projectId: "project-id", todoListId: "list-id" }) {
    success
  }
}