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
@@ -9,7 +9,7 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
9
9
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
10
10
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
11
11
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
12
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
12
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
13
13
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /*
14
14
  * Asana
15
15
  * This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml).
@@ -19,7 +19,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
19
19
  * NOTE: This class is auto generated by the swagger code generator program.
20
20
  * https://github.com/swagger-api/swagger-codegen.git
21
21
  *
22
- * Swagger Codegen version: 3.0.52
22
+ * Swagger Codegen version: 3.0.54
23
23
  *
24
24
  * Do not edit the class manually.
25
25
  *
@@ -29,7 +29,7 @@ var Collection = require('../utils/collection');
29
29
  /**
30
30
  * BatchAPI service.
31
31
  * @module api/BatchAPIApi
32
- * @version 3.0.2
32
+ * @version 3.0.4
33
33
  */
34
34
  var BatchAPIApi = exports.BatchAPIApi = /*#__PURE__*/function () {
35
35
  /**
@@ -53,7 +53,7 @@ var BatchAPIApi = exports.BatchAPIApi = /*#__PURE__*/function () {
53
53
  * @param {Array.<module:model/String>} opts.opt_fields This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include.
54
54
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data and HTTP response
55
55
  */
56
- _createClass(BatchAPIApi, [{
56
+ return _createClass(BatchAPIApi, [{
57
57
  key: "createBatchRequestWithHttpInfo",
58
58
  value: function createBatchRequestWithHttpInfo(body, opts) {
59
59
  opts = opts || {};
@@ -72,9 +72,8 @@ var BatchAPIApi = exports.BatchAPIApi = /*#__PURE__*/function () {
72
72
  var contentTypes = ['application/json; charset=UTF-8'];
73
73
  var accepts = ['application/json; charset=UTF-8'];
74
74
  var returnType = 'Blob';
75
-
76
75
  // Check if RETURN_COLLECTION is set and return a collection object if it is
77
- if (this.apiClient.RETURN_COLLECTION && true) {
76
+ if (this.apiClient.RETURN_COLLECTION) {
78
77
  return Collection.fromApiClient(this.apiClient.callApi('/batch', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
79
78
  'path': '/batch',
80
79
  'httpMethod': 'POST',
@@ -88,9 +87,8 @@ var BatchAPIApi = exports.BatchAPIApi = /*#__PURE__*/function () {
88
87
  'accepts': accepts,
89
88
  'returnType': returnType
90
89
  });
91
- } else {
92
- return this.apiClient.callApi('/batch', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
93
90
  }
91
+ return this.apiClient.callApi('/batch', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
94
92
  }
95
93
 
96
94
  /**
@@ -105,14 +103,12 @@ var BatchAPIApi = exports.BatchAPIApi = /*#__PURE__*/function () {
105
103
  key: "createBatchRequest",
106
104
  value: function createBatchRequest(body, opts) {
107
105
  // Check if RETURN_COLLECTION is set and return a collection object if it is
108
- if (this.apiClient.RETURN_COLLECTION && true) {
106
+ if (this.apiClient.RETURN_COLLECTION) {
109
107
  return this.createBatchRequestWithHttpInfo(body, opts);
110
- } else {
111
- return this.createBatchRequestWithHttpInfo(body, opts).then(function (response_and_data) {
112
- return response_and_data.data;
113
- });
114
108
  }
109
+ return this.createBatchRequestWithHttpInfo(body, opts).then(function (response_and_data) {
110
+ return response_and_data.data;
111
+ });
115
112
  }
116
113
  }]);
117
- return BatchAPIApi;
118
114
  }();
@@ -9,7 +9,7 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
9
9
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
10
10
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
11
11
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
12
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
12
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
13
13
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /*
14
14
  * Asana
15
15
  * This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml).
@@ -19,7 +19,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
19
19
  * NOTE: This class is auto generated by the swagger code generator program.
20
20
  * https://github.com/swagger-api/swagger-codegen.git
21
21
  *
22
- * Swagger Codegen version: 3.0.52
22
+ * Swagger Codegen version: 3.0.54
23
23
  *
24
24
  * Do not edit the class manually.
25
25
  *
@@ -29,7 +29,7 @@ var Collection = require('../utils/collection');
29
29
  /**
30
30
  * CustomFieldSettings service.
31
31
  * @module api/CustomFieldSettingsApi
32
- * @version 3.0.2
32
+ * @version 3.0.4
33
33
  */
34
34
  var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/function () {
35
35
  /**
@@ -55,7 +55,7 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
55
55
  * @param {Array.<module:model/String>} opts.opt_fields This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include.
56
56
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data and HTTP response
57
57
  */
58
- _createClass(CustomFieldSettingsApi, [{
58
+ return _createClass(CustomFieldSettingsApi, [{
59
59
  key: "getCustomFieldSettingsForPortfolioWithHttpInfo",
60
60
  value: function getCustomFieldSettingsForPortfolioWithHttpInfo(portfolio_gid, opts) {
61
61
  opts = opts || {};
@@ -76,9 +76,8 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
76
76
  var contentTypes = [];
77
77
  var accepts = ['application/json; charset=UTF-8'];
78
78
  var returnType = 'Blob';
79
-
80
79
  // Check if RETURN_COLLECTION is set and return a collection object if it is
81
- if (this.apiClient.RETURN_COLLECTION && true) {
80
+ if (this.apiClient.RETURN_COLLECTION) {
82
81
  return Collection.fromApiClient(this.apiClient.callApi('/portfolios/{portfolio_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
83
82
  'path': '/portfolios/{portfolio_gid}/custom_field_settings',
84
83
  'httpMethod': 'GET',
@@ -92,9 +91,8 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
92
91
  'accepts': accepts,
93
92
  'returnType': returnType
94
93
  });
95
- } else {
96
- return this.apiClient.callApi('/portfolios/{portfolio_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
97
94
  }
95
+ return this.apiClient.callApi('/portfolios/{portfolio_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
98
96
  }
99
97
 
100
98
  /**
@@ -111,13 +109,12 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
111
109
  key: "getCustomFieldSettingsForPortfolio",
112
110
  value: function getCustomFieldSettingsForPortfolio(portfolio_gid, opts) {
113
111
  // Check if RETURN_COLLECTION is set and return a collection object if it is
114
- if (this.apiClient.RETURN_COLLECTION && true) {
112
+ if (this.apiClient.RETURN_COLLECTION) {
115
113
  return this.getCustomFieldSettingsForPortfolioWithHttpInfo(portfolio_gid, opts);
116
- } else {
117
- return this.getCustomFieldSettingsForPortfolioWithHttpInfo(portfolio_gid, opts).then(function (response_and_data) {
118
- return response_and_data.data;
119
- });
120
114
  }
115
+ return this.getCustomFieldSettingsForPortfolioWithHttpInfo(portfolio_gid, opts).then(function (response_and_data) {
116
+ return response_and_data.data;
117
+ });
121
118
  }
122
119
 
123
120
  /**
@@ -151,9 +148,8 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
151
148
  var contentTypes = [];
152
149
  var accepts = ['application/json; charset=UTF-8'];
153
150
  var returnType = 'Blob';
154
-
155
151
  // Check if RETURN_COLLECTION is set and return a collection object if it is
156
- if (this.apiClient.RETURN_COLLECTION && true) {
152
+ if (this.apiClient.RETURN_COLLECTION) {
157
153
  return Collection.fromApiClient(this.apiClient.callApi('/projects/{project_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
158
154
  'path': '/projects/{project_gid}/custom_field_settings',
159
155
  'httpMethod': 'GET',
@@ -167,9 +163,8 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
167
163
  'accepts': accepts,
168
164
  'returnType': returnType
169
165
  });
170
- } else {
171
- return this.apiClient.callApi('/projects/{project_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
172
166
  }
167
+ return this.apiClient.callApi('/projects/{project_gid}/custom_field_settings', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
173
168
  }
174
169
 
175
170
  /**
@@ -186,14 +181,12 @@ var CustomFieldSettingsApi = exports.CustomFieldSettingsApi = /*#__PURE__*/funct
186
181
  key: "getCustomFieldSettingsForProject",
187
182
  value: function getCustomFieldSettingsForProject(project_gid, opts) {
188
183
  // Check if RETURN_COLLECTION is set and return a collection object if it is
189
- if (this.apiClient.RETURN_COLLECTION && true) {
184
+ if (this.apiClient.RETURN_COLLECTION) {
190
185
  return this.getCustomFieldSettingsForProjectWithHttpInfo(project_gid, opts);
191
- } else {
192
- return this.getCustomFieldSettingsForProjectWithHttpInfo(project_gid, opts).then(function (response_and_data) {
193
- return response_and_data.data;
194
- });
195
186
  }
187
+ return this.getCustomFieldSettingsForProjectWithHttpInfo(project_gid, opts).then(function (response_and_data) {
188
+ return response_and_data.data;
189
+ });
196
190
  }
197
191
  }]);
198
- return CustomFieldSettingsApi;
199
192
  }();
@@ -9,7 +9,7 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
9
9
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
10
10
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
11
11
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
12
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
12
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
13
13
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); } /*
14
14
  * Asana
15
15
  * This is the interface for interacting with the [Asana Platform](https://developers.asana.com). Our API reference is generated from our [OpenAPI spec] (https://raw.githubusercontent.com/Asana/openapi/master/defs/asana_oas.yaml).
@@ -19,7 +19,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
19
19
  * NOTE: This class is auto generated by the swagger code generator program.
20
20
  * https://github.com/swagger-api/swagger-codegen.git
21
21
  *
22
- * Swagger Codegen version: 3.0.52
22
+ * Swagger Codegen version: 3.0.54
23
23
  *
24
24
  * Do not edit the class manually.
25
25
  *
@@ -29,7 +29,7 @@ var Collection = require('../utils/collection');
29
29
  /**
30
30
  * CustomFields service.
31
31
  * @module api/CustomFieldsApi
32
- * @version 3.0.2
32
+ * @version 3.0.4
33
33
  */
34
34
  var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
35
35
  /**
@@ -53,7 +53,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
53
53
  * @param {Array.<module:model/String>} opts.opt_fields This endpoint returns a compact resource, which excludes some properties by default. To include those optional properties, set this query parameter to a comma-separated list of the properties you wish to include.
54
54
  * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data and HTTP response
55
55
  */
56
- _createClass(CustomFieldsApi, [{
56
+ return _createClass(CustomFieldsApi, [{
57
57
  key: "createCustomFieldWithHttpInfo",
58
58
  value: function createCustomFieldWithHttpInfo(body, opts) {
59
59
  opts = opts || {};
@@ -72,25 +72,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
72
72
  var contentTypes = ['application/json; charset=UTF-8'];
73
73
  var accepts = ['application/json; charset=UTF-8'];
74
74
  var returnType = 'Blob';
75
-
76
- // Check if RETURN_COLLECTION is set and return a collection object if it is
77
- if (this.apiClient.RETURN_COLLECTION && false) {
78
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
79
- 'path': '/custom_fields',
80
- 'httpMethod': 'POST',
81
- 'pathParams': pathParams,
82
- 'queryParams': queryParams,
83
- 'headerParams': headerParams,
84
- 'formParams': formParams,
85
- 'bodyParam': postBody,
86
- 'authNames': authNames,
87
- 'contentTypes': contentTypes,
88
- 'accepts': accepts,
89
- 'returnType': returnType
90
- });
91
- } else {
92
- return this.apiClient.callApi('/custom_fields', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
93
- }
75
+ return this.apiClient.callApi('/custom_fields', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
94
76
  }
95
77
 
96
78
  /**
@@ -104,14 +86,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
104
86
  }, {
105
87
  key: "createCustomField",
106
88
  value: function createCustomField(body, opts) {
107
- // Check if RETURN_COLLECTION is set and return a collection object if it is
108
- if (this.apiClient.RETURN_COLLECTION && false) {
109
- return this.createCustomFieldWithHttpInfo(body, opts);
110
- } else {
111
- return this.createCustomFieldWithHttpInfo(body, opts).then(function (response_and_data) {
112
- return response_and_data.data;
113
- });
114
- }
89
+ return this.createCustomFieldWithHttpInfo(body, opts).then(function (response_and_data) {
90
+ return response_and_data.data;
91
+ });
115
92
  }
116
93
 
117
94
  /**
@@ -144,25 +121,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
144
121
  var contentTypes = ['application/json; charset=UTF-8'];
145
122
  var accepts = ['application/json; charset=UTF-8'];
146
123
  var returnType = 'Blob';
147
-
148
- // Check if RETURN_COLLECTION is set and return a collection object if it is
149
- if (this.apiClient.RETURN_COLLECTION && false) {
150
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
151
- 'path': '/custom_fields/{custom_field_gid}/enum_options',
152
- 'httpMethod': 'POST',
153
- 'pathParams': pathParams,
154
- 'queryParams': queryParams,
155
- 'headerParams': headerParams,
156
- 'formParams': formParams,
157
- 'bodyParam': postBody,
158
- 'authNames': authNames,
159
- 'contentTypes': contentTypes,
160
- 'accepts': accepts,
161
- 'returnType': returnType
162
- });
163
- } else {
164
- return this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
165
- }
124
+ return this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
166
125
  }
167
126
 
168
127
  /**
@@ -177,14 +136,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
177
136
  }, {
178
137
  key: "createEnumOptionForCustomField",
179
138
  value: function createEnumOptionForCustomField(custom_field_gid, opts) {
180
- // Check if RETURN_COLLECTION is set and return a collection object if it is
181
- if (this.apiClient.RETURN_COLLECTION && false) {
182
- return this.createEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts);
183
- } else {
184
- return this.createEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
185
- return response_and_data.data;
186
- });
187
- }
139
+ return this.createEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
140
+ return response_and_data.data;
141
+ });
188
142
  }
189
143
 
190
144
  /**
@@ -211,25 +165,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
211
165
  var contentTypes = [];
212
166
  var accepts = ['application/json; charset=UTF-8'];
213
167
  var returnType = 'Blob';
214
-
215
- // Check if RETURN_COLLECTION is set and return a collection object if it is
216
- if (this.apiClient.RETURN_COLLECTION && false) {
217
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
218
- 'path': '/custom_fields/{custom_field_gid}',
219
- 'httpMethod': 'DELETE',
220
- 'pathParams': pathParams,
221
- 'queryParams': queryParams,
222
- 'headerParams': headerParams,
223
- 'formParams': formParams,
224
- 'bodyParam': postBody,
225
- 'authNames': authNames,
226
- 'contentTypes': contentTypes,
227
- 'accepts': accepts,
228
- 'returnType': returnType
229
- });
230
- } else {
231
- return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
232
- }
168
+ return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'DELETE', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
233
169
  }
234
170
 
235
171
  /**
@@ -241,14 +177,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
241
177
  }, {
242
178
  key: "deleteCustomField",
243
179
  value: function deleteCustomField(custom_field_gid) {
244
- // Check if RETURN_COLLECTION is set and return a collection object if it is
245
- if (this.apiClient.RETURN_COLLECTION && false) {
246
- return this.deleteCustomFieldWithHttpInfo(custom_field_gid);
247
- } else {
248
- return this.deleteCustomFieldWithHttpInfo(custom_field_gid).then(function (response_and_data) {
249
- return response_and_data.data;
250
- });
251
- }
180
+ return this.deleteCustomFieldWithHttpInfo(custom_field_gid).then(function (response_and_data) {
181
+ return response_and_data.data;
182
+ });
252
183
  }
253
184
 
254
185
  /**
@@ -280,25 +211,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
280
211
  var contentTypes = [];
281
212
  var accepts = ['application/json; charset=UTF-8'];
282
213
  var returnType = 'Blob';
283
-
284
- // Check if RETURN_COLLECTION is set and return a collection object if it is
285
- if (this.apiClient.RETURN_COLLECTION && false) {
286
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
287
- 'path': '/custom_fields/{custom_field_gid}',
288
- 'httpMethod': 'GET',
289
- 'pathParams': pathParams,
290
- 'queryParams': queryParams,
291
- 'headerParams': headerParams,
292
- 'formParams': formParams,
293
- 'bodyParam': postBody,
294
- 'authNames': authNames,
295
- 'contentTypes': contentTypes,
296
- 'accepts': accepts,
297
- 'returnType': returnType
298
- });
299
- } else {
300
- return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
301
- }
214
+ return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
302
215
  }
303
216
 
304
217
  /**
@@ -312,14 +225,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
312
225
  }, {
313
226
  key: "getCustomField",
314
227
  value: function getCustomField(custom_field_gid, opts) {
315
- // Check if RETURN_COLLECTION is set and return a collection object if it is
316
- if (this.apiClient.RETURN_COLLECTION && false) {
317
- return this.getCustomFieldWithHttpInfo(custom_field_gid, opts);
318
- } else {
319
- return this.getCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
320
- return response_and_data.data;
321
- });
322
- }
228
+ return this.getCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
229
+ return response_and_data.data;
230
+ });
323
231
  }
324
232
 
325
233
  /**
@@ -353,9 +261,8 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
353
261
  var contentTypes = [];
354
262
  var accepts = ['application/json; charset=UTF-8'];
355
263
  var returnType = 'Blob';
356
-
357
264
  // Check if RETURN_COLLECTION is set and return a collection object if it is
358
- if (this.apiClient.RETURN_COLLECTION && true) {
265
+ if (this.apiClient.RETURN_COLLECTION) {
359
266
  return Collection.fromApiClient(this.apiClient.callApi('/workspaces/{workspace_gid}/custom_fields', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
360
267
  'path': '/workspaces/{workspace_gid}/custom_fields',
361
268
  'httpMethod': 'GET',
@@ -369,9 +276,8 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
369
276
  'accepts': accepts,
370
277
  'returnType': returnType
371
278
  });
372
- } else {
373
- return this.apiClient.callApi('/workspaces/{workspace_gid}/custom_fields', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
374
279
  }
280
+ return this.apiClient.callApi('/workspaces/{workspace_gid}/custom_fields', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
375
281
  }
376
282
 
377
283
  /**
@@ -388,13 +294,12 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
388
294
  key: "getCustomFieldsForWorkspace",
389
295
  value: function getCustomFieldsForWorkspace(workspace_gid, opts) {
390
296
  // Check if RETURN_COLLECTION is set and return a collection object if it is
391
- if (this.apiClient.RETURN_COLLECTION && true) {
297
+ if (this.apiClient.RETURN_COLLECTION) {
392
298
  return this.getCustomFieldsForWorkspaceWithHttpInfo(workspace_gid, opts);
393
- } else {
394
- return this.getCustomFieldsForWorkspaceWithHttpInfo(workspace_gid, opts).then(function (response_and_data) {
395
- return response_and_data.data;
396
- });
397
299
  }
300
+ return this.getCustomFieldsForWorkspaceWithHttpInfo(workspace_gid, opts).then(function (response_and_data) {
301
+ return response_and_data.data;
302
+ });
398
303
  }
399
304
 
400
305
  /**
@@ -427,25 +332,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
427
332
  var contentTypes = ['application/json; charset=UTF-8'];
428
333
  var accepts = ['application/json; charset=UTF-8'];
429
334
  var returnType = 'Blob';
430
-
431
- // Check if RETURN_COLLECTION is set and return a collection object if it is
432
- if (this.apiClient.RETURN_COLLECTION && false) {
433
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options/insert', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
434
- 'path': '/custom_fields/{custom_field_gid}/enum_options/insert',
435
- 'httpMethod': 'POST',
436
- 'pathParams': pathParams,
437
- 'queryParams': queryParams,
438
- 'headerParams': headerParams,
439
- 'formParams': formParams,
440
- 'bodyParam': postBody,
441
- 'authNames': authNames,
442
- 'contentTypes': contentTypes,
443
- 'accepts': accepts,
444
- 'returnType': returnType
445
- });
446
- } else {
447
- return this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options/insert', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
448
- }
335
+ return this.apiClient.callApi('/custom_fields/{custom_field_gid}/enum_options/insert', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
449
336
  }
450
337
 
451
338
  /**
@@ -460,14 +347,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
460
347
  }, {
461
348
  key: "insertEnumOptionForCustomField",
462
349
  value: function insertEnumOptionForCustomField(custom_field_gid, opts) {
463
- // Check if RETURN_COLLECTION is set and return a collection object if it is
464
- if (this.apiClient.RETURN_COLLECTION && false) {
465
- return this.insertEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts);
466
- } else {
467
- return this.insertEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
468
- return response_and_data.data;
469
- });
470
- }
350
+ return this.insertEnumOptionForCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
351
+ return response_and_data.data;
352
+ });
471
353
  }
472
354
 
473
355
  /**
@@ -500,25 +382,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
500
382
  var contentTypes = ['application/json; charset=UTF-8'];
501
383
  var accepts = ['application/json; charset=UTF-8'];
502
384
  var returnType = 'Blob';
503
-
504
- // Check if RETURN_COLLECTION is set and return a collection object if it is
505
- if (this.apiClient.RETURN_COLLECTION && false) {
506
- return Collection.fromApiClient(this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
507
- 'path': '/custom_fields/{custom_field_gid}',
508
- 'httpMethod': 'PUT',
509
- 'pathParams': pathParams,
510
- 'queryParams': queryParams,
511
- 'headerParams': headerParams,
512
- 'formParams': formParams,
513
- 'bodyParam': postBody,
514
- 'authNames': authNames,
515
- 'contentTypes': contentTypes,
516
- 'accepts': accepts,
517
- 'returnType': returnType
518
- });
519
- } else {
520
- return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
521
- }
385
+ return this.apiClient.callApi('/custom_fields/{custom_field_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
522
386
  }
523
387
 
524
388
  /**
@@ -533,14 +397,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
533
397
  }, {
534
398
  key: "updateCustomField",
535
399
  value: function updateCustomField(custom_field_gid, opts) {
536
- // Check if RETURN_COLLECTION is set and return a collection object if it is
537
- if (this.apiClient.RETURN_COLLECTION && false) {
538
- return this.updateCustomFieldWithHttpInfo(custom_field_gid, opts);
539
- } else {
540
- return this.updateCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
541
- return response_and_data.data;
542
- });
543
- }
400
+ return this.updateCustomFieldWithHttpInfo(custom_field_gid, opts).then(function (response_and_data) {
401
+ return response_and_data.data;
402
+ });
544
403
  }
545
404
 
546
405
  /**
@@ -573,25 +432,7 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
573
432
  var contentTypes = ['application/json; charset=UTF-8'];
574
433
  var accepts = ['application/json; charset=UTF-8'];
575
434
  var returnType = 'Blob';
576
-
577
- // Check if RETURN_COLLECTION is set and return a collection object if it is
578
- if (this.apiClient.RETURN_COLLECTION && false) {
579
- return Collection.fromApiClient(this.apiClient.callApi('/enum_options/{enum_option_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType), this.apiClient, {
580
- 'path': '/enum_options/{enum_option_gid}',
581
- 'httpMethod': 'PUT',
582
- 'pathParams': pathParams,
583
- 'queryParams': queryParams,
584
- 'headerParams': headerParams,
585
- 'formParams': formParams,
586
- 'bodyParam': postBody,
587
- 'authNames': authNames,
588
- 'contentTypes': contentTypes,
589
- 'accepts': accepts,
590
- 'returnType': returnType
591
- });
592
- } else {
593
- return this.apiClient.callApi('/enum_options/{enum_option_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
594
- }
435
+ return this.apiClient.callApi('/enum_options/{enum_option_gid}', 'PUT', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType);
595
436
  }
596
437
 
597
438
  /**
@@ -606,15 +447,9 @@ var CustomFieldsApi = exports.CustomFieldsApi = /*#__PURE__*/function () {
606
447
  }, {
607
448
  key: "updateEnumOption",
608
449
  value: function updateEnumOption(enum_option_gid, opts) {
609
- // Check if RETURN_COLLECTION is set and return a collection object if it is
610
- if (this.apiClient.RETURN_COLLECTION && false) {
611
- return this.updateEnumOptionWithHttpInfo(enum_option_gid, opts);
612
- } else {
613
- return this.updateEnumOptionWithHttpInfo(enum_option_gid, opts).then(function (response_and_data) {
614
- return response_and_data.data;
615
- });
616
- }
450
+ return this.updateEnumOptionWithHttpInfo(enum_option_gid, opts).then(function (response_and_data) {
451
+ return response_and_data.data;
452
+ });
617
453
  }
618
454
  }]);
619
- return CustomFieldsApi;
620
455
  }();