I am trying to troubleshoot why I cannot get changes to Task titles, and dates, from google tasks, based on the query param updatedMin
:
In the following scenarios, all Changes made to tasks are done in Google Tasks flyout via calendar.google.com or done via the Android Tasks app.
Fail Scenarios
Fail Scenario 1:
I have a Task A in google Tasks with the Title of "foo"
I have a datetime called
lastSync
=2022-04-04T04:24:02.773Z
I then change a Task A's title to "bar" at
2022-04-04T04:25:12.773Z
- minute and 10 seconds greater thanlastSync
I then do the following query:
import { google, tasks_v1 } from "googleapis";
const taskClient = google.tasks({ version: "v1", auth: oauth2Client });
if (list.updated) {
const updated = GoogleTaskClient.dateFromRfc339(list.updated);
if (updated > lastSync) {
const res = await taskClient.tasks.list({
tasklist: list.id,
updatedMin: formatRFC3339(lastSync),
showHidden: true,
showDeleted: true,
showCompleted: true,
maxResults: 100,
});
}
- and the response has Zero items.
Fail Scenario 2:
I have a Task A in google Tasks with the Title of "foo"
I have a datetime called
lastSync
=2022-04-04T04:24:02.773Z
I then change Task A's date at
2022-04-04T04:25:12.773Z
- minute and 10 seconds greater thanlastSync
run the query
and the response has Zero items.
Success scenarios
Success Scenario 1:
I have a Task A in google Tasks with the Title of "foo"
I have a datetime called
lastSync
=2022-04-04T04:24:02.773Z
I then mark Task A as complete at
2022-04-04T04:25:12.773Z
- minute and 10 seconds greater thanlastSync
run the query
and the response includes Task A.
Success Scenario 2:
I have a Task A in google Tasks with the Title of "foo"
I have a datetime called
lastSync
=2022-04-04T04:24:02.773Z
I then change a Task A's title to "bar" at
2022-04-04T04:25:12.773Z
- minute and 10 seconds greater thanlastSync
I then change Task A's date at
2022-04-04T04:25:15.773Z
run the query
and the response has Task A with the changes.
Summary
Changing the status of a Task always results in it being returned by the query, but changes to Date and Title don't appear to work with updatedMin
.
Is this a known limitation of the task API - if so can you help me with some references.