asana 3.0.2 → 3.0.4

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 (82) hide show
  1. package/.github/workflows/publish.yaml +78 -38
  2. package/.swagger-codegen/VERSION +1 -1
  3. package/README.md +140 -29
  4. package/codegen/templates/README.mustache +129 -26
  5. package/codegen/templates/api.mustache +17 -15
  6. package/dist/ApiClient.js +6 -7
  7. package/dist/api/AllocationsApi.js +307 -0
  8. package/dist/api/AttachmentsApi.js +22 -95
  9. package/dist/api/AuditLogAPIApi.js +10 -14
  10. package/dist/api/BatchAPIApi.js +10 -14
  11. package/dist/api/CustomFieldSettingsApi.js +16 -23
  12. package/dist/api/CustomFieldsApi.js +38 -203
  13. package/dist/api/EventsApi.js +12 -16
  14. package/dist/api/GoalRelationshipsApi.js +26 -122
  15. package/dist/api/GoalsApi.js +48 -239
  16. package/dist/api/JobsApi.js +8 -32
  17. package/dist/api/MembershipsApi.js +73 -99
  18. package/dist/api/OrganizationExportsApi.js +12 -59
  19. package/dist/api/PortfolioMembershipsApi.js +20 -50
  20. package/dist/api/PortfoliosApi.js +56 -293
  21. package/dist/api/ProjectBriefsApi.js +20 -113
  22. package/dist/api/ProjectMembershipsApi.js +14 -41
  23. package/dist/api/ProjectStatusesApi.js +22 -95
  24. package/dist/api/ProjectTemplatesApi.js +28 -104
  25. package/dist/api/ProjectsApi.js +88 -446
  26. package/dist/api/RulesApi.js +8 -32
  27. package/dist/api/SectionsApi.js +34 -176
  28. package/dist/api/StatusUpdatesApi.js +22 -95
  29. package/dist/api/StoriesApi.js +26 -122
  30. package/dist/api/TagsApi.js +42 -167
  31. package/dist/api/TaskTemplatesApi.js +63 -72
  32. package/dist/api/TasksApi.js +173 -544
  33. package/dist/api/TeamMembershipsApi.js +26 -59
  34. package/dist/api/TeamsApi.js +36 -158
  35. package/dist/api/TimePeriodsApi.js +14 -41
  36. package/dist/api/TimeTrackingEntriesApi.js +26 -122
  37. package/dist/api/TypeaheadApi.js +12 -16
  38. package/dist/api/UserTaskListsApi.js +12 -59
  39. package/dist/api/UsersApi.js +32 -68
  40. package/dist/api/WebhooksApi.js +26 -122
  41. package/dist/api/WorkspaceMembershipsApi.js +20 -50
  42. package/dist/api/WorkspacesApi.js +26 -122
  43. package/dist/index.js +7 -0
  44. package/package.json +1 -1
  45. package/src/ApiClient.js +4 -4
  46. package/src/api/AllocationsApi.js +365 -0
  47. package/src/api/AttachmentsApi.js +42 -134
  48. package/src/api/AuditLogAPIApi.js +15 -17
  49. package/src/api/BatchAPIApi.js +15 -17
  50. package/src/api/CustomFieldSettingsApi.js +28 -32
  51. package/src/api/CustomFieldsApi.js +78 -290
  52. package/src/api/EventsApi.js +17 -19
  53. package/src/api/GoalRelationshipsApi.js +51 -173
  54. package/src/api/GoalsApi.js +100 -344
  55. package/src/api/JobsApi.js +11 -41
  56. package/src/api/MembershipsApi.js +105 -138
  57. package/src/api/OrganizationExportsApi.js +20 -80
  58. package/src/api/PortfolioMembershipsApi.js +37 -71
  59. package/src/api/PortfoliosApi.js +118 -422
  60. package/src/api/ProjectBriefsApi.js +38 -158
  61. package/src/api/ProjectMembershipsApi.js +24 -56
  62. package/src/api/ProjectStatusesApi.js +42 -134
  63. package/src/api/ProjectTemplatesApi.js +55 -149
  64. package/src/api/ProjectsApi.js +189 -647
  65. package/src/api/RulesApi.js +11 -41
  66. package/src/api/SectionsApi.js +69 -251
  67. package/src/api/StatusUpdatesApi.js +42 -134
  68. package/src/api/StoriesApi.js +51 -173
  69. package/src/api/TagsApi.js +86 -242
  70. package/src/api/TaskTemplatesApi.js +86 -95
  71. package/src/api/TasksApi.js +330 -799
  72. package/src/api/TeamMembershipsApi.js +50 -86
  73. package/src/api/TeamsApi.js +73 -227
  74. package/src/api/TimePeriodsApi.js +24 -56
  75. package/src/api/TimeTrackingEntriesApi.js +51 -173
  76. package/src/api/TypeaheadApi.js +17 -19
  77. package/src/api/UserTaskListsApi.js +20 -80
  78. package/src/api/UsersApi.js +63 -101
  79. package/src/api/WebhooksApi.js +51 -173
  80. package/src/api/WorkspaceMembershipsApi.js +37 -71
  81. package/src/api/WorkspacesApi.js +51 -173
  82. package/src/index.js +9 -2
@@ -7,7 +7,7 @@
7
7
  * NOTE: This class is auto generated by the swagger code generator program.
8
8
  * https://github.com/swagger-api/swagger-codegen.git
9
9
  *
10
- * Swagger Codegen version: 3.0.52
10
+ * Swagger Codegen version: 3.0.54
11
11
  *
12
12
  * Do not edit the class manually.
13
13
  *
@@ -18,7 +18,7 @@ var Collection = require('../utils/collection');
18
18
  /**
19
19
  * TaskTemplates service.
20
20
  * @module api/TaskTemplatesApi
21
- * @version 3.0.2
21
+ * @version 3.0.4
22
22
  */
23
23
  export class TaskTemplatesApi {
24
24
 
@@ -36,6 +36,59 @@ export class TaskTemplatesApi {
36
36
 
37
37
 
38
38
 
39
+ /**
40
+ * Delete a task template
41
+ * A specific, existing task template can be deleted by making a DELETE request on the URL for that task template. Returns an empty data record.
42
+ * @param {String} task_template_gid Globally unique identifier for the task template.
43
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data and HTTP response
44
+ */
45
+ deleteTaskTemplateWithHttpInfo(task_template_gid) {
46
+
47
+ let postBody = null;
48
+ // verify the required parameter 'task_template_gid' is set
49
+ if (task_template_gid === undefined || task_template_gid === null) {
50
+ throw new Error("Missing the required parameter 'task_template_gid' when calling deleteTaskTemplate");
51
+ }
52
+
53
+ let pathParams = {
54
+ 'task_template_gid': task_template_gid
55
+ };
56
+ let queryParams = {};
57
+
58
+ let headerParams = {
59
+
60
+ };
61
+ let formParams = {
62
+
63
+ };
64
+
65
+ let authNames = ['personalAccessToken'];
66
+ let contentTypes = [];
67
+ let accepts = ['application/json; charset=UTF-8'];
68
+ let returnType = 'Blob';
69
+
70
+ return this.apiClient.callApi(
71
+ '/task_templates/{task_template_gid}', 'DELETE',
72
+ pathParams, queryParams, headerParams, formParams, postBody,
73
+ authNames, contentTypes, accepts, returnType
74
+ );
75
+ }
76
+
77
+ /**
78
+ * Delete a task template
79
+ * A specific, existing task template can be deleted by making a DELETE request on the URL for that task template. Returns an empty data record.
80
+ * @param {<&vendorExtensions.x-jsdoc-type>} task_template_gid Globally unique identifier for the task template.
81
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/EmptyResponseData}
82
+ */
83
+ deleteTaskTemplate(task_template_gid) {
84
+
85
+ return this.deleteTaskTemplateWithHttpInfo(task_template_gid)
86
+ .then(function(response_and_data) {
87
+ return response_and_data.data;
88
+ });
89
+ }
90
+
91
+
39
92
  /**
40
93
  * Get a task template
41
94
  * Returns the complete task template record for a single task template.
@@ -71,36 +124,11 @@ export class TaskTemplatesApi {
71
124
  let accepts = ['application/json; charset=UTF-8'];
72
125
  let returnType = 'Blob';
73
126
 
74
- // Check if RETURN_COLLECTION is set and return a collection object if it is
75
- if (this.apiClient.RETURN_COLLECTION && false) {
76
- return Collection.fromApiClient(
77
- this.apiClient.callApi(
78
- '/task_templates/{task_template_gid}', 'GET',
79
- pathParams, queryParams, headerParams, formParams, postBody,
80
- authNames, contentTypes, accepts, returnType
81
- ),
82
- this.apiClient,
83
- {
84
- 'path': '/task_templates/{task_template_gid}',
85
- 'httpMethod': 'GET',
86
- 'pathParams': pathParams,
87
- 'queryParams': queryParams,
88
- 'headerParams': headerParams,
89
- 'formParams': formParams,
90
- 'bodyParam': postBody,
91
- 'authNames': authNames,
92
- 'contentTypes': contentTypes,
93
- 'accepts': accepts,
94
- 'returnType': returnType
95
- }
96
- )
97
- } else {
98
- return this.apiClient.callApi(
99
- '/task_templates/{task_template_gid}', 'GET',
100
- pathParams, queryParams, headerParams, formParams, postBody,
101
- authNames, contentTypes, accepts, returnType
102
- );
103
- }
127
+ return this.apiClient.callApi(
128
+ '/task_templates/{task_template_gid}', 'GET',
129
+ pathParams, queryParams, headerParams, formParams, postBody,
130
+ authNames, contentTypes, accepts, returnType
131
+ );
104
132
  }
105
133
 
106
134
  /**
@@ -113,15 +141,10 @@ export class TaskTemplatesApi {
113
141
  */
114
142
  getTaskTemplate(task_template_gid, opts) {
115
143
 
116
- // Check if RETURN_COLLECTION is set and return a collection object if it is
117
- if (this.apiClient.RETURN_COLLECTION && false) {
118
- return this.getTaskTemplateWithHttpInfo(task_template_gid, opts)
119
- } else {
120
- return this.getTaskTemplateWithHttpInfo(task_template_gid, opts)
121
- .then(function(response_and_data) {
122
- return response_and_data.data;
123
- });
124
- }
144
+ return this.getTaskTemplateWithHttpInfo(task_template_gid, opts)
145
+ .then(function(response_and_data) {
146
+ return response_and_data.data;
147
+ });
125
148
  }
126
149
 
127
150
 
@@ -157,9 +180,8 @@ export class TaskTemplatesApi {
157
180
  let contentTypes = [];
158
181
  let accepts = ['application/json; charset=UTF-8'];
159
182
  let returnType = 'Blob';
160
-
161
183
  // Check if RETURN_COLLECTION is set and return a collection object if it is
162
- if (this.apiClient.RETURN_COLLECTION && true) {
184
+ if (this.apiClient.RETURN_COLLECTION) {
163
185
  return Collection.fromApiClient(
164
186
  this.apiClient.callApi(
165
187
  '/task_templates', 'GET',
@@ -181,13 +203,13 @@ export class TaskTemplatesApi {
181
203
  'returnType': returnType
182
204
  }
183
205
  )
184
- } else {
185
- return this.apiClient.callApi(
186
- '/task_templates', 'GET',
187
- pathParams, queryParams, headerParams, formParams, postBody,
188
- authNames, contentTypes, accepts, returnType
189
- );
190
206
  }
207
+
208
+ return this.apiClient.callApi(
209
+ '/task_templates', 'GET',
210
+ pathParams, queryParams, headerParams, formParams, postBody,
211
+ authNames, contentTypes, accepts, returnType
212
+ );
191
213
  }
192
214
 
193
215
  /**
@@ -201,16 +223,15 @@ export class TaskTemplatesApi {
201
223
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TaskTemplateResponseArray}
202
224
  */
203
225
  getTaskTemplates(opts) {
204
-
205
226
  // Check if RETURN_COLLECTION is set and return a collection object if it is
206
- if (this.apiClient.RETURN_COLLECTION && true) {
207
- return this.getTaskTemplatesWithHttpInfo(opts)
208
- } else {
227
+ if (this.apiClient.RETURN_COLLECTION) {
209
228
  return this.getTaskTemplatesWithHttpInfo(opts)
210
- .then(function(response_and_data) {
211
- return response_and_data.data;
212
- });
213
229
  }
230
+
231
+ return this.getTaskTemplatesWithHttpInfo(opts)
232
+ .then(function(response_and_data) {
233
+ return response_and_data.data;
234
+ });
214
235
  }
215
236
 
216
237
 
@@ -250,36 +271,11 @@ export class TaskTemplatesApi {
250
271
  let accepts = ['application/json; charset=UTF-8'];
251
272
  let returnType = 'Blob';
252
273
 
253
- // Check if RETURN_COLLECTION is set and return a collection object if it is
254
- if (this.apiClient.RETURN_COLLECTION && false) {
255
- return Collection.fromApiClient(
256
- this.apiClient.callApi(
257
- '/task_templates/{task_template_gid}/instantiateTask', 'POST',
258
- pathParams, queryParams, headerParams, formParams, postBody,
259
- authNames, contentTypes, accepts, returnType
260
- ),
261
- this.apiClient,
262
- {
263
- 'path': '/task_templates/{task_template_gid}/instantiateTask',
264
- 'httpMethod': 'POST',
265
- 'pathParams': pathParams,
266
- 'queryParams': queryParams,
267
- 'headerParams': headerParams,
268
- 'formParams': formParams,
269
- 'bodyParam': postBody,
270
- 'authNames': authNames,
271
- 'contentTypes': contentTypes,
272
- 'accepts': accepts,
273
- 'returnType': returnType
274
- }
275
- )
276
- } else {
277
- return this.apiClient.callApi(
278
- '/task_templates/{task_template_gid}/instantiateTask', 'POST',
279
- pathParams, queryParams, headerParams, formParams, postBody,
280
- authNames, contentTypes, accepts, returnType
281
- );
282
- }
274
+ return this.apiClient.callApi(
275
+ '/task_templates/{task_template_gid}/instantiateTask', 'POST',
276
+ pathParams, queryParams, headerParams, formParams, postBody,
277
+ authNames, contentTypes, accepts, returnType
278
+ );
283
279
  }
284
280
 
285
281
  /**
@@ -293,15 +289,10 @@ export class TaskTemplatesApi {
293
289
  */
294
290
  instantiateTask(task_template_gid, opts) {
295
291
 
296
- // Check if RETURN_COLLECTION is set and return a collection object if it is
297
- if (this.apiClient.RETURN_COLLECTION && false) {
298
- return this.instantiateTaskWithHttpInfo(task_template_gid, opts)
299
- } else {
300
- return this.instantiateTaskWithHttpInfo(task_template_gid, opts)
301
- .then(function(response_and_data) {
302
- return response_and_data.data;
303
- });
304
- }
292
+ return this.instantiateTaskWithHttpInfo(task_template_gid, opts)
293
+ .then(function(response_and_data) {
294
+ return response_and_data.data;
295
+ });
305
296
  }
306
297
 
307
298
  }