@maxim_mazurok/gapi.client.tasks-v1 0.0.20240625 → 0.0.20240702

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.d.ts +39 -13
  2. package/package.json +1 -1
  3. package/readme.md +5 -5
package/index.d.ts CHANGED
@@ -9,7 +9,7 @@
9
9
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
10
10
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
11
11
  // Generated from: https://tasks.googleapis.com/$discovery/rest?version=v1
12
- // Revision: 20240625
12
+ // Revision: 20240702
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -24,10 +24,32 @@ declare namespace gapi.client {
24
24
  function load(name: 'tasks', version: 'v1', callback: () => any): void;
25
25
 
26
26
  namespace tasks {
27
+ interface AssignmentInfo {
28
+ /** Output only. Information about the Drive file where this task originates from. Currently, the Drive file can only be a document. This field is read-only. */
29
+ driveResourceInfo?: DriveResourceInfo;
30
+ /** Output only. An absolute link to the original task in the surface of assignment (Docs, Chat spaces, etc.). */
31
+ linkToTask?: string;
32
+ /** Output only. Information about the Chat Space where this task originates from. This field is read-only. */
33
+ spaceInfo?: SpaceInfo;
34
+ /** Output only. The type of surface this assigned task originates from. Currently limited to DOCUMENT or SPACE. */
35
+ surfaceType?: string;
36
+ }
37
+ interface DriveResourceInfo {
38
+ /** Output only. Identifier of the file in the Drive API. */
39
+ driveFileId?: string;
40
+ /** Output only. Resource key required to access files shared via a shared link. Not required for all files. See also developers.google.com/drive/api/guides/resource-keys. */
41
+ resourceKey?: string;
42
+ }
43
+ interface SpaceInfo {
44
+ /** Output only. The Chat space where this task originates from. The format is "spaces/{space}". */
45
+ space?: string;
46
+ }
27
47
  interface Task {
48
+ /** Output only. Context information for assigned tasks. A task can be assigned to a user, currently possible from surfaces like Docs and Chat Spaces. This field is populated for tasks assigned to the current user and identifies where the task was assigned from. This field is read-only. */
49
+ assignmentInfo?: AssignmentInfo;
28
50
  /** Completion date of the task (as a RFC 3339 timestamp). This field is omitted if the task has not been completed. */
29
51
  completed?: string;
30
- /** Flag indicating whether the task has been deleted. The default is False. */
52
+ /** Flag indicating whether the task has been deleted. For assigned tasks this field is read-only. They can only be deleted by calling tasks.delete, in which case both the assigned task and the original task (in Docs or Chat Spaces) are deleted. To delete the assigned task only, navigate to the assignment surface and unassign the task from there. The default is False. */
31
53
  deleted?: boolean;
32
54
  /** Due date of the task (as a RFC 3339 timestamp). Optional. The due date only records date information; the time portion of the timestamp is discarded when setting the due date. It isn't possible to read or write the time that a task is due via the API. */
33
55
  due?: string;
@@ -48,9 +70,9 @@ declare namespace gapi.client {
48
70
  /** Type of the link, e.g. "email". */
49
71
  type?: string;
50
72
  }>;
51
- /** Notes describing the task. Optional. Maximum length allowed: 8192 characters. */
73
+ /** Notes describing the task. Tasks assigned from Google Docs cannot have notes. Optional. Maximum length allowed: 8192 characters. */
52
74
  notes?: string;
53
- /** Output only. Parent task identifier. This field is omitted if it is a top-level task. This field is read-only. Use the "move" method to move the task under a different parent or to the top level. */
75
+ /** Output only. Parent task identifier. This field is omitted if it is a top-level task. Use the "move" method to move the task under a different parent or to the top level. A parent task can never be an assigned task (from Chat Spaces, Docs). This field is read-only. */
54
76
  parent?: string;
55
77
  /** Output only. String indicating the position of the task among its sibling tasks under the same parent task or at the top level. If this string is greater than another task's corresponding position string according to lexicographical ordering, the task is positioned after the other task under the same parent task (or at the top level). Use the "move" method to move the task to another position. */
56
78
  position?: string;
@@ -100,7 +122,7 @@ declare namespace gapi.client {
100
122
  nextPageToken?: string;
101
123
  }
102
124
  interface TasklistsResource {
103
- /** Deletes the authenticated user's specified task list. */
125
+ /** Deletes the authenticated user's specified task list. If the list contains assigned tasks, both the assigned tasks and the original tasks in the assignment surface (Docs, Chat Spaces) are deleted. */
104
126
  delete(request?: {
105
127
  /** V1 error format. */
106
128
  '$.xgafv'?: string;
@@ -382,7 +404,7 @@ declare namespace gapi.client {
382
404
  /** Legacy upload protocol for media (e.g. "media", "multipart"). */
383
405
  uploadType?: string;
384
406
  }): Request<void>;
385
- /** Deletes the specified task from the task list. */
407
+ /** Deletes the specified task from the task list. If the task is assigned, both the assigned task and the original task (in Docs, Chat Spaces) are deleted. To delete the assigned task only, navigate to the assignment surface and unassign the task from there. */
386
408
  delete(request?: {
387
409
  /** V1 error format. */
388
410
  '$.xgafv'?: string;
@@ -440,7 +462,7 @@ declare namespace gapi.client {
440
462
  /** Legacy upload protocol for media (e.g. "media", "multipart"). */
441
463
  uploadType?: string;
442
464
  }): Request<Task>;
443
- /** Creates a new task on the specified task list. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time. */
465
+ /** Creates a new task on the specified task list. Tasks assigned from Docs or Chat Spaces cannot be inserted from Tasks Public API; they can only be created by assigning them from Docs or Chat Spaces. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time. */
444
466
  insert(request: {
445
467
  /** V1 error format. */
446
468
  '$.xgafv'?: string;
@@ -456,7 +478,7 @@ declare namespace gapi.client {
456
478
  key?: string;
457
479
  /** OAuth 2.0 token for the current user. */
458
480
  oauth_token?: string;
459
- /** Parent task identifier. If the task is created at the top level, this parameter is omitted. Optional. */
481
+ /** Parent task identifier. If the task is created at the top level, this parameter is omitted. An assigned task cannot be a parent task, nor can it have a parent. Setting the parent to an assigned task results in failure of the request. Optional. */
460
482
  parent?: string;
461
483
  /** Returns response with indentations and line breaks. */
462
484
  prettyPrint?: boolean;
@@ -489,7 +511,7 @@ declare namespace gapi.client {
489
511
  key?: string;
490
512
  /** OAuth 2.0 token for the current user. */
491
513
  oauth_token?: string;
492
- /** Parent task identifier. If the task is created at the top level, this parameter is omitted. Optional. */
514
+ /** Parent task identifier. If the task is created at the top level, this parameter is omitted. An assigned task cannot be a parent task, nor can it have a parent. Setting the parent to an assigned task results in failure of the request. Optional. */
493
515
  parent?: string;
494
516
  /** Returns response with indentations and line breaks. */
495
517
  prettyPrint?: boolean;
@@ -506,7 +528,7 @@ declare namespace gapi.client {
506
528
  },
507
529
  body: Task
508
530
  ): Request<Task>;
509
- /** Returns all tasks in the specified task list. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time. */
531
+ /** Returns all tasks in the specified task list. Does not return assigned tasks be default (from Docs, Chat Spaces). A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time. */
510
532
  list(request?: {
511
533
  /** V1 error format. */
512
534
  '$.xgafv'?: string;
@@ -538,7 +560,9 @@ declare namespace gapi.client {
538
560
  prettyPrint?: boolean;
539
561
  /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
540
562
  quotaUser?: string;
541
- /** Flag indicating whether completed tasks are returned in the result. Optional. The default is True. Note that showHidden must also be True to show tasks completed in first party clients, such as the web UI and Google's mobile apps. */
563
+ /** Optional. Flag indicating whether tasks assigned to the current user are returned in the result. Optional. The default is False. */
564
+ showAssigned?: boolean;
565
+ /** Flag indicating whether completed tasks are returned in the result. Note that showHidden must also be True to show tasks completed in first party clients, such as the web UI and Google's mobile apps. Optional. The default is True. */
542
566
  showCompleted?: boolean;
543
567
  /** Flag indicating whether deleted tasks are returned in the result. Optional. The default is False. */
544
568
  showDeleted?: boolean;
@@ -553,7 +577,7 @@ declare namespace gapi.client {
553
577
  /** Legacy upload protocol for media (e.g. "media", "multipart"). */
554
578
  uploadType?: string;
555
579
  }): Request<Tasks>;
556
- /** Moves the specified task to another position in the task list. This can include putting it as a child task under a new parent and/or move it to a different position among its sibling tasks. A user can have up to 2,000 subtasks per task. */
580
+ /** Moves the specified task to another position in the destination task list. If the destination list is not specified, the task is moved within its current list. This can include putting it as a child task under a new parent and/or move it to a different position among its sibling tasks. A user can have up to 2,000 subtasks per task. */
557
581
  move(request?: {
558
582
  /** V1 error format. */
559
583
  '$.xgafv'?: string;
@@ -563,13 +587,15 @@ declare namespace gapi.client {
563
587
  alt?: string;
564
588
  /** JSONP */
565
589
  callback?: string;
590
+ /** Optional. Destination task list identifier. If set, the task is moved from tasklist to the destinationTasklist list. Otherwise the task is moved within its current list. Recurrent tasks cannot currently be moved between lists. Optional. */
591
+ destinationTasklist?: string;
566
592
  /** Selector specifying which fields to include in a partial response. */
567
593
  fields?: string;
568
594
  /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
569
595
  key?: string;
570
596
  /** OAuth 2.0 token for the current user. */
571
597
  oauth_token?: string;
572
- /** New parent task identifier. If the task is moved to the top level, this parameter is omitted. Optional. */
598
+ /** New parent task identifier. If the task is moved to the top level, this parameter is omitted. Assigned tasks can not be set as parent task (have subtasks) or be moved under a parent task (become subtasks). Optional. */
573
599
  parent?: string;
574
600
  /** Returns response with indentations and line breaks. */
575
601
  prettyPrint?: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.tasks-v1",
3
- "version": "0.0.20240625",
3
+ "version": "0.0.20240702",
4
4
  "description": "TypeScript typings for Google Tasks API v1",
5
5
  "repository": {
6
6
  "type": "git",
package/readme.md CHANGED
@@ -73,7 +73,7 @@ After that you can use Google Tasks API resources: <!-- TODO: make this work for
73
73
 
74
74
  ```typescript
75
75
  /*
76
- Deletes the authenticated user's specified task list.
76
+ Deletes the authenticated user's specified task list. If the list contains assigned tasks, both the assigned tasks and the original tasks in the assignment surface (Docs, Chat Spaces) are deleted.
77
77
  */
78
78
  await gapi.client.tasks.tasklists.delete({tasklist: 'tasklist'});
79
79
 
@@ -108,7 +108,7 @@ Clears all completed tasks from the specified task list. The affected tasks will
108
108
  await gapi.client.tasks.tasks.clear({tasklist: 'tasklist'});
109
109
 
110
110
  /*
111
- Deletes the specified task from the task list.
111
+ Deletes the specified task from the task list. If the task is assigned, both the assigned task and the original task (in Docs, Chat Spaces) are deleted. To delete the assigned task only, navigate to the assignment surface and unassign the task from there.
112
112
  */
113
113
  await gapi.client.tasks.tasks.delete({task: 'task', tasklist: 'tasklist'});
114
114
 
@@ -118,17 +118,17 @@ Returns the specified task.
118
118
  await gapi.client.tasks.tasks.get({task: 'task', tasklist: 'tasklist'});
119
119
 
120
120
  /*
121
- Creates a new task on the specified task list. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time.
121
+ Creates a new task on the specified task list. Tasks assigned from Docs or Chat Spaces cannot be inserted from Tasks Public API; they can only be created by assigning them from Docs or Chat Spaces. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time.
122
122
  */
123
123
  await gapi.client.tasks.tasks.insert({tasklist: 'tasklist'});
124
124
 
125
125
  /*
126
- Returns all tasks in the specified task list. A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time.
126
+ Returns all tasks in the specified task list. Does not return assigned tasks be default (from Docs, Chat Spaces). A user can have up to 20,000 non-hidden tasks per list and up to 100,000 tasks in total at a time.
127
127
  */
128
128
  await gapi.client.tasks.tasks.list({tasklist: 'tasklist'});
129
129
 
130
130
  /*
131
- Moves the specified task to another position in the task list. This can include putting it as a child task under a new parent and/or move it to a different position among its sibling tasks. A user can have up to 2,000 subtasks per task.
131
+ Moves the specified task to another position in the destination task list. If the destination list is not specified, the task is moved within its current list. This can include putting it as a child task under a new parent and/or move it to a different position among its sibling tasks. A user can have up to 2,000 subtasks per task.
132
132
  */
133
133
  await gapi.client.tasks.tasks.move({task: 'task', tasklist: 'tasklist'});
134
134