google-apis-tasks_v1 0.23.0 → 0.24.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d0001099e6adfaa98e2e37ff6783dbfe807c7de5312400f5c6fdbdf3ba32d0ef
4
- data.tar.gz: e376006a1fddfd7526c51b0514e40418674b2afb3c3f6fbf646d9374aa4f28af
3
+ metadata.gz: b443b2074a1da2630309336bc81f8bfd22b302720fe81df523ca3766d28800ed
4
+ data.tar.gz: cccfee2004c2ea6108d2ccd63a883889f5f27c59b0d1a503afc6820310721c23
5
5
  SHA512:
6
- metadata.gz: 83ffe5114a065b5e860054ed8db6746d3a1edde8c8ba1e10300a4c3f925a195a6d798da561880c04174d1d3760e5a7f75b9ac1d65ffcbe18024b6b209d410bf2
7
- data.tar.gz: fab295d991a97dd05d8afbb9d205e6c52f97f691be0c1f88e5cd8b8f0623fa7335d7698d82254458fd553440b739a2f5c2313cead21a6cd6afbabb9c064db4bc
6
+ metadata.gz: e98764156709345441f934adadd629929c054a45b46b480db58afd2a0a5ecce2d2c49e6a9b471b2d048ce10f26c9cffdc616e89ea6e1516ca63403900ced9d03
7
+ data.tar.gz: 4aee52f2417a155652a4201f421a73b05720608bbbcd66abd615e269ae1673dd8b69b226324a9f32fb13a0bc6c44a4d2ed4c7f1a635ac3b8ad9eef35b08348c6
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Release history for google-apis-tasks_v1
2
2
 
3
+ ### v0.24.0 (2024-07-07)
4
+
5
+ * Regenerated from discovery document revision 20240630
6
+
3
7
  ### v0.23.0 (2024-06-02)
4
8
 
5
9
  * Regenerated from discovery document revision 20240526
@@ -22,17 +22,114 @@ module Google
22
22
  module Apis
23
23
  module TasksV1
24
24
 
25
+ # Information about the source of the task assignment (Document, Chat Space).
26
+ class AssignmentInfo
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # Information about the Drive resource where a task was assigned from (the
30
+ # document, sheet, etc.).
31
+ # Corresponds to the JSON property `driveResourceInfo`
32
+ # @return [Google::Apis::TasksV1::DriveResourceInfo]
33
+ attr_accessor :drive_resource_info
34
+
35
+ # Output only. An absolute link to the original task in the surface of
36
+ # assignment (Docs, Chat spaces, etc.).
37
+ # Corresponds to the JSON property `linkToTask`
38
+ # @return [String]
39
+ attr_accessor :link_to_task
40
+
41
+ # Information about the Chat Space where a task was assigned from.
42
+ # Corresponds to the JSON property `spaceInfo`
43
+ # @return [Google::Apis::TasksV1::SpaceInfo]
44
+ attr_accessor :space_info
45
+
46
+ # Output only. The type of surface this assigned task originates from. Currently
47
+ # limited to DOCUMENT or SPACE.
48
+ # Corresponds to the JSON property `surfaceType`
49
+ # @return [String]
50
+ attr_accessor :surface_type
51
+
52
+ def initialize(**args)
53
+ update!(**args)
54
+ end
55
+
56
+ # Update properties of this object
57
+ def update!(**args)
58
+ @drive_resource_info = args[:drive_resource_info] if args.key?(:drive_resource_info)
59
+ @link_to_task = args[:link_to_task] if args.key?(:link_to_task)
60
+ @space_info = args[:space_info] if args.key?(:space_info)
61
+ @surface_type = args[:surface_type] if args.key?(:surface_type)
62
+ end
63
+ end
64
+
65
+ # Information about the Drive resource where a task was assigned from (the
66
+ # document, sheet, etc.).
67
+ class DriveResourceInfo
68
+ include Google::Apis::Core::Hashable
69
+
70
+ # Output only. Identifier of the file in the Drive API.
71
+ # Corresponds to the JSON property `driveFileId`
72
+ # @return [String]
73
+ attr_accessor :drive_file_id
74
+
75
+ # Output only. Resource key required to access files shared via a shared link.
76
+ # Not required for all files. See also developers.google.com/drive/api/guides/
77
+ # resource-keys.
78
+ # Corresponds to the JSON property `resourceKey`
79
+ # @return [String]
80
+ attr_accessor :resource_key
81
+
82
+ def initialize(**args)
83
+ update!(**args)
84
+ end
85
+
86
+ # Update properties of this object
87
+ def update!(**args)
88
+ @drive_file_id = args[:drive_file_id] if args.key?(:drive_file_id)
89
+ @resource_key = args[:resource_key] if args.key?(:resource_key)
90
+ end
91
+ end
92
+
93
+ # Information about the Chat Space where a task was assigned from.
94
+ class SpaceInfo
95
+ include Google::Apis::Core::Hashable
96
+
97
+ # Output only. The Chat space where this task originates from. The format is "
98
+ # spaces/`space`".
99
+ # Corresponds to the JSON property `space`
100
+ # @return [String]
101
+ attr_accessor :space
102
+
103
+ def initialize(**args)
104
+ update!(**args)
105
+ end
106
+
107
+ # Update properties of this object
108
+ def update!(**args)
109
+ @space = args[:space] if args.key?(:space)
110
+ end
111
+ end
112
+
25
113
  #
26
114
  class Task
27
115
  include Google::Apis::Core::Hashable
28
116
 
117
+ # Information about the source of the task assignment (Document, Chat Space).
118
+ # Corresponds to the JSON property `assignmentInfo`
119
+ # @return [Google::Apis::TasksV1::AssignmentInfo]
120
+ attr_accessor :assignment_info
121
+
29
122
  # Completion date of the task (as a RFC 3339 timestamp). This field is omitted
30
123
  # if the task has not been completed.
31
124
  # Corresponds to the JSON property `completed`
32
125
  # @return [String]
33
126
  attr_accessor :completed
34
127
 
35
- # Flag indicating whether the task has been deleted. The default is False.
128
+ # Flag indicating whether the task has been deleted. For assigned tasks this
129
+ # field is read-only. They can only be deleted by calling tasks.delete, in which
130
+ # case both the assigned task and the original task (in Docs or Chat Spaces) are
131
+ # deleted. To delete the assigned task only, navigate to the assignment surface
132
+ # and unassign the task from there. The default is False.
36
133
  # Corresponds to the JSON property `deleted`
37
134
  # @return [Boolean]
38
135
  attr_accessor :deleted
@@ -74,14 +171,16 @@ module Google
74
171
  # @return [Array<Google::Apis::TasksV1::Task::Link>]
75
172
  attr_accessor :links
76
173
 
77
- # Notes describing the task. Optional. Maximum length allowed: 8192 characters.
174
+ # Notes describing the task. Tasks assigned from Google Docs cannot have notes.
175
+ # Optional. Maximum length allowed: 8192 characters.
78
176
  # Corresponds to the JSON property `notes`
79
177
  # @return [String]
80
178
  attr_accessor :notes
81
179
 
82
180
  # Output only. Parent task identifier. This field is omitted if it is a top-
83
- # level task. This field is read-only. Use the "move" method to move the task
84
- # under a different parent or to the top level.
181
+ # level task. Use the "move" method to move the task under a different parent or
182
+ # to the top level. A parent task can never be an assigned task (from Chat
183
+ # Spaces, Docs). This field is read-only.
85
184
  # Corresponds to the JSON property `parent`
86
185
  # @return [String]
87
186
  attr_accessor :parent
@@ -128,6 +227,7 @@ module Google
128
227
 
129
228
  # Update properties of this object
130
229
  def update!(**args)
230
+ @assignment_info = args[:assignment_info] if args.key?(:assignment_info)
131
231
  @completed = args[:completed] if args.key?(:completed)
132
232
  @deleted = args[:deleted] if args.key?(:deleted)
133
233
  @due = args[:due] if args.key?(:due)
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module TasksV1
18
18
  # Version of the google-apis-tasks_v1 gem
19
- GEM_VERSION = "0.23.0"
19
+ GEM_VERSION = "0.24.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
22
  GENERATOR_VERSION = "0.15.0"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20240526"
25
+ REVISION = "20240630"
26
26
  end
27
27
  end
28
28
  end
@@ -22,6 +22,24 @@ module Google
22
22
  module Apis
23
23
  module TasksV1
24
24
 
25
+ class AssignmentInfo
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
31
+ class DriveResourceInfo
32
+ class Representation < Google::Apis::Core::JsonRepresentation; end
33
+
34
+ include Google::Apis::Core::JsonObjectSupport
35
+ end
36
+
37
+ class SpaceInfo
38
+ class Representation < Google::Apis::Core::JsonRepresentation; end
39
+
40
+ include Google::Apis::Core::JsonObjectSupport
41
+ end
42
+
25
43
  class Task
26
44
  class Representation < Google::Apis::Core::JsonRepresentation; end
27
45
 
@@ -52,9 +70,38 @@ module Google
52
70
  include Google::Apis::Core::JsonObjectSupport
53
71
  end
54
72
 
73
+ class AssignmentInfo
74
+ # @private
75
+ class Representation < Google::Apis::Core::JsonRepresentation
76
+ property :drive_resource_info, as: 'driveResourceInfo', class: Google::Apis::TasksV1::DriveResourceInfo, decorator: Google::Apis::TasksV1::DriveResourceInfo::Representation
77
+
78
+ property :link_to_task, as: 'linkToTask'
79
+ property :space_info, as: 'spaceInfo', class: Google::Apis::TasksV1::SpaceInfo, decorator: Google::Apis::TasksV1::SpaceInfo::Representation
80
+
81
+ property :surface_type, as: 'surfaceType'
82
+ end
83
+ end
84
+
85
+ class DriveResourceInfo
86
+ # @private
87
+ class Representation < Google::Apis::Core::JsonRepresentation
88
+ property :drive_file_id, as: 'driveFileId'
89
+ property :resource_key, as: 'resourceKey'
90
+ end
91
+ end
92
+
93
+ class SpaceInfo
94
+ # @private
95
+ class Representation < Google::Apis::Core::JsonRepresentation
96
+ property :space, as: 'space'
97
+ end
98
+ end
99
+
55
100
  class Task
56
101
  # @private
57
102
  class Representation < Google::Apis::Core::JsonRepresentation
103
+ property :assignment_info, as: 'assignmentInfo', class: Google::Apis::TasksV1::AssignmentInfo, decorator: Google::Apis::TasksV1::AssignmentInfo::Representation
104
+
58
105
  property :completed, as: 'completed'
59
106
  property :deleted, as: 'deleted'
60
107
  property :due, as: 'due'
@@ -51,7 +51,9 @@ module Google
51
51
  @batch_path = 'batch'
52
52
  end
53
53
 
54
- # Deletes the authenticated user's specified task list.
54
+ # Deletes the authenticated user's specified task list. If the list contains
55
+ # assigned tasks, both the assigned tasks and the original tasks in the
56
+ # assignment surface (Docs, Chat Spaces) are deleted.
55
57
  # @param [String] tasklist
56
58
  # Task list identifier.
57
59
  # @param [String] fields
@@ -272,7 +274,10 @@ module Google
272
274
  execute_or_queue_command(command, &block)
273
275
  end
274
276
 
275
- # Deletes the specified task from the task list.
277
+ # Deletes the specified task from the task list. If the task is assigned, both
278
+ # the assigned task and the original task (in Docs, Chat Spaces) are deleted. To
279
+ # delete the assigned task only, navigate to the assignment surface and unassign
280
+ # the task from there.
276
281
  # @param [String] tasklist
277
282
  # Task list identifier.
278
283
  # @param [String] task
@@ -336,14 +341,18 @@ module Google
336
341
  execute_or_queue_command(command, &block)
337
342
  end
338
343
 
339
- # Creates a new task on the specified task list. A user can have up to 20,000
340
- # non-hidden tasks per list and up to 100,000 tasks in total at a time.
344
+ # Creates a new task on the specified task list. Tasks assigned from Docs or
345
+ # Chat Spaces cannot be inserted from Tasks Public API; they can only be created
346
+ # by assigning them from Docs or Chat Spaces. A user can have up to 20,000 non-
347
+ # hidden tasks per list and up to 100,000 tasks in total at a time.
341
348
  # @param [String] tasklist
342
349
  # Task list identifier.
343
350
  # @param [Google::Apis::TasksV1::Task] task_object
344
351
  # @param [String] parent
345
352
  # Parent task identifier. If the task is created at the top level, this
346
- # parameter is omitted. Optional.
353
+ # parameter is omitted. An assigned task cannot be a parent task, nor can it
354
+ # have a parent. Setting the parent to an assigned task results in failure of
355
+ # the request. Optional.
347
356
  # @param [String] previous
348
357
  # Previous sibling task identifier. If the task is created at the first position
349
358
  # among its siblings, this parameter is omitted. Optional.
@@ -378,8 +387,9 @@ module Google
378
387
  execute_or_queue_command(command, &block)
379
388
  end
380
389
 
381
- # Returns all tasks in the specified task list. A user can have up to 20,000 non-
382
- # hidden tasks per list and up to 100,000 tasks in total at a time.
390
+ # Returns all tasks in the specified task list. Does not return assigned tasks
391
+ # be default (from Docs, Chat Spaces). A user can have up to 20,000 non-hidden
392
+ # tasks per list and up to 100,000 tasks in total at a time.
383
393
  # @param [String] tasklist
384
394
  # Task list identifier.
385
395
  # @param [String] completed_max
@@ -399,10 +409,13 @@ module Google
399
409
  # allowed: 100).
400
410
  # @param [String] page_token
401
411
  # Token specifying the result page to return. Optional.
412
+ # @param [Boolean] show_assigned
413
+ # Optional. Flag indicating whether tasks assigned to the current user are
414
+ # returned in the result. Optional. The default is False.
402
415
  # @param [Boolean] show_completed
403
- # Flag indicating whether completed tasks are returned in the result. Optional.
404
- # The default is True. Note that showHidden must also be True to show tasks
405
- # completed in first party clients, such as the web UI and Google's mobile apps.
416
+ # Flag indicating whether completed tasks are returned in the result. Note that
417
+ # showHidden must also be True to show tasks completed in first party clients,
418
+ # such as the web UI and Google's mobile apps. Optional. The default is True.
406
419
  # @param [Boolean] show_deleted
407
420
  # Flag indicating whether deleted tasks are returned in the result. Optional.
408
421
  # The default is False.
@@ -429,7 +442,7 @@ module Google
429
442
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
430
443
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
431
444
  # @raise [Google::Apis::AuthorizationError] Authorization is required
432
- def list_tasks(tasklist, completed_max: nil, completed_min: nil, due_max: nil, due_min: nil, max_results: nil, page_token: nil, show_completed: nil, show_deleted: nil, show_hidden: nil, updated_min: nil, fields: nil, quota_user: nil, options: nil, &block)
445
+ def list_tasks(tasklist, completed_max: nil, completed_min: nil, due_max: nil, due_min: nil, max_results: nil, page_token: nil, show_assigned: nil, show_completed: nil, show_deleted: nil, show_hidden: nil, updated_min: nil, fields: nil, quota_user: nil, options: nil, &block)
433
446
  command = make_simple_command(:get, 'tasks/v1/lists/{tasklist}/tasks', options)
434
447
  command.response_representation = Google::Apis::TasksV1::Tasks::Representation
435
448
  command.response_class = Google::Apis::TasksV1::Tasks
@@ -440,6 +453,7 @@ module Google
440
453
  command.query['dueMin'] = due_min unless due_min.nil?
441
454
  command.query['maxResults'] = max_results unless max_results.nil?
442
455
  command.query['pageToken'] = page_token unless page_token.nil?
456
+ command.query['showAssigned'] = show_assigned unless show_assigned.nil?
443
457
  command.query['showCompleted'] = show_completed unless show_completed.nil?
444
458
  command.query['showDeleted'] = show_deleted unless show_deleted.nil?
445
459
  command.query['showHidden'] = show_hidden unless show_hidden.nil?
@@ -449,17 +463,24 @@ module Google
449
463
  execute_or_queue_command(command, &block)
450
464
  end
451
465
 
452
- # Moves the specified task to another position in the task list. This can
453
- # include putting it as a child task under a new parent and/or move it to a
454
- # different position among its sibling tasks. A user can have up to 2,000
455
- # subtasks per task.
466
+ # Moves the specified task to another position in the destination task list. If
467
+ # the destination list is not specified, the task is moved within its current
468
+ # list. This can include putting it as a child task under a new parent and/or
469
+ # move it to a different position among its sibling tasks. A user can have up to
470
+ # 2,000 subtasks per task.
456
471
  # @param [String] tasklist
457
472
  # Task list identifier.
458
473
  # @param [String] task
459
474
  # Task identifier.
475
+ # @param [String] destination_tasklist
476
+ # Optional. Destination task list identifier. If set, the task is moved from
477
+ # tasklist to the destinationTasklist list. Otherwise the task is moved within
478
+ # its current list. Recurrent tasks cannot currently be moved between lists.
479
+ # Optional.
460
480
  # @param [String] parent
461
481
  # New parent task identifier. If the task is moved to the top level, this
462
- # parameter is omitted. Optional.
482
+ # parameter is omitted. Assigned tasks can not be set as parent task (have
483
+ # subtasks) or be moved under a parent task (become subtasks). Optional.
463
484
  # @param [String] previous
464
485
  # New previous sibling task identifier. If the task is moved to the first
465
486
  # position among its siblings, this parameter is omitted. Optional.
@@ -480,12 +501,13 @@ module Google
480
501
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
481
502
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
482
503
  # @raise [Google::Apis::AuthorizationError] Authorization is required
483
- def move_task(tasklist, task, parent: nil, previous: nil, fields: nil, quota_user: nil, options: nil, &block)
504
+ def move_task(tasklist, task, destination_tasklist: nil, parent: nil, previous: nil, fields: nil, quota_user: nil, options: nil, &block)
484
505
  command = make_simple_command(:post, 'tasks/v1/lists/{tasklist}/tasks/{task}/move', options)
485
506
  command.response_representation = Google::Apis::TasksV1::Task::Representation
486
507
  command.response_class = Google::Apis::TasksV1::Task
487
508
  command.params['tasklist'] = tasklist unless tasklist.nil?
488
509
  command.params['task'] = task unless task.nil?
510
+ command.query['destinationTasklist'] = destination_tasklist unless destination_tasklist.nil?
489
511
  command.query['parent'] = parent unless parent.nil?
490
512
  command.query['previous'] = previous unless previous.nil?
491
513
  command.query['fields'] = fields unless fields.nil?
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-tasks_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.0
4
+ version: 0.24.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-06-02 00:00:00.000000000 Z
11
+ date: 2024-07-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-tasks_v1/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-tasks_v1/v0.23.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-tasks_v1/v0.24.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-tasks_v1
63
63
  post_install_message:
64
64
  rdoc_options: []