description:'The project you want to operate on. Choose from the list, or specify an ID.',
},
{
displayName:'Section Name or ID',
name:'section',
type:'options',
typeOptions:{
loadOptionsMethod:'getSections',
loadOptionsDependsOn:['project.value'],
},
displayOptions:{
show:{
resource:['task'],
operation:['move'],
},
},
default:'',
description:
'Section to which you want move the task. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
{
displayName:'Label Names or IDs',
name:'labels',
type:'multiOptions',
typeOptions:{
loadOptionsMethod:'getLabels',
},
displayOptions:{
show:{
resource:['task'],
operation:['create'],
},
},
default:[],
description:
'Optional labels that will be assigned to a created task. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
{
displayName:'Content',
name:'content',
type:'string',
typeOptions:{
rows: 5,
},
displayOptions:{
show:{
resource:['task'],
operation:['create'],
},
},
default:'',
required: true,
description:'Task content',
},
{
displayName:'Sync Commands',
name:'commands',
type:'string',
displayOptions:{
show:{
resource:['task'],
operation:['sync'],
},
},
default:'[]',
hint:'See docs for possible commands: https://developer.todoist.com/sync/v8/#sync',
'The parent task you want to operate on. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
{
displayName:'Priority',
name:'priority',
type:'number',
typeOptions:{
maxValue: 4,
minValue: 1,
},
default:1,
description:'Task priority from 1 (normal) to 4 (urgent)',
},
{
displayName:'Section Name or ID',
name:'section',
type:'options',
typeOptions:{
loadOptionsMethod:'getSections',
loadOptionsDependsOn:['project.value'],
},
default:{},
description:
'The section you want to operate on. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
],
},
{
displayName:'Return All',
name:'returnAll',
type:'boolean',
displayOptions:{
show:{
operation:['getAll'],
resource:['task'],
},
},
default:false,
description:'Whether to return all results or only up to a given limit',
'Filter tasks by parent task ID. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
{
displayName:'Project Name or ID',
name:'projectId',
type:'options',
typeOptions:{
loadOptionsMethod:'getProjects',
},
default:'',
description:
'Filter tasks by project ID. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
{
displayName:'Section Name or ID',
name:'sectionId',
type:'options',
typeOptions:{
loadOptionsMethod:'getSections',
loadOptionsDependsOn:['filters.projectId'],
},
default:'',
description:
'Filter tasks by section ID. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.',
},
],
},
{
displayName:'Update Fields',
name:'updateFields',
type:'collection',
placeholder:'Add Field',
default:{},
displayOptions:{
show:{
resource:['task'],
operation:['update'],
},
},
options:[
{
displayName:'Content',
name:'content',
type:'string',
default:'',
description:'Task content',
},
{
displayName:'Description',
name:'description',
type:'string',
default:'',
description:'A description for the task',
},
{
displayName:'Due Date Time',
name:'dueDateTime',
type:'dateTime',
default:'',
description:'Specific date and time in RFC3339 format in UTC',
},
{
displayName:'Due String Locale',
name:'dueLang',
type:'string',
default:'',
description:
'2-letter code specifying language in case due_string is not written in English',
},
{
displayName:'Due String',
name:'dueString',
type:'string',
default:'',
description:
'Human defined task due date (ex.: “next Monday”, “Tomorrow”). Value is set using local (not UTC) time.',
},
{
displayName:'Due String Locale',
name:'dueLang',
type:'string',
default:'',
description:
'2-letter code specifying language in case due_string is not written in English',
},
{
displayName:'Label Names or IDs',
name:'labels',
type:'multiOptions',
description:
'Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>',
typeOptions:{
loadOptionsMethod:'getLabels',
},
default:[],
},
{
displayName:'Priority',
name:'priority',
type:'number',
typeOptions:{
maxValue: 4,
minValue: 1,
},
default:1,
description:'Task priority from 1 (normal) to 4 (urgent)',