@resolution/jira-api-client 0.1.0 → 0.1.2

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 (201) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/package.json +10 -3
  3. package/.eslintrc.js +0 -3
  4. package/config/api-typescript-generator.config.ts +0 -91
  5. package/config/compare-schemas.ts +0 -307
  6. package/src/index.ts +0 -47
  7. package/src/openapi/platform/base-jira-platform-api-client.ts +0 -2298
  8. package/src/openapi/platform/core/common-http-client.ts +0 -723
  9. package/src/openapi/platform/core/common-http-service.ts +0 -22
  10. package/src/openapi/platform/core/common-validation-schema-storage.ts +0 -105
  11. package/src/openapi/platform/models/announcement-banner.ts +0 -59
  12. package/src/openapi/platform/models/app-data-policies.ts +0 -79
  13. package/src/openapi/platform/models/app-migration.ts +0 -172
  14. package/src/openapi/platform/models/app-properties.ts +0 -32
  15. package/src/openapi/platform/models/audit-records.ts +0 -140
  16. package/src/openapi/platform/models/avatars.ts +0 -48
  17. package/src/openapi/platform/models/classification-levels.ts +0 -58
  18. package/src/openapi/platform/models/common.ts +0 -2669
  19. package/src/openapi/platform/models/dashboards.ts +0 -849
  20. package/src/openapi/platform/models/dynamic-modules.ts +0 -121
  21. package/src/openapi/platform/models/filter-sharing.ts +0 -103
  22. package/src/openapi/platform/models/filters.ts +0 -319
  23. package/src/openapi/platform/models/group-and-user-picker.ts +0 -85
  24. package/src/openapi/platform/models/groups.ts +0 -247
  25. package/src/openapi/platform/models/issue-attachments.ts +0 -290
  26. package/src/openapi/platform/models/issue-comment-properties.ts +0 -27
  27. package/src/openapi/platform/models/issue-comments.ts +0 -91
  28. package/src/openapi/platform/models/issue-custom-field-configuration-apps.ts +0 -96
  29. package/src/openapi/platform/models/issue-custom-field-contexts.ts +0 -1072
  30. package/src/openapi/platform/models/issue-custom-field-options-apps.ts +0 -273
  31. package/src/openapi/platform/models/issue-custom-field-options.ts +0 -283
  32. package/src/openapi/platform/models/issue-custom-field-values-apps.ts +0 -118
  33. package/src/openapi/platform/models/issue-field-configurations.ts +0 -435
  34. package/src/openapi/platform/models/issue-fields.ts +0 -392
  35. package/src/openapi/platform/models/issue-link-types.ts +0 -28
  36. package/src/openapi/platform/models/issue-links.ts +0 -185
  37. package/src/openapi/platform/models/issue-notification-schemes.ts +0 -370
  38. package/src/openapi/platform/models/issue-priorities.ts +0 -196
  39. package/src/openapi/platform/models/issue-properties.ts +0 -259
  40. package/src/openapi/platform/models/issue-remote-links.ts +0 -207
  41. package/src/openapi/platform/models/issue-resolutions.ts +0 -180
  42. package/src/openapi/platform/models/issue-search.ts +0 -367
  43. package/src/openapi/platform/models/issue-security-level.ts +0 -76
  44. package/src/openapi/platform/models/issue-security-schemes.ts +0 -496
  45. package/src/openapi/platform/models/issue-type-schemes.ts +0 -290
  46. package/src/openapi/platform/models/issue-type-screen-schemes.ts +0 -286
  47. package/src/openapi/platform/models/issue-types.ts +0 -66
  48. package/src/openapi/platform/models/issue-votes.ts +0 -38
  49. package/src/openapi/platform/models/issue-watchers.ts +0 -67
  50. package/src/openapi/platform/models/issue-worklogs.ts +0 -190
  51. package/src/openapi/platform/models/issues.ts +0 -1268
  52. package/src/openapi/platform/models/jira-expressions.ts +0 -578
  53. package/src/openapi/platform/models/jira-settings.ts +0 -118
  54. package/src/openapi/platform/models/jql-functions-apps.ts +0 -128
  55. package/src/openapi/platform/models/jql.ts +0 -783
  56. package/src/openapi/platform/models/labels.ts +0 -42
  57. package/src/openapi/platform/models/license-metrics.ts +0 -68
  58. package/src/openapi/platform/models/myself.ts +0 -29
  59. package/src/openapi/platform/models/permission-schemes.ts +0 -89
  60. package/src/openapi/platform/models/permissions.ts +0 -308
  61. package/src/openapi/platform/models/priority-schemes.ts +0 -527
  62. package/src/openapi/platform/models/project-avatars.ts +0 -29
  63. package/src/openapi/platform/models/project-classification-levels.ts +0 -24
  64. package/src/openapi/platform/models/project-components.ts +0 -231
  65. package/src/openapi/platform/models/project-email.ts +0 -27
  66. package/src/openapi/platform/models/project-features.ts +0 -78
  67. package/src/openapi/platform/models/project-permission-schemes.ts +0 -43
  68. package/src/openapi/platform/models/project-role-actors.ts +0 -107
  69. package/src/openapi/platform/models/project-roles.ts +0 -76
  70. package/src/openapi/platform/models/project-types.ts +0 -36
  71. package/src/openapi/platform/models/project-versions.ts +0 -216
  72. package/src/openapi/platform/models/projects.ts +0 -429
  73. package/src/openapi/platform/models/screen-schemes.ts +0 -192
  74. package/src/openapi/platform/models/screen-tab-fields.ts +0 -45
  75. package/src/openapi/platform/models/screens.ts +0 -171
  76. package/src/openapi/platform/models/server-info.ts +0 -100
  77. package/src/openapi/platform/models/service-registry.ts +0 -68
  78. package/src/openapi/platform/models/status.ts +0 -229
  79. package/src/openapi/platform/models/time-tracking.ts +0 -38
  80. package/src/openapi/platform/models/ui-modifications-apps.ts +0 -229
  81. package/src/openapi/platform/models/user-search.ts +0 -69
  82. package/src/openapi/platform/models/users.ts +0 -121
  83. package/src/openapi/platform/models/webhooks.ts +0 -307
  84. package/src/openapi/platform/models/workflow-scheme-drafts.ts +0 -58
  85. package/src/openapi/platform/models/workflow-scheme-project-associations.ts +0 -68
  86. package/src/openapi/platform/models/workflow-schemes.ts +0 -545
  87. package/src/openapi/platform/models/workflow-transition-properties.ts +0 -33
  88. package/src/openapi/platform/models/workflow-transition-rules.ts +0 -261
  89. package/src/openapi/platform/models/workflows.ts +0 -1943
  90. package/src/openapi/platform/services/announcement-banner-service.ts +0 -142
  91. package/src/openapi/platform/services/app-data-policies-service.ts +0 -136
  92. package/src/openapi/platform/services/app-migration-service.ts +0 -289
  93. package/src/openapi/platform/services/app-properties-service.ts +0 -441
  94. package/src/openapi/platform/services/application-roles-service.ts +0 -247
  95. package/src/openapi/platform/services/audit-records-service.ts +0 -164
  96. package/src/openapi/platform/services/avatars-service.ts +0 -769
  97. package/src/openapi/platform/services/classification-levels-service.ts +0 -131
  98. package/src/openapi/platform/services/dashboards-service.ts +0 -1721
  99. package/src/openapi/platform/services/dynamic-modules-service.ts +0 -127
  100. package/src/openapi/platform/services/filter-sharing-service.ts +0 -687
  101. package/src/openapi/platform/services/filters-service.ts +0 -1901
  102. package/src/openapi/platform/services/group-and-user-picker-service.ts +0 -224
  103. package/src/openapi/platform/services/groups-service.ts +0 -751
  104. package/src/openapi/platform/services/issue-attachments-service.ts +0 -900
  105. package/src/openapi/platform/services/issue-comment-properties-service.ts +0 -324
  106. package/src/openapi/platform/services/issue-comments-service.ts +0 -812
  107. package/src/openapi/platform/services/issue-custom-field-configuration-apps-service.ts +0 -277
  108. package/src/openapi/platform/services/issue-custom-field-contexts-service.ts +0 -1339
  109. package/src/openapi/platform/services/issue-custom-field-options-apps-service.ts +0 -994
  110. package/src/openapi/platform/services/issue-custom-field-options-service.ts +0 -651
  111. package/src/openapi/platform/services/issue-custom-field-values-apps-service.ts +0 -201
  112. package/src/openapi/platform/services/issue-field-configurations-service.ts +0 -1294
  113. package/src/openapi/platform/services/issue-fields-service.ts +0 -837
  114. package/src/openapi/platform/services/issue-link-types-service.ts +0 -360
  115. package/src/openapi/platform/services/issue-links-service.ts +0 -345
  116. package/src/openapi/platform/services/issue-navigator-settings-service.ts +0 -119
  117. package/src/openapi/platform/services/issue-notification-schemes-service.ts +0 -1209
  118. package/src/openapi/platform/services/issue-priorities-service.ts +0 -575
  119. package/src/openapi/platform/services/issue-properties-service.ts +0 -606
  120. package/src/openapi/platform/services/issue-remote-links-service.ts +0 -597
  121. package/src/openapi/platform/services/issue-resolutions-service.ts +0 -534
  122. package/src/openapi/platform/services/issue-search-service.ts +0 -1139
  123. package/src/openapi/platform/services/issue-security-level-service.ts +0 -250
  124. package/src/openapi/platform/services/issue-security-schemes-service.ts +0 -1240
  125. package/src/openapi/platform/services/issue-type-properties-service.ts +0 -325
  126. package/src/openapi/platform/services/issue-type-schemes-service.ts +0 -940
  127. package/src/openapi/platform/services/issue-type-screen-schemes-service.ts +0 -994
  128. package/src/openapi/platform/services/issue-types-service.ts +0 -679
  129. package/src/openapi/platform/services/issue-votes-service.ts +0 -221
  130. package/src/openapi/platform/services/issue-watchers-service.ts +0 -331
  131. package/src/openapi/platform/services/issue-worklog-properties-service.ts +0 -348
  132. package/src/openapi/platform/services/issue-worklogs-service.ts +0 -1089
  133. package/src/openapi/platform/services/issues-service.ts +0 -3346
  134. package/src/openapi/platform/services/jira-expressions-service.ts +0 -407
  135. package/src/openapi/platform/services/jira-settings-service.ts +0 -415
  136. package/src/openapi/platform/services/jql-functions-apps-service.ts +0 -219
  137. package/src/openapi/platform/services/jql-service.ts +0 -896
  138. package/src/openapi/platform/services/labels-service.ts +0 -89
  139. package/src/openapi/platform/services/license-metrics-service.ts +0 -216
  140. package/src/openapi/platform/services/myself-service.ts +0 -520
  141. package/src/openapi/platform/services/permission-schemes-service.ts +0 -926
  142. package/src/openapi/platform/services/permissions-service.ts +0 -407
  143. package/src/openapi/platform/services/priority-schemes-service.ts +0 -1001
  144. package/src/openapi/platform/services/project-avatars-service.ts +0 -341
  145. package/src/openapi/platform/services/project-categories-service.ts +0 -318
  146. package/src/openapi/platform/services/project-classification-levels-service.ts +0 -232
  147. package/src/openapi/platform/services/project-components-service.ts +0 -1332
  148. package/src/openapi/platform/services/project-email-service.ts +0 -161
  149. package/src/openapi/platform/services/project-features-service.ts +0 -207
  150. package/src/openapi/platform/services/project-key-and-name-validation-service.ts +0 -200
  151. package/src/openapi/platform/services/project-permission-schemes-service.ts +0 -384
  152. package/src/openapi/platform/services/project-properties-service.ts +0 -320
  153. package/src/openapi/platform/services/project-role-actors-service.ts +0 -627
  154. package/src/openapi/platform/services/project-roles-service.ts +0 -867
  155. package/src/openapi/platform/services/project-types-service.ts +0 -297
  156. package/src/openapi/platform/services/project-versions-service.ts +0 -1287
  157. package/src/openapi/platform/services/projects-service.ts +0 -2196
  158. package/src/openapi/platform/services/screen-schemes-service.ts +0 -334
  159. package/src/openapi/platform/services/screen-tab-fields-service.ts +0 -276
  160. package/src/openapi/platform/services/screen-tabs-service.ts +0 -421
  161. package/src/openapi/platform/services/screens-service.ts +0 -528
  162. package/src/openapi/platform/services/server-info-service.ts +0 -88
  163. package/src/openapi/platform/services/service-registry-service.ts +0 -89
  164. package/src/openapi/platform/services/status-service.ts +0 -498
  165. package/src/openapi/platform/services/tasks-service.ts +0 -159
  166. package/src/openapi/platform/services/time-tracking-service.ts +0 -386
  167. package/src/openapi/platform/services/ui-modifications-apps-service.ts +0 -403
  168. package/src/openapi/platform/services/user-properties-service.ts +0 -413
  169. package/src/openapi/platform/services/user-search-service.ts +0 -1214
  170. package/src/openapi/platform/services/users-service.ts +0 -1108
  171. package/src/openapi/platform/services/webhooks-service.ts +0 -458
  172. package/src/openapi/platform/services/workflow-scheme-drafts-service.ts +0 -1313
  173. package/src/openapi/platform/services/workflow-scheme-project-associations-service.ts +0 -189
  174. package/src/openapi/platform/services/workflow-schemes-service.ts +0 -1617
  175. package/src/openapi/platform/services/workflow-status-categories-service.ts +0 -151
  176. package/src/openapi/platform/services/workflow-statuses-service.ts +0 -176
  177. package/src/openapi/platform/services/workflow-transition-properties-service.ts +0 -388
  178. package/src/openapi/platform/services/workflow-transition-rules-service.ts +0 -485
  179. package/src/openapi/platform/services/workflows-service.ts +0 -3477
  180. package/src/openapi/platform/validation-schema-storage.ts +0 -186
  181. package/src/openapi/software/base-jira-software-api-client.ts +0 -447
  182. package/src/openapi/software/core/common-http-client.ts +0 -723
  183. package/src/openapi/software/core/common-http-service.ts +0 -22
  184. package/src/openapi/software/core/common-validation-schema-storage.ts +0 -105
  185. package/src/openapi/software/models/board.ts +0 -918
  186. package/src/openapi/software/services/backlog-service.ts +0 -160
  187. package/src/openapi/software/services/board-service.ts +0 -4189
  188. package/src/openapi/software/services/builds-service.ts +0 -571
  189. package/src/openapi/software/services/deployments-service.ts +0 -403
  190. package/src/openapi/software/services/dev-ops-components-service.ts +0 -371
  191. package/src/openapi/software/services/development-information-service.ts +0 -2357
  192. package/src/openapi/software/services/epic-service.ts +0 -854
  193. package/src/openapi/software/services/feature-flags-service.ts +0 -303
  194. package/src/openapi/software/services/issue-service.ts +0 -529
  195. package/src/openapi/software/services/operations-service.ts +0 -741
  196. package/src/openapi/software/services/remote-links-service.ts +0 -653
  197. package/src/openapi/software/services/security-information-service.ts +0 -495
  198. package/src/openapi/software/services/sprint-service.ts +0 -969
  199. package/src/openapi/software/validation-schema-storage.ts +0 -186
  200. package/tsconfig.build.json +0 -7
  201. package/tsconfig.json +0 -4
@@ -1,1721 +0,0 @@
1
- // DO NOT EDIT!
2
- // This file is generated by "api-typescript-generator".
3
- // To update this file run "yarn build:openapi".
4
- import { z } from "zod";
5
-
6
- import * as commonHttpClient from "../core/common-http-client";
7
- import { CommonHttpService } from "../core/common-http-service";
8
- import {
9
- type EntityProperty,
10
- type PropertyKeys,
11
- registerCommonValidationSchemas,
12
- } from "../models/common";
13
- import {
14
- type AvailableDashboardGadgetsResponse,
15
- type BulkEditShareableEntityRequest,
16
- type BulkEditShareableEntityResponse,
17
- type Dashboard,
18
- type DashboardDetails,
19
- type DashboardGadget,
20
- type DashboardGadgetResponse,
21
- type DashboardGadgetSettings,
22
- type DashboardGadgetUpdateRequest,
23
- type PageBeanDashboard,
24
- type PageOfDashboards,
25
- registerDashboardsValidationSchemas,
26
- } from "../models/dashboards";
27
- import { validationSchemaStorage } from "../validation-schema-storage";
28
- /**
29
- * This resource represents dashboards. Use it to obtain the details of dashboards
30
- * as well as get, create, update, or remove item properties and gadgets from
31
- * dashboards.
32
- */
33
- export class DashboardsService extends CommonHttpService {
34
- /**
35
- * Adds a gadget to a dashboard.
36
- *
37
- * **[Permissions](#permissions) required:** None.
38
- *
39
- * @returns Returned if the request is successful.
40
- *
41
- * example: {
42
- * "id": 10001,
43
- * "moduleKey":
44
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-item",
45
- * "color": "blue",
46
- * "position": {
47
- * "row": 0,
48
- * "column": 1
49
- * },
50
- * "title": "Issue statistics"
51
- * }
52
- * @path {POST} /rest/api/3/dashboard/{dashboardId}/gadget
53
- * @scopes-current write:jira-work, read:jira-work
54
- * @scopes-beta write:dashboard:jira, read:dashboard:jira
55
- */
56
- addGadget({
57
- dashboardId,
58
- dashboardGadgetSettings,
59
- }: {
60
- /** The ID of the dashboard. */
61
- dashboardId: number;
62
- /**
63
- * @example {
64
- * "color": "blue",
65
- * "ignoreUriAndModuleKeyValidation": false,
66
- * "moduleKey":
67
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-item",
68
- * "position": {
69
- * "column": 1,
70
- * "row": 0
71
- * },
72
- * "title": "Issue statistics"
73
- * }
74
- */
75
- dashboardGadgetSettings: DashboardGadgetSettings;
76
- }): Promise<DashboardGadget> {
77
- return this.getClientInstance()
78
- .request({
79
- path: "/rest/api/3/dashboard/{dashboardId}/gadget",
80
- method: "POST",
81
- pathParams: {
82
- dashboardId,
83
- },
84
- headers: {
85
- "Content-Type": "application/json",
86
- },
87
- body: dashboardGadgetSettings,
88
- })
89
- .then(
90
- this.getClientInstance().responseHandler({
91
- 200: {
92
- "application/json": "json",
93
- },
94
- }),
95
- )
96
- .then(
97
- commonHttpClient.castResponse<{
98
- status: 200;
99
- mediaType: "application/json";
100
- body: DashboardGadget;
101
- }>(),
102
- )
103
- .then(
104
- validationSchemaStorage.validator(
105
- "DashboardsService.addGadget.response",
106
- ),
107
- )
108
- .then(commonHttpClient.getBody);
109
- }
110
- /**
111
- * Bulk edit dashboards. Maximum number of dashboards to be edited at the same
112
- * time is 100.
113
- *
114
- * **[Permissions](#permissions) required:** None
115
- *
116
- * The dashboards to be updated must be owned by the user, or the user must be an
117
- * administrator.
118
- *
119
- * @returns Returned if the request is successful.
120
- *
121
- * example: {
122
- * "action": "changePermission",
123
- * "entityErrors": {
124
- * "10002": {
125
- * "errorMessages": [
126
- * "Only owner or editors of the dashboard can change permissions."
127
- * ],
128
- * "errors": {}
129
- * }
130
- * }
131
- * }
132
- * @path {PUT} /rest/api/3/dashboard/bulk/edit
133
- * @scopes-current write:jira-work
134
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
135
- * read:project-role:jira, read:user:jira, write:dashboard:jira,
136
- * read:application-role:jira, read:avatar:jira, read:issue-type-hierarchy:jira,
137
- * read:issue-type:jira, read:project-category:jira, read:project-version:jira,
138
- * read:project.component:jira
139
- */
140
- bulkEditDashboards({
141
- bulkEditShareableEntityRequest,
142
- }: {
143
- /**
144
- * The details of dashboards being updated in bulk.
145
- *
146
- * @example {
147
- * "action": "changePermission",
148
- * "entityIds": [
149
- * 10001,
150
- * 10002
151
- * ],
152
- * "extendAdminPermissions": true,
153
- * "permissionDetails": {
154
- * "editPermissions": [
155
- * {
156
- * "group": {
157
- * "groupId": "276f955c-63d7-42c8-9520-92d01dca0625",
158
- * "name": "jira-administrators",
159
- * "self":
160
- * "https://your-domain.atlassian.net/rest/api/~ver~/group?groupId=276f955c-63d7-42c8-9520-92d01dca0625"
161
- * },
162
- * "id": 10010,
163
- * "type": "group"
164
- * }
165
- * ],
166
- * "sharePermissions": [
167
- * {
168
- * "id": 10000,
169
- * "type": "global"
170
- * }
171
- * ]
172
- * }
173
- * }
174
- */
175
- bulkEditShareableEntityRequest: BulkEditShareableEntityRequest;
176
- }): Promise<BulkEditShareableEntityResponse> {
177
- return this.getClientInstance()
178
- .request({
179
- path: "/rest/api/3/dashboard/bulk/edit",
180
- method: "PUT",
181
- headers: {
182
- "Content-Type": "application/json",
183
- },
184
- body: bulkEditShareableEntityRequest,
185
- })
186
- .then(
187
- this.getClientInstance().responseHandler({
188
- 200: {
189
- "application/json": "json",
190
- },
191
- }),
192
- )
193
- .then(
194
- commonHttpClient.castResponse<{
195
- status: 200;
196
- mediaType: "application/json";
197
- body: BulkEditShareableEntityResponse;
198
- }>(),
199
- )
200
- .then(
201
- validationSchemaStorage.validator(
202
- "DashboardsService.bulkEditDashboards.response",
203
- ),
204
- )
205
- .then(commonHttpClient.getBody);
206
- }
207
- /**
208
- * Copies a dashboard. Any values provided in the `dashboard` parameter replace
209
- * those in the copied dashboard.
210
- *
211
- * **[Permissions](#permissions) required:** None
212
- *
213
- * The dashboard to be copied must be owned by or shared with the user.
214
- *
215
- * @returns Returned if the request is successful.
216
- *
217
- * example: {
218
- * "id": "10000",
219
- * "isFavourite": false,
220
- * "name": "System Dashboard",
221
- * "popularity": 1,
222
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/10000",
223
- * "sharePermissions": [
224
- * {
225
- * "type": "global"
226
- * }
227
- * ],
228
- * "view":
229
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=10000"
230
- * }
231
- * @path {POST} /rest/api/3/dashboard/{id}/copy
232
- * @scopes-current write:jira-work
233
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
234
- * read:project-role:jira, read:user:jira, write:dashboard:jira,
235
- * read:application-role:jira, read:avatar:jira, read:issue-type-hierarchy:jira,
236
- * read:issue-type:jira, read:project-category:jira, read:project-version:jira,
237
- * read:project.component:jira
238
- */
239
- copyDashboard({
240
- id,
241
- dashboardDetails,
242
- }: {
243
- id: string;
244
- /**
245
- * Dashboard details.
246
- *
247
- * @example {
248
- * "description": "A dashboard to help auditors identify sample of issues to
249
- * check.",
250
- * "editPermissions": [],
251
- * "name": "Auditors dashboard",
252
- * "sharePermissions": [
253
- * {
254
- * "type": "global"
255
- * }
256
- * ]
257
- * }
258
- */
259
- dashboardDetails: DashboardDetails;
260
- }): Promise<Dashboard> {
261
- return this.getClientInstance()
262
- .request({
263
- path: "/rest/api/3/dashboard/{id}/copy",
264
- method: "POST",
265
- pathParams: {
266
- id,
267
- },
268
- headers: {
269
- "Content-Type": "application/json",
270
- },
271
- body: dashboardDetails,
272
- })
273
- .then(
274
- this.getClientInstance().responseHandler({
275
- 200: {
276
- "application/json": "json",
277
- },
278
- }),
279
- )
280
- .then(
281
- commonHttpClient.castResponse<{
282
- status: 200;
283
- mediaType: "application/json";
284
- body: Dashboard;
285
- }>(),
286
- )
287
- .then(
288
- validationSchemaStorage.validator(
289
- "DashboardsService.copyDashboard.response",
290
- ),
291
- )
292
- .then(commonHttpClient.getBody);
293
- }
294
- /**
295
- * Creates a dashboard.
296
- *
297
- * **[Permissions](#permissions) required:** None.
298
- *
299
- * @returns Returned if the request is successful.
300
- *
301
- * example: {
302
- * "id": "10000",
303
- * "isFavourite": false,
304
- * "name": "System Dashboard",
305
- * "popularity": 1,
306
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/10000",
307
- * "sharePermissions": [
308
- * {
309
- * "type": "global"
310
- * }
311
- * ],
312
- * "view":
313
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=10000"
314
- * }
315
- * @path {POST} /rest/api/3/dashboard
316
- * @scopes-current write:jira-work
317
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
318
- * read:project-role:jira, read:user:jira, write:dashboard:jira,
319
- * read:application-role:jira, read:avatar:jira, read:issue-type-hierarchy:jira,
320
- * read:issue-type:jira, read:project-category:jira, read:project-version:jira,
321
- * read:project.component:jira
322
- */
323
- createDashboard({
324
- dashboardDetails,
325
- }: {
326
- /**
327
- * Dashboard details.
328
- *
329
- * @example {
330
- * "description": "A dashboard to help auditors identify sample of issues to
331
- * check.",
332
- * "editPermissions": [],
333
- * "name": "Auditors dashboard",
334
- * "sharePermissions": [
335
- * {
336
- * "type": "global"
337
- * }
338
- * ]
339
- * }
340
- */
341
- dashboardDetails: DashboardDetails;
342
- }): Promise<Dashboard> {
343
- return this.getClientInstance()
344
- .request({
345
- path: "/rest/api/3/dashboard",
346
- method: "POST",
347
- headers: {
348
- "Content-Type": "application/json",
349
- },
350
- body: dashboardDetails,
351
- })
352
- .then(
353
- this.getClientInstance().responseHandler({
354
- 200: {
355
- "application/json": "json",
356
- },
357
- }),
358
- )
359
- .then(
360
- commonHttpClient.castResponse<{
361
- status: 200;
362
- mediaType: "application/json";
363
- body: Dashboard;
364
- }>(),
365
- )
366
- .then(
367
- validationSchemaStorage.validator(
368
- "DashboardsService.createDashboard.response",
369
- ),
370
- )
371
- .then(commonHttpClient.getBody);
372
- }
373
- /**
374
- * Deletes a dashboard.
375
- *
376
- * **[Permissions](#permissions) required:** None
377
- *
378
- * The dashboard to be deleted must be owned by the user.
379
- *
380
- * @path {DELETE} /rest/api/3/dashboard/{id}
381
- * @scopes-current write:jira-work
382
- * @scopes-beta delete:dashboard:jira
383
- */
384
- deleteDashboard({
385
- id,
386
- }: {
387
- /** The ID of the dashboard. */
388
- id: string;
389
- }): Promise<void> {
390
- return this.getClientInstance()
391
- .request({
392
- path: "/rest/api/3/dashboard/{id}",
393
- method: "DELETE",
394
- pathParams: {
395
- id,
396
- },
397
- })
398
- .then(commonHttpClient.discardResult);
399
- }
400
- /**
401
- * Deletes a dashboard item property.
402
- *
403
- * This operation can be accessed anonymously.
404
- *
405
- * **[Permissions](#permissions) required:** The user must be the owner of the
406
- * dashboard. Note, users with the *Administer Jira* [global
407
- * permission](https://confluence.atlassian.com/x/x4dKLg) are considered owners of
408
- * the System dashboard.
409
- *
410
- * @returns Returned if the dashboard item property is deleted.
411
- * @path {DELETE}
412
- * /rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}
413
- * @scopes-current write:jira-work
414
- * @scopes-beta delete:dashboard.property:jira
415
- */
416
- deleteDashboardItemProperty({
417
- dashboardId,
418
- itemId,
419
- propertyKey,
420
- }: {
421
- /** The ID of the dashboard. */
422
- dashboardId: string;
423
- /** The ID of the dashboard item. */
424
- itemId: string;
425
- /** The key of the dashboard item property. */
426
- propertyKey: string;
427
- }): Promise<void> {
428
- return this.getClientInstance()
429
- .request({
430
- path: "/rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}",
431
- method: "DELETE",
432
- pathParams: {
433
- dashboardId,
434
- itemId,
435
- propertyKey,
436
- },
437
- })
438
- .then(
439
- this.getClientInstance().responseHandler({
440
- 204: {
441
- "application/json": "json",
442
- },
443
- }),
444
- )
445
- .then(
446
- commonHttpClient.castResponse<{
447
- status: 204;
448
- mediaType: "application/json";
449
- body: void;
450
- }>(),
451
- )
452
- .then(
453
- validationSchemaStorage.validator(
454
- "DashboardsService.deleteDashboardItemProperty.response",
455
- ),
456
- )
457
- .then(commonHttpClient.getBody);
458
- }
459
- /**
460
- * Gets a list of all available gadgets that can be added to all dashboards.
461
- *
462
- * **[Permissions](#permissions) required:** None.
463
- *
464
- * @returns Returned if the request is successful.
465
- *
466
- * example: {
467
- * "gadgets": [
468
- * {
469
- * "moduleKey":
470
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-item",
471
- * "title": "Issue statistics"
472
- * },
473
- * {
474
- * "uri":
475
- * "rest/gadgets/1.0/g/com.atlassian.streams.streams-jira-plugin:activitystream-gadget/gadgets/activitystream-gadget.xml",
476
- * "title": "Activity Stream"
477
- * }
478
- * ]
479
- * }
480
- * @path {GET} /rest/api/3/dashboard/gadgets
481
- * @scopes-current read:jira-work
482
- * @scopes-beta read:dashboard:jira
483
- */
484
- getAllAvailableDashboardGadgets(): Promise<AvailableDashboardGadgetsResponse> {
485
- return this.getClientInstance()
486
- .request({
487
- path: "/rest/api/3/dashboard/gadgets",
488
- method: "GET",
489
- })
490
- .then(
491
- this.getClientInstance().responseHandler({
492
- 200: {
493
- "application/json": "json",
494
- },
495
- }),
496
- )
497
- .then(
498
- commonHttpClient.castResponse<{
499
- status: 200;
500
- mediaType: "application/json";
501
- body: AvailableDashboardGadgetsResponse;
502
- }>(),
503
- )
504
- .then(
505
- validationSchemaStorage.validator(
506
- "DashboardsService.getAllAvailableDashboardGadgets.response",
507
- ),
508
- )
509
- .then(commonHttpClient.getBody);
510
- }
511
- /**
512
- * Returns a list of dashboards owned by or shared with the user. The list may be
513
- * filtered to include only favorite or owned dashboards.
514
- *
515
- * This operation can be accessed anonymously.
516
- *
517
- * **[Permissions](#permissions) required:** None.
518
- *
519
- * @returns Returned if the request is successful.
520
- *
521
- * example: {
522
- * "dashboards": [
523
- * {
524
- * "id": "10000",
525
- * "isFavourite": false,
526
- * "name": "System Dashboard",
527
- * "popularity": 1,
528
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/10000",
529
- * "sharePermissions": [
530
- * {
531
- * "type": "global"
532
- * }
533
- * ],
534
- * "view":
535
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=10000"
536
- * },
537
- * {
538
- * "id": "20000",
539
- * "isFavourite": true,
540
- * "name": "Build Engineering",
541
- * "owner": {
542
- * "key": "Mia",
543
- * "self":
544
- * "https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10a2844c20165700ede21g",
545
- * "name": "mia",
546
- * "displayName": "Mia Krystof",
547
- * "avatarUrls": {
548
- * "16x16":
549
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
550
- * "24x24":
551
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
552
- * "32x32":
553
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
554
- * "48x48":
555
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
556
- * }
557
- * },
558
- * "popularity": 1,
559
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/20000",
560
- * "sharePermissions": [
561
- * {
562
- * "group": {
563
- * "name": "administrators",
564
- * "self":
565
- * "https://your-domain.atlassian.net/rest/api/3/group?groupname=administrators"
566
- * },
567
- * "id": 10105,
568
- * "type": "group"
569
- * }
570
- * ],
571
- * "view":
572
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=20000"
573
- * }
574
- * ],
575
- * "maxResults": 10,
576
- * "next": "https://your-domain.atlassian.net/rest/api/3/dashboard?startAt=10",
577
- * "prev": "https://your-domain.atlassian.net/rest/api/3/dashboard?startAt=0",
578
- * "startAt": 10,
579
- * "total": 143
580
- * }
581
- * @path {GET} /rest/api/3/dashboard
582
- * @scopes-current read:jira-work
583
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
584
- * read:project-role:jira, read:user:jira, read:application-role:jira,
585
- * read:avatar:jira, read:issue-type-hierarchy:jira, read:issue-type:jira,
586
- * read:project-category:jira, read:project-version:jira,
587
- * read:project.component:jira
588
- */
589
- getAllDashboards({
590
- filter,
591
- startAt,
592
- maxResults,
593
- }: {
594
- /**
595
- * The filter applied to the list of dashboards. Valid values are:
596
- *
597
- * * `favourite` Returns dashboards the user has marked as favorite.
598
- * * `my` Returns dashboards owned by the user.
599
- */
600
- filter?: "my" | "favourite";
601
- /** The index of the first item to return in a page of results (page offset). */
602
- startAt?: number;
603
- /** The maximum number of items to return per page. */
604
- maxResults?: number;
605
- }): Promise<PageOfDashboards> {
606
- return this.getClientInstance()
607
- .request({
608
- path: "/rest/api/3/dashboard",
609
- method: "GET",
610
- query: {
611
- filter,
612
- startAt,
613
- maxResults,
614
- },
615
- })
616
- .then(
617
- this.getClientInstance().responseHandler({
618
- 200: {
619
- "application/json": "json",
620
- },
621
- }),
622
- )
623
- .then(
624
- commonHttpClient.castResponse<{
625
- status: 200;
626
- mediaType: "application/json";
627
- body: PageOfDashboards;
628
- }>(),
629
- )
630
- .then(
631
- validationSchemaStorage.validator(
632
- "DashboardsService.getAllDashboards.response",
633
- ),
634
- )
635
- .then(commonHttpClient.getBody);
636
- }
637
- /**
638
- * Returns a list of dashboard gadgets on a dashboard.
639
- *
640
- * This operation returns:
641
- *
642
- * * Gadgets from a list of IDs, when `id` is set.
643
- * * Gadgets with a module key, when `moduleKey` is set.
644
- * * Gadgets from a list of URIs, when `uri` is set.
645
- * * All gadgets, when no other parameters are set.
646
- *
647
- * This operation can be accessed anonymously.
648
- *
649
- * **[Permissions](#permissions) required:** None.
650
- *
651
- * @returns Returned if the request is successful.
652
- *
653
- * example: {
654
- * "gadgets": [
655
- * {
656
- * "id": 10001,
657
- * "moduleKey":
658
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-item",
659
- * "color": "blue",
660
- * "position": {
661
- * "row": 0,
662
- * "column": 0
663
- * },
664
- * "title": "Issue statistics"
665
- * },
666
- * {
667
- * "id": 10002,
668
- * "moduleKey":
669
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-graph",
670
- * "color": "red",
671
- * "position": {
672
- * "row": 1,
673
- * "column": 0
674
- * },
675
- * "title": "Activity stream"
676
- * },
677
- * {
678
- * "id": 10003,
679
- * "moduleKey":
680
- * "com.atlassian.plugins.atlassian-connect-plugin:com.atlassian.connect.node.sample-addon__sample-dashboard-item",
681
- * "color": "yellow",
682
- * "position": {
683
- * "row": 0,
684
- * "column": 1
685
- * },
686
- * "title": "Bubble chart"
687
- * }
688
- * ]
689
- * }
690
- * @path {GET} /rest/api/3/dashboard/{dashboardId}/gadget
691
- * @scopes-current read:jira-work
692
- * @scopes-beta read:dashboard:jira
693
- */
694
- getAllGadgets({
695
- dashboardId,
696
- moduleKey,
697
- uri,
698
- gadgetId,
699
- }: {
700
- /** The ID of the dashboard. */
701
- dashboardId: number;
702
- /**
703
- * The list of gadgets module keys. To include multiple module keys, separate
704
- * module keys with ampersand: `moduleKey=key:one&moduleKey=key:two`.
705
- */
706
- moduleKey?: string[];
707
- /**
708
- * The list of gadgets URIs. To include multiple URIs, separate URIs with
709
- * ampersand: `uri=/rest/example/uri/1&uri=/rest/example/uri/2`.
710
- */
711
- uri?: string[];
712
- /**
713
- * The list of gadgets IDs. To include multiple IDs, separate IDs with ampersand:
714
- * `gadgetId=10000&gadgetId=10001`.
715
- */
716
- gadgetId?: number[];
717
- }): Promise<DashboardGadgetResponse> {
718
- return this.getClientInstance()
719
- .request({
720
- path: "/rest/api/3/dashboard/{dashboardId}/gadget",
721
- method: "GET",
722
- pathParams: {
723
- dashboardId,
724
- },
725
- query: {
726
- moduleKey,
727
- uri,
728
- gadgetId,
729
- },
730
- })
731
- .then(
732
- this.getClientInstance().responseHandler({
733
- 200: {
734
- "application/json": "json",
735
- },
736
- }),
737
- )
738
- .then(
739
- commonHttpClient.castResponse<{
740
- status: 200;
741
- mediaType: "application/json";
742
- body: DashboardGadgetResponse;
743
- }>(),
744
- )
745
- .then(
746
- validationSchemaStorage.validator(
747
- "DashboardsService.getAllGadgets.response",
748
- ),
749
- )
750
- .then(commonHttpClient.getBody);
751
- }
752
- /**
753
- * Returns a dashboard.
754
- *
755
- * This operation can be accessed anonymously.
756
- *
757
- * **[Permissions](#permissions) required:** None.
758
- *
759
- * However, to get a dashboard, the dashboard must be shared with the user or the
760
- * user must own it. Note, users with the *Administer Jira* [global
761
- * permission](https://confluence.atlassian.com/x/x4dKLg) are considered owners of
762
- * the System dashboard. The System dashboard is considered to be shared with all
763
- * other users.
764
- *
765
- * @returns Returned if the request is successful.
766
- *
767
- * example: {
768
- * "id": "10000",
769
- * "isFavourite": false,
770
- * "name": "System Dashboard",
771
- * "popularity": 1,
772
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/10000",
773
- * "sharePermissions": [
774
- * {
775
- * "type": "global"
776
- * }
777
- * ],
778
- * "view":
779
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=10000"
780
- * }
781
- * @path {GET} /rest/api/3/dashboard/{id}
782
- * @scopes-current read:jira-work
783
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
784
- * read:project-role:jira, read:user:jira, read:application-role:jira,
785
- * read:avatar:jira, read:issue-type-hierarchy:jira, read:issue-type:jira,
786
- * read:project-category:jira, read:project-version:jira,
787
- * read:project.component:jira
788
- */
789
- getDashboard({
790
- id,
791
- }: {
792
- /** The ID of the dashboard. */
793
- id: string;
794
- }): Promise<Dashboard> {
795
- return this.getClientInstance()
796
- .request({
797
- path: "/rest/api/3/dashboard/{id}",
798
- method: "GET",
799
- pathParams: {
800
- id,
801
- },
802
- })
803
- .then(
804
- this.getClientInstance().responseHandler({
805
- 200: {
806
- "application/json": "json",
807
- },
808
- }),
809
- )
810
- .then(
811
- commonHttpClient.castResponse<{
812
- status: 200;
813
- mediaType: "application/json";
814
- body: Dashboard;
815
- }>(),
816
- )
817
- .then(
818
- validationSchemaStorage.validator(
819
- "DashboardsService.getDashboard.response",
820
- ),
821
- )
822
- .then(commonHttpClient.getBody);
823
- }
824
- /**
825
- * Returns the key and value of a dashboard item property.
826
- *
827
- * A dashboard item enables an app to add user-specific information to a user
828
- * dashboard. Dashboard items are exposed to users as gadgets that users can add
829
- * to their dashboards. For more information on how users do this, see [Adding and
830
- * customizing gadgets](https://confluence.atlassian.com/x/7AeiLQ).
831
- *
832
- * When an app creates a dashboard item it registers a callback to receive the
833
- * dashboard item ID. The callback fires whenever the item is rendered or, where
834
- * the item is configurable, the user edits the item. The app then uses this
835
- * resource to store the item's content or configuration details. For more
836
- * information on working with dashboard items, see [ Building a dashboard item
837
- * for a JIRA Connect
838
- * add-on](https://developer.atlassian.com/server/jira/platform/guide-building-a-dashboard-item-for-a-jira-connect-add-on-33746254/)
839
- * and the [Dashboard
840
- * Item](https://developer.atlassian.com/cloud/jira/platform/modules/dashboard-item/)
841
- * documentation.
842
- *
843
- * There is no resource to set or get dashboard items.
844
- *
845
- * This operation can be accessed anonymously.
846
- *
847
- * **[Permissions](#permissions) required:** The user must be the owner of the
848
- * dashboard or have the dashboard shared with them. Note, users with the
849
- * *Administer Jira* [global
850
- * permission](https://confluence.atlassian.com/x/x4dKLg) are considered owners of
851
- * the System dashboard. The System dashboard is considered to be shared with all
852
- * other users, and is accessible to anonymous users when Jira\\u2019s anonymous
853
- * access is permitted.
854
- *
855
- * @returns Returned if the request is successful.
856
- *
857
- * example: {
858
- * "key": "issue.support",
859
- * "value": {
860
- * "system.conversation.id": "b1bf38be-5e94-4b40-a3b8-9278735ee1e6",
861
- * "system.support.time": "1m"
862
- * }
863
- * }
864
- * @path {GET}
865
- * /rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}
866
- * @scopes-current read:jira-work
867
- * @scopes-beta read:dashboard.property:jira
868
- */
869
- getDashboardItemProperty({
870
- dashboardId,
871
- itemId,
872
- propertyKey,
873
- }: {
874
- /** The ID of the dashboard. */
875
- dashboardId: string;
876
- /** The ID of the dashboard item. */
877
- itemId: string;
878
- /** The key of the dashboard item property. */
879
- propertyKey: string;
880
- }): Promise<EntityProperty> {
881
- return this.getClientInstance()
882
- .request({
883
- path: "/rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}",
884
- method: "GET",
885
- pathParams: {
886
- dashboardId,
887
- itemId,
888
- propertyKey,
889
- },
890
- })
891
- .then(
892
- this.getClientInstance().responseHandler({
893
- 200: {
894
- "application/json": "json",
895
- },
896
- }),
897
- )
898
- .then(
899
- commonHttpClient.castResponse<{
900
- status: 200;
901
- mediaType: "application/json";
902
- body: EntityProperty;
903
- }>(),
904
- )
905
- .then(
906
- validationSchemaStorage.validator(
907
- "DashboardsService.getDashboardItemProperty.response",
908
- ),
909
- )
910
- .then(commonHttpClient.getBody);
911
- }
912
- /**
913
- * Returns the keys of all properties for a dashboard item.
914
- *
915
- * This operation can be accessed anonymously.
916
- *
917
- * **[Permissions](#permissions) required:** The user must be the owner of the
918
- * dashboard or have the dashboard shared with them. Note, users with the
919
- * *Administer Jira* [global
920
- * permission](https://confluence.atlassian.com/x/x4dKLg) are considered owners of
921
- * the System dashboard. The System dashboard is considered to be shared with all
922
- * other users, and is accessible to anonymous users when Jira\\u2019s anonymous
923
- * access is permitted.
924
- *
925
- * @returns Returned if the request is successful.
926
- *
927
- * example: {
928
- * "keys": [
929
- * {
930
- * "key": "issue.support",
931
- * "self":
932
- * "https://your-domain.atlassian.net/rest/api/3/issue/EX-2/properties/issue.support"
933
- * }
934
- * ]
935
- * }
936
- * @path {GET} /rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties
937
- * @scopes-current read:jira-work
938
- * @scopes-beta read:dashboard.property:jira
939
- */
940
- getDashboardItemPropertyKeys({
941
- dashboardId,
942
- itemId,
943
- }: {
944
- /** The ID of the dashboard. */
945
- dashboardId: string;
946
- /** The ID of the dashboard item. */
947
- itemId: string;
948
- }): Promise<PropertyKeys> {
949
- return this.getClientInstance()
950
- .request({
951
- path: "/rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties",
952
- method: "GET",
953
- pathParams: {
954
- dashboardId,
955
- itemId,
956
- },
957
- })
958
- .then(
959
- this.getClientInstance().responseHandler({
960
- 200: {
961
- "application/json": "json",
962
- },
963
- }),
964
- )
965
- .then(
966
- commonHttpClient.castResponse<{
967
- status: 200;
968
- mediaType: "application/json";
969
- body: PropertyKeys;
970
- }>(),
971
- )
972
- .then(
973
- validationSchemaStorage.validator(
974
- "DashboardsService.getDashboardItemPropertyKeys.response",
975
- ),
976
- )
977
- .then(commonHttpClient.getBody);
978
- }
979
- /**
980
- * Returns a [paginated](#pagination) list of dashboards. This operation is
981
- * similar to [Get dashboards](#api-rest-api-3-dashboard-get) except that the
982
- * results can be refined to include dashboards that have specific attributes. For
983
- * example, dashboards with a particular name. When multiple attributes are
984
- * specified only filters matching all attributes are returned.
985
- *
986
- * This operation can be accessed anonymously.
987
- *
988
- * **[Permissions](#permissions) required:** The following dashboards that match
989
- * the query parameters are returned:
990
- *
991
- * * Dashboards owned by the user. Not returned for anonymous users.
992
- * * Dashboards shared with a group that the user is a member of. Not returned
993
- * for anonymous users.
994
- * * Dashboards shared with a private project that the user can browse. Not
995
- * returned for anonymous users.
996
- * * Dashboards shared with a public project.
997
- * * Dashboards shared with the public.
998
- *
999
- * @returns Returned if the request is successful.
1000
- *
1001
- * example: {
1002
- * "isLast": true,
1003
- * "maxResults": 100,
1004
- * "self":
1005
- * "https://your-domain.atlassian.net/rest/api/3/dashboard/search?expand=owner&maxResults=50&startAt=0",
1006
- * "startAt": 0,
1007
- * "total": 2,
1008
- * "values": [
1009
- * {
1010
- * "description": "Testing program",
1011
- * "id": "1",
1012
- * "isFavourite": true,
1013
- * "name": "Testing",
1014
- * "owner": {
1015
- * "self":
1016
- * "https://your-domain.atlassian.net/user?accountId=5b10a2844c20165700ede21g",
1017
- * "displayName": "Mia",
1018
- * "active": true,
1019
- * "accountId": "5b10a2844c20165700ede21g",
1020
- * "avatarUrls": {
1021
- * "16x16":
1022
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
1023
- * "24x24":
1024
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
1025
- * "32x32":
1026
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
1027
- * "48x48":
1028
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
1029
- * }
1030
- * },
1031
- * "popularity": 1,
1032
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/1",
1033
- * "sharePermissions": [
1034
- * {
1035
- * "type": "global"
1036
- * }
1037
- * ],
1038
- * "view": "https://your-domain.atlassian.net/Dashboard.jspa?selectPageId=1"
1039
- * },
1040
- * {
1041
- * "description": "Quantum initiative",
1042
- * "id": "2",
1043
- * "isFavourite": false,
1044
- * "name": "Quantum ",
1045
- * "owner": {
1046
- * "self":
1047
- * "https://your-domain.atlassian.net/user?accountId=5b10a2844c20165700ede21g",
1048
- * "displayName": "Mia",
1049
- * "active": true,
1050
- * "accountId": "5b10a2844c20165700ede21g",
1051
- * "avatarUrls": {
1052
- * "16x16":
1053
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=16&s=16",
1054
- * "24x24":
1055
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=24&s=24",
1056
- * "32x32":
1057
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=32&s=32",
1058
- * "48x48":
1059
- * "https://avatar-management--avatars.server-location.prod.public.atl-paas.net/initials/MK-5.png?size=48&s=48"
1060
- * }
1061
- * },
1062
- * "popularity": 0,
1063
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/2",
1064
- * "sharePermissions": [
1065
- * {
1066
- * "type": "loggedin"
1067
- * }
1068
- * ],
1069
- * "view": "https://your-domain.atlassian.net/Dashboard.jspa?selectPageId=2"
1070
- * }
1071
- * ]
1072
- * }
1073
- * @path {GET} /rest/api/3/dashboard/search
1074
- * @scopes-current read:jira-work
1075
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
1076
- * read:project-role:jira, read:user:jira, read:application-role:jira,
1077
- * read:avatar:jira, read:issue-type-hierarchy:jira, read:issue-type:jira,
1078
- * read:project-category:jira, read:project-version:jira,
1079
- * read:project.component:jira
1080
- */
1081
- getDashboardsPaginated({
1082
- dashboardName,
1083
- accountId,
1084
- owner,
1085
- groupname,
1086
- groupId,
1087
- projectId,
1088
- orderBy,
1089
- startAt,
1090
- maxResults,
1091
- status,
1092
- expand,
1093
- }: {
1094
- /** String used to perform a case-insensitive partial match with `name`. */
1095
- dashboardName?: string;
1096
- /**
1097
- * User account ID used to return dashboards with the matching `owner.accountId`.
1098
- * This parameter cannot be used with the `owner` parameter.
1099
- */
1100
- accountId?: string;
1101
- /**
1102
- * This parameter is deprecated because of privacy changes. Use `accountId`
1103
- * instead. See the [migration
1104
- * guide](https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/)
1105
- * for details. User name used to return dashboards with the matching
1106
- * `owner.name`. This parameter cannot be used with the `accountId` parameter.
1107
- */
1108
- owner?: string;
1109
- /**
1110
- * As a group's name can change, use of `groupId` is recommended. Group name used
1111
- * to return dashboards that are shared with a group that matches
1112
- * `sharePermissions.group.name`. This parameter cannot be used with the `groupId`
1113
- * parameter.
1114
- */
1115
- groupname?: string;
1116
- /**
1117
- * Group ID used to return dashboards that are shared with a group that matches
1118
- * `sharePermissions.group.groupId`. This parameter cannot be used with the
1119
- * `groupname` parameter.
1120
- */
1121
- groupId?: string;
1122
- /**
1123
- * Project ID used to returns dashboards that are shared with a project that
1124
- * matches `sharePermissions.project.id`.
1125
- */
1126
- projectId?: number;
1127
- /**
1128
- * [Order](#ordering) the results by a field:
1129
- *
1130
- * * `description` Sorts by dashboard description. Note that this sort works
1131
- * independently of whether the expand to display the description field is in use.
1132
- * * `favourite_count` Sorts by dashboard popularity.
1133
- * * `id` Sorts by dashboard ID.
1134
- * * `is_favourite` Sorts by whether the dashboard is marked as a favorite.
1135
- * * `name` Sorts by dashboard name.
1136
- * * `owner` Sorts by dashboard owner name.
1137
- */
1138
- orderBy?:
1139
- | "description"
1140
- | "-description"
1141
- | "+description"
1142
- | "favorite_count"
1143
- | "-favorite_count"
1144
- | "+favorite_count"
1145
- | "id"
1146
- | "-id"
1147
- | "+id"
1148
- | "is_favorite"
1149
- | "-is_favorite"
1150
- | "+is_favorite"
1151
- | "name"
1152
- | "-name"
1153
- | "+name"
1154
- | "owner"
1155
- | "-owner"
1156
- | "+owner";
1157
- /** The index of the first item to return in a page of results (page offset). */
1158
- startAt?: number;
1159
- /** The maximum number of items to return per page. */
1160
- maxResults?: number;
1161
- /** The status to filter by. It may be active, archived or deleted. */
1162
- status?: "active" | "archived" | "deleted";
1163
- /**
1164
- * Use [expand](#expansion) to include additional information about dashboard in
1165
- * the response. This parameter accepts a comma-separated list. Expand options
1166
- * include:
1167
- *
1168
- * * `description` Returns the description of the dashboard.
1169
- * * `owner` Returns the owner of the dashboard.
1170
- * * `viewUrl` Returns the URL that is used to view the dashboard.
1171
- * * `favourite` Returns `isFavourite`, an indicator of whether the user has set
1172
- * the dashboard as a favorite.
1173
- * * `favouritedCount` Returns `popularity`, a count of how many users have set
1174
- * this dashboard as a favorite.
1175
- * * `sharePermissions` Returns details of the share permissions defined for the
1176
- * dashboard.
1177
- * * `editPermissions` Returns details of the edit permissions defined for the
1178
- * dashboard.
1179
- * * `isWritable` Returns whether the current user has permission to edit the
1180
- * dashboard.
1181
- */
1182
- expand?: string;
1183
- }): Promise<PageBeanDashboard> {
1184
- return this.getClientInstance()
1185
- .request({
1186
- path: "/rest/api/3/dashboard/search",
1187
- method: "GET",
1188
- query: {
1189
- dashboardName,
1190
- accountId,
1191
- owner,
1192
- groupname,
1193
- groupId,
1194
- projectId,
1195
- orderBy,
1196
- startAt,
1197
- maxResults,
1198
- status,
1199
- expand,
1200
- },
1201
- })
1202
- .then(
1203
- this.getClientInstance().responseHandler({
1204
- 200: {
1205
- "application/json": "json",
1206
- },
1207
- }),
1208
- )
1209
- .then(
1210
- commonHttpClient.castResponse<{
1211
- status: 200;
1212
- mediaType: "application/json";
1213
- body: PageBeanDashboard;
1214
- }>(),
1215
- )
1216
- .then(
1217
- validationSchemaStorage.validator(
1218
- "DashboardsService.getDashboardsPaginated.response",
1219
- ),
1220
- )
1221
- .then(commonHttpClient.getBody);
1222
- }
1223
- /**
1224
- * Removes a dashboard gadget from a dashboard.
1225
- *
1226
- * When a gadget is removed from a dashboard, other gadgets in the same column are
1227
- * moved up to fill the emptied position.
1228
- *
1229
- * **[Permissions](#permissions) required:** None.
1230
- *
1231
- * @returns Returned if the request is successful.
1232
- * @path {DELETE} /rest/api/3/dashboard/{dashboardId}/gadget/{gadgetId}
1233
- * @scopes-current write:jira-work
1234
- * @scopes-beta write:dashboard:jira
1235
- */
1236
- removeGadget({
1237
- dashboardId,
1238
- gadgetId,
1239
- }: {
1240
- /** The ID of the dashboard. */
1241
- dashboardId: number;
1242
- /** The ID of the gadget. */
1243
- gadgetId: number;
1244
- }): Promise<void> {
1245
- return this.getClientInstance()
1246
- .request({
1247
- path: "/rest/api/3/dashboard/{dashboardId}/gadget/{gadgetId}",
1248
- method: "DELETE",
1249
- pathParams: {
1250
- dashboardId,
1251
- gadgetId,
1252
- },
1253
- })
1254
- .then(
1255
- this.getClientInstance().responseHandler({
1256
- 204: {
1257
- "application/json": "json",
1258
- },
1259
- }),
1260
- )
1261
- .then(
1262
- commonHttpClient.castResponse<{
1263
- status: 204;
1264
- mediaType: "application/json";
1265
- body: void;
1266
- }>(),
1267
- )
1268
- .then(
1269
- validationSchemaStorage.validator(
1270
- "DashboardsService.removeGadget.response",
1271
- ),
1272
- )
1273
- .then(commonHttpClient.getBody);
1274
- }
1275
- /**
1276
- * Sets the value of a dashboard item property. Use this resource in apps to store
1277
- * custom data against a dashboard item.
1278
- *
1279
- * A dashboard item enables an app to add user-specific information to a user
1280
- * dashboard. Dashboard items are exposed to users as gadgets that users can add
1281
- * to their dashboards. For more information on how users do this, see [Adding and
1282
- * customizing gadgets](https://confluence.atlassian.com/x/7AeiLQ).
1283
- *
1284
- * When an app creates a dashboard item it registers a callback to receive the
1285
- * dashboard item ID. The callback fires whenever the item is rendered or, where
1286
- * the item is configurable, the user edits the item. The app then uses this
1287
- * resource to store the item's content or configuration details. For more
1288
- * information on working with dashboard items, see [ Building a dashboard item
1289
- * for a JIRA Connect
1290
- * add-on](https://developer.atlassian.com/server/jira/platform/guide-building-a-dashboard-item-for-a-jira-connect-add-on-33746254/)
1291
- * and the [Dashboard
1292
- * Item](https://developer.atlassian.com/cloud/jira/platform/modules/dashboard-item/)
1293
- * documentation.
1294
- *
1295
- * There is no resource to set or get dashboard items.
1296
- *
1297
- * The value of the request body must be a
1298
- * [valid](http://tools.ietf.org/html/rfc4627), non-empty JSON blob. The maximum
1299
- * length is 32768 characters.
1300
- *
1301
- * This operation can be accessed anonymously.
1302
- *
1303
- * **[Permissions](#permissions) required:** The user must be the owner of the
1304
- * dashboard. Note, users with the *Administer Jira* [global
1305
- * permission](https://confluence.atlassian.com/x/x4dKLg) are considered owners of
1306
- * the System dashboard.
1307
- *
1308
- * @returns * status: 200, mediaType: application/json
1309
- *
1310
- * Returned if the dashboard item property is updated.
1311
- *
1312
- * * status: 201, mediaType: application/json
1313
- *
1314
- * Returned if the dashboard item property is created.
1315
- * @path {PUT}
1316
- * /rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}
1317
- * @scopes-current write:jira-work
1318
- * @scopes-beta write:dashboard.property:jira
1319
- */
1320
- setDashboardItemProperty({
1321
- dashboardId,
1322
- itemId,
1323
- propertyKey,
1324
- requestBody,
1325
- }: {
1326
- /** The ID of the dashboard. */
1327
- dashboardId: string;
1328
- /** The ID of the dashboard item. */
1329
- itemId: string;
1330
- /**
1331
- * The key of the dashboard item property. The maximum length is 255 characters.
1332
- * For dashboard items with a spec URI and no complete module key, if the provided
1333
- * propertyKey is equal to "config", the request body's JSON must be an object
1334
- * with all keys and values as strings.
1335
- */
1336
- propertyKey: string;
1337
- /**
1338
- * The value of the property. The value has to be a valid, non-empty
1339
- * [JSON](https://tools.ietf.org/html/rfc4627) value. The maximum length of the
1340
- * property value is 32768 bytes.
1341
- *
1342
- * @example {
1343
- * "number": 5,
1344
- * "string": "string-value"
1345
- * }
1346
- */
1347
- requestBody: unknown;
1348
- }): Promise<{
1349
- created: boolean;
1350
- body: unknown;
1351
- }> {
1352
- return this.getClientInstance()
1353
- .request({
1354
- path: "/rest/api/3/dashboard/{dashboardId}/items/{itemId}/properties/{propertyKey}",
1355
- method: "PUT",
1356
- pathParams: {
1357
- dashboardId,
1358
- itemId,
1359
- propertyKey,
1360
- },
1361
- headers: {
1362
- "Content-Type": "application/json",
1363
- },
1364
- body: requestBody,
1365
- })
1366
- .then(
1367
- this.getClientInstance().responseHandler({
1368
- 200: {
1369
- "application/json": "json",
1370
- },
1371
- 201: {
1372
- "application/json": "json",
1373
- },
1374
- }),
1375
- )
1376
- .then(
1377
- commonHttpClient.castResponse<{
1378
- status: 200 | 201;
1379
- mediaType: "application/json";
1380
- body: unknown;
1381
- }>(),
1382
- )
1383
- .then(
1384
- validationSchemaStorage.validator(
1385
- "DashboardsService.setDashboardItemProperty.response",
1386
- ),
1387
- )
1388
- .then(commonHttpClient.asCreatedResponse("body"));
1389
- }
1390
- /**
1391
- * Updates a dashboard, replacing all the dashboard details with those provided.
1392
- *
1393
- * **[Permissions](#permissions) required:** None
1394
- *
1395
- * The dashboard to be updated must be owned by the user.
1396
- *
1397
- * @returns Returned if the request is successful.
1398
- *
1399
- * example: {
1400
- * "id": "10000",
1401
- * "isFavourite": false,
1402
- * "name": "System Dashboard",
1403
- * "popularity": 1,
1404
- * "self": "https://your-domain.atlassian.net/rest/api/3/dashboard/10000",
1405
- * "sharePermissions": [
1406
- * {
1407
- * "type": "global"
1408
- * }
1409
- * ],
1410
- * "view":
1411
- * "https://your-domain.atlassian.net/secure/Dashboard.jspa?selectPageId=10000"
1412
- * }
1413
- * @path {PUT} /rest/api/3/dashboard/{id}
1414
- * @scopes-current write:jira-work
1415
- * @scopes-beta read:dashboard:jira, read:group:jira, read:project:jira,
1416
- * read:project-role:jira, read:user:jira, write:dashboard:jira,
1417
- * read:application-role:jira, read:avatar:jira, read:issue-type-hierarchy:jira,
1418
- * read:issue-type:jira, read:project-category:jira, read:project-version:jira,
1419
- * read:project.component:jira
1420
- */
1421
- updateDashboard({
1422
- id,
1423
- dashboardDetails,
1424
- }: {
1425
- /** The ID of the dashboard to update. */
1426
- id: string;
1427
- /**
1428
- * Replacement dashboard details.
1429
- *
1430
- * @example {
1431
- * "description": "A dashboard to help auditors identify sample of issues to
1432
- * check.",
1433
- * "editPermissions": [],
1434
- * "name": "Auditors dashboard",
1435
- * "sharePermissions": [
1436
- * {
1437
- * "type": "global"
1438
- * }
1439
- * ]
1440
- * }
1441
- */
1442
- dashboardDetails: DashboardDetails;
1443
- }): Promise<Dashboard> {
1444
- return this.getClientInstance()
1445
- .request({
1446
- path: "/rest/api/3/dashboard/{id}",
1447
- method: "PUT",
1448
- pathParams: {
1449
- id,
1450
- },
1451
- headers: {
1452
- "Content-Type": "application/json",
1453
- },
1454
- body: dashboardDetails,
1455
- })
1456
- .then(
1457
- this.getClientInstance().responseHandler({
1458
- 200: {
1459
- "application/json": "json",
1460
- },
1461
- }),
1462
- )
1463
- .then(
1464
- commonHttpClient.castResponse<{
1465
- status: 200;
1466
- mediaType: "application/json";
1467
- body: Dashboard;
1468
- }>(),
1469
- )
1470
- .then(
1471
- validationSchemaStorage.validator(
1472
- "DashboardsService.updateDashboard.response",
1473
- ),
1474
- )
1475
- .then(commonHttpClient.getBody);
1476
- }
1477
- /**
1478
- * Changes the title, position, and color of the gadget on a dashboard.
1479
- *
1480
- * **[Permissions](#permissions) required:** None.
1481
- *
1482
- * @returns Returned if the request is successful.
1483
- * @path {PUT} /rest/api/3/dashboard/{dashboardId}/gadget/{gadgetId}
1484
- * @scopes-current write:jira-work
1485
- * @scopes-beta write:dashboard:jira
1486
- */
1487
- updateGadget({
1488
- dashboardId,
1489
- gadgetId,
1490
- dashboardGadgetUpdateRequest,
1491
- }: {
1492
- /** The ID of the dashboard. */
1493
- dashboardId: number;
1494
- /** The ID of the gadget. */
1495
- gadgetId: number;
1496
- /**
1497
- * @example {
1498
- * "color": "red",
1499
- * "position": {
1500
- * "column": 1,
1501
- * "row": 1
1502
- * },
1503
- * "title": "My new gadget title"
1504
- * }
1505
- */
1506
- dashboardGadgetUpdateRequest: DashboardGadgetUpdateRequest;
1507
- }): Promise<void> {
1508
- return this.getClientInstance()
1509
- .request({
1510
- path: "/rest/api/3/dashboard/{dashboardId}/gadget/{gadgetId}",
1511
- method: "PUT",
1512
- pathParams: {
1513
- dashboardId,
1514
- gadgetId,
1515
- },
1516
- headers: {
1517
- "Content-Type": "application/json",
1518
- },
1519
- body: dashboardGadgetUpdateRequest,
1520
- })
1521
- .then(
1522
- this.getClientInstance().responseHandler({
1523
- 204: {
1524
- "application/json": "json",
1525
- },
1526
- }),
1527
- )
1528
- .then(
1529
- commonHttpClient.castResponse<{
1530
- status: 204;
1531
- mediaType: "application/json";
1532
- body: void;
1533
- }>(),
1534
- )
1535
- .then(
1536
- validationSchemaStorage.validator(
1537
- "DashboardsService.updateGadget.response",
1538
- ),
1539
- )
1540
- .then(commonHttpClient.getBody);
1541
- }
1542
- static initialize() {
1543
- validationSchemaStorage.registerExtensible(
1544
- "DashboardsService.getAllDashboards.response",
1545
- z
1546
- .object({
1547
- status: z.literal(200),
1548
- mediaType: z.literal("application/json"),
1549
- body: validationSchemaStorage.lazy("PageOfDashboards"),
1550
- })
1551
- .describe("DashboardsService.getAllDashboards.response"),
1552
- );
1553
- validationSchemaStorage.registerExtensible(
1554
- "DashboardsService.createDashboard.response",
1555
- z
1556
- .object({
1557
- status: z.literal(200),
1558
- mediaType: z.literal("application/json"),
1559
- body: validationSchemaStorage.lazy("Dashboard"),
1560
- })
1561
- .describe("DashboardsService.createDashboard.response"),
1562
- );
1563
- validationSchemaStorage.registerExtensible(
1564
- "DashboardsService.getAllGadgets.response",
1565
- z
1566
- .object({
1567
- status: z.literal(200),
1568
- mediaType: z.literal("application/json"),
1569
- body: validationSchemaStorage.lazy("DashboardGadgetResponse"),
1570
- })
1571
- .describe("DashboardsService.getAllGadgets.response"),
1572
- );
1573
- validationSchemaStorage.registerExtensible(
1574
- "DashboardsService.addGadget.response",
1575
- z
1576
- .object({
1577
- status: z.literal(200),
1578
- mediaType: z.literal("application/json"),
1579
- body: validationSchemaStorage.lazy("DashboardGadget"),
1580
- })
1581
- .describe("DashboardsService.addGadget.response"),
1582
- );
1583
- validationSchemaStorage.registerExtensible(
1584
- "DashboardsService.updateGadget.response",
1585
- z
1586
- .object({
1587
- status: z.literal(204),
1588
- mediaType: z.literal("application/json"),
1589
- body: z.unknown(),
1590
- })
1591
- .describe("DashboardsService.updateGadget.response"),
1592
- );
1593
- validationSchemaStorage.registerExtensible(
1594
- "DashboardsService.removeGadget.response",
1595
- z
1596
- .object({
1597
- status: z.literal(204),
1598
- mediaType: z.literal("application/json"),
1599
- body: z.unknown(),
1600
- })
1601
- .describe("DashboardsService.removeGadget.response"),
1602
- );
1603
- validationSchemaStorage.registerExtensible(
1604
- "DashboardsService.getDashboardItemPropertyKeys.response",
1605
- z
1606
- .object({
1607
- status: z.literal(200),
1608
- mediaType: z.literal("application/json"),
1609
- body: validationSchemaStorage.lazy("PropertyKeys"),
1610
- })
1611
- .describe("DashboardsService.getDashboardItemPropertyKeys.response"),
1612
- );
1613
- validationSchemaStorage.registerExtensible(
1614
- "DashboardsService.getDashboardItemProperty.response",
1615
- z
1616
- .object({
1617
- status: z.literal(200),
1618
- mediaType: z.literal("application/json"),
1619
- body: validationSchemaStorage.lazy("EntityProperty"),
1620
- })
1621
- .describe("DashboardsService.getDashboardItemProperty.response"),
1622
- );
1623
- validationSchemaStorage.registerExtensible(
1624
- "DashboardsService.setDashboardItemProperty.response",
1625
- z
1626
- .object({
1627
- status: z.number(),
1628
- mediaType: z.string(),
1629
- body: z.unknown(),
1630
- })
1631
- .superRefine(({ status: status, body: body }, ctx) => {
1632
- if (status === 200 || status === 201) {
1633
- z.unknown().parse(body);
1634
- } else {
1635
- ctx.addIssue({
1636
- code: z.ZodIssueCode.custom,
1637
- path: ["status"],
1638
- message: `Unexpected status code: ${status}`,
1639
- });
1640
- }
1641
- })
1642
- .describe("DashboardsService.setDashboardItemProperty.response"),
1643
- );
1644
- validationSchemaStorage.registerExtensible(
1645
- "DashboardsService.deleteDashboardItemProperty.response",
1646
- z
1647
- .object({
1648
- status: z.literal(204),
1649
- mediaType: z.literal("application/json"),
1650
- body: z.unknown(),
1651
- })
1652
- .describe("DashboardsService.deleteDashboardItemProperty.response"),
1653
- );
1654
- validationSchemaStorage.registerExtensible(
1655
- "DashboardsService.getDashboard.response",
1656
- z
1657
- .object({
1658
- status: z.literal(200),
1659
- mediaType: z.literal("application/json"),
1660
- body: validationSchemaStorage.lazy("Dashboard"),
1661
- })
1662
- .describe("DashboardsService.getDashboard.response"),
1663
- );
1664
- validationSchemaStorage.registerExtensible(
1665
- "DashboardsService.updateDashboard.response",
1666
- z
1667
- .object({
1668
- status: z.literal(200),
1669
- mediaType: z.literal("application/json"),
1670
- body: validationSchemaStorage.lazy("Dashboard"),
1671
- })
1672
- .describe("DashboardsService.updateDashboard.response"),
1673
- );
1674
- validationSchemaStorage.registerExtensible(
1675
- "DashboardsService.copyDashboard.response",
1676
- z
1677
- .object({
1678
- status: z.literal(200),
1679
- mediaType: z.literal("application/json"),
1680
- body: validationSchemaStorage.lazy("Dashboard"),
1681
- })
1682
- .describe("DashboardsService.copyDashboard.response"),
1683
- );
1684
- validationSchemaStorage.registerExtensible(
1685
- "DashboardsService.bulkEditDashboards.response",
1686
- z
1687
- .object({
1688
- status: z.literal(200),
1689
- mediaType: z.literal("application/json"),
1690
- body: validationSchemaStorage.lazy("BulkEditShareableEntityResponse"),
1691
- })
1692
- .describe("DashboardsService.bulkEditDashboards.response"),
1693
- );
1694
- validationSchemaStorage.registerExtensible(
1695
- "DashboardsService.getAllAvailableDashboardGadgets.response",
1696
- z
1697
- .object({
1698
- status: z.literal(200),
1699
- mediaType: z.literal("application/json"),
1700
- body: validationSchemaStorage.lazy(
1701
- "AvailableDashboardGadgetsResponse",
1702
- ),
1703
- })
1704
- .describe("DashboardsService.getAllAvailableDashboardGadgets.response"),
1705
- );
1706
- validationSchemaStorage.registerExtensible(
1707
- "DashboardsService.getDashboardsPaginated.response",
1708
- z
1709
- .object({
1710
- status: z.literal(200),
1711
- mediaType: z.literal("application/json"),
1712
- body: validationSchemaStorage.lazy("PageBeanDashboard"),
1713
- })
1714
- .describe("DashboardsService.getDashboardsPaginated.response"),
1715
- );
1716
- validationSchemaStorage.registerOnce([
1717
- registerDashboardsValidationSchemas,
1718
- registerCommonValidationSchemas,
1719
- ]);
1720
- }
1721
- }