KosmoKrator

productivity

Google Tasks CLI for AI Agents

Use the Google Tasks CLI from KosmoKrator to call Google Tasks tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

11 functions 9 read 2 write OAuth browser flow auth

Google Tasks CLI Setup

Google Tasks can be configured headlessly with `kosmokrator integrations:configure google_tasks`.

# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure google_tasks --set access_token="$GOOGLE_TASKS_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmokrator integrations:doctor google_tasks --json
kosmokrator integrations:status --json

Credentials

Authentication type: OAuth browser flow oauth2_authorization_code. Configure credentials once, then use the same stored profile from scripts, coding CLIs, Lua code mode, and the MCP gateway.

KeyEnv varTypeRequiredLabel
access_token GOOGLE_TASKS_ACCESS_TOKEN OAuth token oauth yes Google Account

Call Google Tasks Headlessly

Use the generic call form when another coding CLI or script needs a stable universal interface.

kosmo integrations:call google_tasks.google_tasks_clear_completed '{
  "list_id": "example_list_id"
}' --json

Use the provider shortcut form for shorter human-facing commands.

kosmo integrations:google_tasks google_tasks_clear_completed '{
  "list_id": "example_list_id"
}' --json

Agent Discovery Commands

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

kosmo integrations:docs google_tasks --json
kosmo integrations:docs google_tasks.google_tasks_clear_completed --json
kosmo integrations:schema google_tasks.google_tasks_clear_completed --json
kosmo integrations:search "Google Tasks" --json
kosmo integrations:list --json

All CLI Functions

Every function below can be called headlessly. The generic form is stable across all integrations; the provider shortcut is shorter but specific to Google Tasks.

google_tasks.google_tasks_clear_completed

Read read

Remove all completed tasks from a Google Tasks list. Warning: permanently deletes completed tasks.

Parameters
list_id

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_clear_completed '{"list_id":"example_list_id"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_clear_completed '{"list_id":"example_list_id"}' --json

google_tasks.google_tasks_complete

Read read

Mark a Google Task as completed.

Parameters
task_id, list_id

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_complete '{"task_id":"example_task_id","list_id":"example_list_id"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_complete '{"task_id":"example_task_id","list_id":"example_list_id"}' --json

google_tasks.google_tasks_create

Read read

Create a task in Google Tasks. Use "@default" as listId for the primary "My Tasks" list.

Parameters
title, list_id, notes, due, parent

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_create '{"title":"example_title","list_id":"example_list_id","notes":"example_notes","due":"example_due","parent":"example_parent"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_create '{"title":"example_title","list_id":"example_list_id","notes":"example_notes","due":"example_due","parent":"example_parent"}' --json

google_tasks.google_tasks_create_list

Write write

Create a new task list in Google Tasks.

Parameters
title

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_create_list '{"title":"example_title"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_create_list '{"title":"example_title"}' --json

google_tasks.google_tasks_delete

Read read

Delete a Google Task.

Parameters
task_id, list_id

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_delete '{"task_id":"example_task_id","list_id":"example_list_id"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_delete '{"task_id":"example_task_id","list_id":"example_list_id"}' --json

google_tasks.google_tasks_delete_list

Write write

Delete a task list from Google Tasks.

Parameters
list_id

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_delete_list '{"list_id":"example_list_id"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_delete_list '{"list_id":"example_list_id"}' --json

google_tasks.google_tasks_move

Read read

Reorder or reparent a Google Task. Use parent to set a new parent (empty string moves to top level), and previous to position after a sibling.

Parameters
task_id, list_id, parent, previous

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_move '{"task_id":"example_task_id","list_id":"example_list_id","parent":"example_parent","previous":"example_previous"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_move '{"task_id":"example_task_id","list_id":"example_list_id","parent":"example_parent","previous":"example_previous"}' --json

google_tasks.google_tasks_get_task

Read read

Get full details of a single Google Task by its ID.

Parameters
list_id, task_id

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_get_task '{"list_id":"example_list_id","task_id":"example_task_id"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_get_task '{"list_id":"example_list_id","task_id":"example_task_id"}' --json

google_tasks.google_tasks_list_lists

Read read

List all Google Task lists. Returns IDs and titles. Start here to discover available lists.

Parameters
max_results, page_token

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_list_lists '{"max_results":1,"page_token":"example_page_token"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_list_lists '{"max_results":1,"page_token":"example_page_token"}' --json

google_tasks.google_tasks_list_tasks

Read read

List tasks in a Google Task list. Use "@default" as listId for the primary "My Tasks" list. Supports filtering by completion status and due date range.

Parameters
list_id, show_completed, show_hidden, due_min, due_max, max_results, page_token

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_list_tasks '{"list_id":"example_list_id","show_completed":true,"show_hidden":true,"due_min":"example_due_min","due_max":"example_due_max","max_results":1,"page_token":"example_page_token"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_list_tasks '{"list_id":"example_list_id","show_completed":true,"show_hidden":true,"due_min":"example_due_min","due_max":"example_due_max","max_results":1,"page_token":"example_page_token"}' --json

google_tasks.google_tasks_update

Read read

Update task fields in Google Tasks. At least one field to update is required.

Parameters
task_id, list_id, title, notes, due, status

Generic CLI call

kosmo integrations:call google_tasks.google_tasks_update '{"task_id":"example_task_id","list_id":"example_list_id","title":"example_title","notes":"example_notes","due":"example_due","status":"example_status"}' --json

Provider shortcut

kosmo integrations:google_tasks google_tasks_update '{"task_id":"example_task_id","list_id":"example_list_id","title":"example_title","notes":"example_notes","due":"example_due","status":"example_status"}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

google_tasks.google_tasks_clear_completed

Remove all completed tasks from a Google Tasks list. Warning: permanently deletes completed tasks.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_clear_completed --json
ParameterTypeRequiredDescription
list_id string no Task list ID (default: "@default").

google_tasks.google_tasks_complete

Mark a Google Task as completed.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_complete --json
ParameterTypeRequiredDescription
task_id string yes Task ID to complete.
list_id string no Task list ID (default: "@default").

google_tasks.google_tasks_create

Create a task in Google Tasks. Use "@default" as listId for the primary "My Tasks" list.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_create --json
ParameterTypeRequiredDescription
title string yes Task title.
list_id string no Task list ID (default: "@default" for primary "My Tasks" list).
notes string no Task notes/description (max 8192 chars).
due string no Due date in YYYY-MM-DD format.
parent string no Parent task ID to create as subtask.

google_tasks.google_tasks_create_list

Create a new task list in Google Tasks.

Operation
Write write
Schema command
kosmo integrations:schema google_tasks.google_tasks_create_list --json
ParameterTypeRequiredDescription
title string yes Name for the new task list.

google_tasks.google_tasks_delete

Delete a Google Task.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_delete --json
ParameterTypeRequiredDescription
task_id string yes Task ID to delete.
list_id string no Task list ID (default: "@default").

google_tasks.google_tasks_delete_list

Delete a task list from Google Tasks.

Operation
Write write
Schema command
kosmo integrations:schema google_tasks.google_tasks_delete_list --json
ParameterTypeRequiredDescription
list_id string yes Task list ID to delete.

google_tasks.google_tasks_move

Reorder or reparent a Google Task. Use parent to set a new parent (empty string moves to top level), and previous to position after a sibling.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_move --json
ParameterTypeRequiredDescription
task_id string yes Task ID to move.
list_id string no Task list ID (default: "@default").
parent string no New parent task ID. Empty string moves to top level.
previous string no Sibling task ID to insert after.

google_tasks.google_tasks_get_task

Get full details of a single Google Task by its ID.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_get_task --json
ParameterTypeRequiredDescription
list_id string no Task list ID. Use "@default" for the primary "My Tasks" list.
task_id string yes Task ID to retrieve.

google_tasks.google_tasks_list_lists

List all Google Task lists. Returns IDs and titles. Start here to discover available lists.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_list_lists --json
ParameterTypeRequiredDescription
max_results integer no Maximum number of results (default: 100, max: 100).
page_token string no Page token for pagination (from previous response).

google_tasks.google_tasks_list_tasks

List tasks in a Google Task list. Use "@default" as listId for the primary "My Tasks" list. Supports filtering by completion status and due date range.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_list_tasks --json
ParameterTypeRequiredDescription
list_id string no Task list ID. Use "@default" for the primary "My Tasks" list.
show_completed boolean no Include completed tasks (default: false).
show_hidden boolean no Include hidden tasks (default: false).
due_min string no Filter tasks with due date on or after this date (YYYY-MM-DD).
due_max string no Filter tasks with due date on or before this date (YYYY-MM-DD).
max_results integer no Maximum number of results (default: 100, max: 100).
page_token string no Page token for pagination (from previous response).

google_tasks.google_tasks_update

Update task fields in Google Tasks. At least one field to update is required.

Operation
Read read
Schema command
kosmo integrations:schema google_tasks.google_tasks_update --json
ParameterTypeRequiredDescription
task_id string yes Task ID to update.
list_id string no Task list ID (default: "@default").
title string no New task title.
notes string no Task notes/description (max 8192 chars).
due string no Due date in YYYY-MM-DD format. Set empty string to clear.
status string no Task status: "needsAction" (open) or "completed".

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.