@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,527 +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, type ZodTypeAny } from "zod";
5
-
6
- import type { CommonValidationSchemaStorage } from "../core/common-validation-schema-storage";
7
- import {
8
- type JsonNode,
9
- type PageBeanProjectDetails,
10
- registerCommonValidationSchemas,
11
- } from "./common";
12
- /** Details of a new priority scheme */
13
- export interface CreatePrioritySchemeDetails {
14
- /** The ID of the default priority for the priority scheme. */
15
- defaultPriorityId: number;
16
- /** The description of the priority scheme. */
17
- description?: string;
18
- /**
19
- * Mappings of issue priorities for issues being migrated in and out of this
20
- * priority scheme.
21
- */
22
- mappings?: PriorityMapping;
23
- /** The name of the priority scheme. Must be unique. */
24
- name: string;
25
- /** The IDs of priorities in the scheme. */
26
- priorityIds: number[];
27
- /** The IDs of projects that will use the priority scheme. */
28
- projectIds?: number[];
29
- }
30
- /** A page of items. */
31
- export interface PageBeanPrioritySchemeWithPaginatedPrioritiesAndProjects {
32
- /** Whether this is the last page. */
33
- isLast?: boolean;
34
- /** The maximum number of items that could be returned. */
35
- maxResults?: number;
36
- /** If there is another page of results, the URL of the next page. */
37
- nextPage?: string;
38
- /** The URL of the page. */
39
- self?: string;
40
- /** The index of the first item returned. */
41
- startAt?: number;
42
- /** The number of items returned. */
43
- total?: number;
44
- /** The list of items. */
45
- values?: PrioritySchemeWithPaginatedPrioritiesAndProjects[];
46
- }
47
- /** A page of items. */
48
- export interface PageBeanPriorityWithSequence {
49
- /** Whether this is the last page. */
50
- isLast?: boolean;
51
- /** The maximum number of items that could be returned. */
52
- maxResults?: number;
53
- /** If there is another page of results, the URL of the next page. */
54
- nextPage?: string;
55
- /** The URL of the page. */
56
- self?: string;
57
- /** The index of the first item returned. */
58
- startAt?: number;
59
- /** The number of items returned. */
60
- total?: number;
61
- /** The list of items. */
62
- values?: PriorityWithSequence[];
63
- }
64
- /** Mapping of issue priorities for changes in priority schemes. */
65
- export interface PriorityMapping {
66
- /**
67
- * The mapping of priorities for issues being migrated **into** this priority
68
- * scheme. Key is the old priority ID, value is the new priority ID (must exist in
69
- * this priority scheme).
70
- */
71
- in?: {
72
- [key: string]: number;
73
- };
74
- /**
75
- * The mapping of priorities for issues being migrated **out of** this priority
76
- * scheme. Key is the old priority ID (must exist in this priority scheme), value
77
- * is the new priority ID (must exist in the default priority scheme). Required
78
- * for updating an existing priority scheme. Not used when creating a new priority
79
- * scheme.
80
- */
81
- out?: {
82
- [key: string]: number;
83
- };
84
- }
85
- /** Priorities to remove from a scheme */
86
- export interface PrioritySchemeChangesWithMappings {
87
- /** Affected entity ids. */
88
- ids: number[];
89
- /** Instructions to migrate issues. */
90
- mappings?: PriorityMapping[];
91
- }
92
- /** Priorities to add to a scheme */
93
- export interface PrioritySchemeChangesWithoutMappings {
94
- /** Affected entity ids. */
95
- ids: number[];
96
- }
97
- /** The ID of a priority scheme. */
98
- export interface PrioritySchemeId {
99
- /** The ID of the priority scheme. */
100
- id?: string;
101
- /** The in-progress issue migration task. */
102
- task?: TaskProgressBeanJsonNode;
103
- }
104
- /** A priority scheme with paginated priorities and projects. */
105
- export interface PrioritySchemeWithPaginatedPrioritiesAndProjects
106
- extends Record<string, unknown> {
107
- default?: boolean;
108
- /** The ID of the default issue priority. */
109
- defaultPriorityId?: string;
110
- /** The description of the priority scheme */
111
- description?: string;
112
- /** The ID of the priority scheme. */
113
- id: string;
114
- isDefault?: boolean;
115
- /** The name of the priority scheme */
116
- name: string;
117
- /** The paginated list of priorities. */
118
- priorities?: PageBeanPriorityWithSequence;
119
- /** The paginated list of projects. */
120
- projects?: PageBeanProjectDetails;
121
- /** The URL of the priority scheme. */
122
- self?: string;
123
- }
124
- /** An issue priority with sequence information. */
125
- export interface PriorityWithSequence {
126
- /** The description of the issue priority. */
127
- description?: string;
128
- /** The URL of the icon for the issue priority. */
129
- iconUrl?: string;
130
- /** The ID of the issue priority. */
131
- id?: string;
132
- /** Whether this priority is the default. */
133
- isDefault?: boolean;
134
- /** The name of the issue priority. */
135
- name?: string;
136
- /** The URL of the issue priority. */
137
- self?: string;
138
- /** The sequence of the issue priority. */
139
- sequence?: string;
140
- /** The color used to indicate the issue priority. */
141
- statusColor?: string;
142
- }
143
- /**
144
- * Details of changes to a priority scheme's priorities that require suggested
145
- * priority mappings.
146
- */
147
- export interface SuggestedMappingsForPrioritiesRequestBean {
148
- /** The ids of priorities being removed from the scheme. */
149
- add?: number[];
150
- /** The ids of priorities being removed from the scheme. */
151
- remove?: number[];
152
- }
153
- /**
154
- * Details of changes to a priority scheme's projects that require suggested
155
- * priority mappings.
156
- */
157
- export interface SuggestedMappingsForProjectsRequestBean {
158
- /** The ids of projects being added to the scheme. */
159
- add?: number[];
160
- }
161
- /**
162
- * Details of changes to a priority scheme that require suggested priority
163
- * mappings.
164
- */
165
- export interface SuggestedMappingsRequestBean {
166
- /** The maximum number of results that could be on the page. */
167
- maxResults?: number;
168
- /** The priority changes in the scheme. */
169
- priorities?: SuggestedMappingsForPrioritiesRequestBean;
170
- /** The project changes in the scheme. */
171
- projects?: SuggestedMappingsForProjectsRequestBean;
172
- /** The id of the priority scheme. */
173
- schemeId?: number;
174
- /** The index of the first item returned on the page. */
175
- startAt?: number;
176
- }
177
- /** Details about a task. */
178
- export interface TaskProgressBeanJsonNode {
179
- /** The description of the task. */
180
- description?: string;
181
- /** The execution time of the task, in milliseconds. */
182
- elapsedRuntime: number;
183
- /** A timestamp recording when the task was finished. */
184
- finished?: number;
185
- /** The ID of the task. */
186
- id: string;
187
- /** A timestamp recording when the task progress was last updated. */
188
- lastUpdate: number;
189
- /** Information about the progress of the task. */
190
- message?: string;
191
- /** The progress of the task, as a percentage complete. */
192
- progress: number;
193
- /** The result of the task execution. */
194
- result?: JsonNode;
195
- /** The URL of the task. */
196
- self: string;
197
- /** A timestamp recording when the task was started. */
198
- started?: number;
199
- /** The status of the task. */
200
- status:
201
- | "ENQUEUED"
202
- | "RUNNING"
203
- | "COMPLETE"
204
- | "FAILED"
205
- | "CANCEL_REQUESTED"
206
- | "CANCELLED"
207
- | "DEAD";
208
- /** A timestamp recording when the task was submitted. */
209
- submitted: number;
210
- /** The ID of the user who submitted the task. */
211
- submittedBy: number;
212
- }
213
- /** Update priorities in a scheme */
214
- export interface UpdatePrioritiesInSchemeRequestBean
215
- extends Record<string, unknown> {
216
- /** Priorities to add to a scheme */
217
- add?: PrioritySchemeChangesWithoutMappings;
218
- /** Priorities to remove from a scheme */
219
- remove?: PrioritySchemeChangesWithMappings;
220
- }
221
- /** Details of a priority scheme. */
222
- export interface UpdatePrioritySchemeRequestBean {
223
- /** The default priority of the scheme. */
224
- defaultPriorityId?: number;
225
- /** The description of the priority scheme. */
226
- description?: string;
227
- /** Instructions to migrate issues. */
228
- mappings?: PriorityMapping;
229
- /** The name of the priority scheme. Must be unique. */
230
- name?: string;
231
- /** The priorities in the scheme. */
232
- priorities?: UpdatePrioritiesInSchemeRequestBean;
233
- /** The projects in the scheme. */
234
- projects?: UpdateProjectsInSchemeRequestBean;
235
- }
236
- /** Details of the updated priority scheme. */
237
- export interface UpdatePrioritySchemeResponseBean
238
- extends Record<string, unknown> {
239
- /** A priority scheme with paginated priorities and projects. */
240
- priorityScheme?: PrioritySchemeWithPaginatedPrioritiesAndProjects;
241
- /** The in-progress issue migration task. */
242
- task?: TaskProgressBeanJsonNode;
243
- }
244
- /** Update projects in a scheme */
245
- export interface UpdateProjectsInSchemeRequestBean
246
- extends Record<string, unknown> {
247
- /** Projects to add to a scheme */
248
- add?: PrioritySchemeChangesWithoutMappings;
249
- /** Projects to remove from a scheme */
250
- remove?: PrioritySchemeChangesWithoutMappings;
251
- }
252
- export function registerPrioritySchemesValidationSchemas(
253
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
254
- ) {
255
- validationSchemaStorage.register(
256
- "CreatePrioritySchemeDetails",
257
- z
258
- .object({
259
- defaultPriorityId: z.number().int(),
260
- description: z.string().max(4000).optional(),
261
- mappings: validationSchemaStorage.lazy("PriorityMapping").optional(),
262
- name: z.string().max(255),
263
- priorityIds: z.array(z.number().int()),
264
- projectIds: z
265
- .array(z.number().int())
266
- .superRefine((items, ctx) => {
267
- if (
268
- new Set(items.map((item) => JSON.stringify(item))).size !==
269
- items.length
270
- ) {
271
- ctx.addIssue({
272
- code: z.ZodIssueCode.custom,
273
- path: [],
274
- message: "Array items must be unique",
275
- });
276
- }
277
- })
278
- .optional(),
279
- })
280
- .strict()
281
- .describe("CreatePrioritySchemeDetails"),
282
- );
283
- validationSchemaStorage.register(
284
- "PageBeanPrioritySchemeWithPaginatedPrioritiesAndProjects",
285
- z
286
- .object({
287
- isLast: z.boolean().optional(),
288
- maxResults: z.number().int().optional(),
289
- nextPage: z.string().optional(),
290
- self: z.string().optional(),
291
- startAt: z.number().int().optional(),
292
- total: z.number().int().optional(),
293
- values: z
294
- .array(
295
- validationSchemaStorage.lazy(
296
- "PrioritySchemeWithPaginatedPrioritiesAndProjects",
297
- ),
298
- )
299
- .optional(),
300
- })
301
- .strict()
302
- .describe("PageBeanPrioritySchemeWithPaginatedPrioritiesAndProjects"),
303
- );
304
- validationSchemaStorage.register(
305
- "PageBeanPriorityWithSequence",
306
- z
307
- .object({
308
- isLast: z.boolean().optional(),
309
- maxResults: z.number().int().optional(),
310
- nextPage: z.string().optional(),
311
- self: z.string().optional(),
312
- startAt: z.number().int().optional(),
313
- total: z.number().int().optional(),
314
- values: z
315
- .array(validationSchemaStorage.lazy("PriorityWithSequence"))
316
- .optional(),
317
- })
318
- .strict()
319
- .describe("PageBeanPriorityWithSequence"),
320
- );
321
- validationSchemaStorage.register(
322
- "PriorityMapping",
323
- z
324
- .object({
325
- in: z.object({}).catchall(z.number().int()).optional(),
326
- out: z.object({}).catchall(z.number().int()).optional(),
327
- })
328
- .strict()
329
- .describe("PriorityMapping"),
330
- );
331
- validationSchemaStorage.register(
332
- "PrioritySchemeChangesWithMappings",
333
- z
334
- .object({
335
- ids: z.array(z.number().int()),
336
- mappings: z
337
- .array(validationSchemaStorage.lazy("PriorityMapping"))
338
- .optional(),
339
- })
340
- .strict()
341
- .describe("PrioritySchemeChangesWithMappings"),
342
- );
343
- validationSchemaStorage.register(
344
- "PrioritySchemeChangesWithoutMappings",
345
- z
346
- .object({
347
- ids: z.array(z.number().int()),
348
- })
349
- .strict()
350
- .describe("PrioritySchemeChangesWithoutMappings"),
351
- );
352
- validationSchemaStorage.register(
353
- "PrioritySchemeId",
354
- z
355
- .object({
356
- id: z.string().optional(),
357
- task: validationSchemaStorage
358
- .lazy("TaskProgressBeanJsonNode")
359
- .optional(),
360
- })
361
- .strict()
362
- .describe("PrioritySchemeId"),
363
- );
364
- validationSchemaStorage.register(
365
- "PrioritySchemeWithPaginatedPrioritiesAndProjects",
366
- z
367
- .object({
368
- default: z.boolean().optional(),
369
- defaultPriorityId: z.string().optional(),
370
- description: z.string().optional(),
371
- id: z.string(),
372
- isDefault: z.boolean().optional(),
373
- name: z.string(),
374
- priorities: validationSchemaStorage
375
- .lazy("PageBeanPriorityWithSequence")
376
- .optional(),
377
- projects: validationSchemaStorage
378
- .lazy("PageBeanProjectDetails")
379
- .optional(),
380
- self: z.string().optional(),
381
- })
382
- .catchall(z.unknown())
383
- .describe("PrioritySchemeWithPaginatedPrioritiesAndProjects"),
384
- );
385
- validationSchemaStorage.register(
386
- "PriorityWithSequence",
387
- z
388
- .object({
389
- description: z.string().optional(),
390
- iconUrl: z.string().optional(),
391
- id: z.string().optional(),
392
- isDefault: z.boolean().optional(),
393
- name: z.string().optional(),
394
- self: z.string().optional(),
395
- sequence: z.string().optional(),
396
- statusColor: z.string().optional(),
397
- })
398
- .strict()
399
- .describe("PriorityWithSequence"),
400
- );
401
- validationSchemaStorage.register(
402
- "SuggestedMappingsForPrioritiesRequestBean",
403
- z
404
- .object({
405
- add: z.array(z.number().int()).optional(),
406
- remove: z.array(z.number().int()).optional(),
407
- })
408
- .strict()
409
- .describe("SuggestedMappingsForPrioritiesRequestBean"),
410
- );
411
- validationSchemaStorage.register(
412
- "SuggestedMappingsForProjectsRequestBean",
413
- z
414
- .object({
415
- add: z.array(z.number().int()).optional(),
416
- })
417
- .strict()
418
- .describe("SuggestedMappingsForProjectsRequestBean"),
419
- );
420
- validationSchemaStorage.register(
421
- "SuggestedMappingsRequestBean",
422
- z
423
- .object({
424
- maxResults: z.number().int().optional(),
425
- priorities: validationSchemaStorage
426
- .lazy("SuggestedMappingsForPrioritiesRequestBean")
427
- .optional(),
428
- projects: validationSchemaStorage
429
- .lazy("SuggestedMappingsForProjectsRequestBean")
430
- .optional(),
431
- schemeId: z.number().int().optional(),
432
- startAt: z.number().int().optional(),
433
- })
434
- .strict()
435
- .describe("SuggestedMappingsRequestBean"),
436
- );
437
- validationSchemaStorage.register(
438
- "TaskProgressBeanJsonNode",
439
- z
440
- .object({
441
- description: z.string().optional(),
442
- elapsedRuntime: z.number().int(),
443
- finished: z.number().int().optional(),
444
- id: z.string(),
445
- lastUpdate: z.number().int(),
446
- message: z.string().optional(),
447
- progress: z.number().int(),
448
- result: validationSchemaStorage.lazy("JsonNode").optional(),
449
- self: z.string(),
450
- started: z.number().int().optional(),
451
- status: z.enum([
452
- "ENQUEUED",
453
- "RUNNING",
454
- "COMPLETE",
455
- "FAILED",
456
- "CANCEL_REQUESTED",
457
- "CANCELLED",
458
- "DEAD",
459
- ]),
460
- submitted: z.number().int(),
461
- submittedBy: z.number().int(),
462
- })
463
- .strict()
464
- .describe("TaskProgressBeanJsonNode"),
465
- );
466
- validationSchemaStorage.register(
467
- "UpdatePrioritiesInSchemeRequestBean",
468
- z
469
- .object({
470
- add: validationSchemaStorage
471
- .lazy("PrioritySchemeChangesWithoutMappings")
472
- .optional(),
473
- remove: validationSchemaStorage
474
- .lazy("PrioritySchemeChangesWithMappings")
475
- .optional(),
476
- })
477
- .catchall(z.unknown())
478
- .describe("UpdatePrioritiesInSchemeRequestBean"),
479
- );
480
- validationSchemaStorage.register(
481
- "UpdatePrioritySchemeRequestBean",
482
- z
483
- .object({
484
- defaultPriorityId: z.number().int().optional(),
485
- description: z.string().max(4000).optional(),
486
- mappings: validationSchemaStorage.lazy("PriorityMapping").optional(),
487
- name: z.string().max(255).optional(),
488
- priorities: validationSchemaStorage
489
- .lazy("UpdatePrioritiesInSchemeRequestBean")
490
- .optional(),
491
- projects: validationSchemaStorage
492
- .lazy("UpdateProjectsInSchemeRequestBean")
493
- .optional(),
494
- })
495
- .strict()
496
- .describe("UpdatePrioritySchemeRequestBean"),
497
- );
498
- validationSchemaStorage.register(
499
- "UpdatePrioritySchemeResponseBean",
500
- z
501
- .object({
502
- priorityScheme: validationSchemaStorage
503
- .lazy("PrioritySchemeWithPaginatedPrioritiesAndProjects")
504
- .optional(),
505
- task: validationSchemaStorage
506
- .lazy("TaskProgressBeanJsonNode")
507
- .optional(),
508
- })
509
- .catchall(z.unknown())
510
- .describe("UpdatePrioritySchemeResponseBean"),
511
- );
512
- validationSchemaStorage.register(
513
- "UpdateProjectsInSchemeRequestBean",
514
- z
515
- .object({
516
- add: validationSchemaStorage
517
- .lazy("PrioritySchemeChangesWithoutMappings")
518
- .optional(),
519
- remove: validationSchemaStorage
520
- .lazy("PrioritySchemeChangesWithoutMappings")
521
- .optional(),
522
- })
523
- .catchall(z.unknown())
524
- .describe("UpdateProjectsInSchemeRequestBean"),
525
- );
526
- validationSchemaStorage.registerOnce([registerCommonValidationSchemas]);
527
- }
@@ -1,29 +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, type ZodTypeAny } from "zod";
5
-
6
- import type { CommonValidationSchemaStorage } from "../core/common-validation-schema-storage";
7
- import { type Avatar, registerCommonValidationSchemas } from "./common";
8
- /** List of project avatars. */
9
- export interface ProjectAvatars {
10
- /** List of avatars added to Jira. These avatars may be deleted. */
11
- custom?: Avatar[];
12
- /** List of avatars included with Jira. These avatars cannot be deleted. */
13
- system?: Avatar[];
14
- }
15
- export function registerProjectAvatarsValidationSchemas(
16
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
17
- ) {
18
- validationSchemaStorage.register(
19
- "ProjectAvatars",
20
- z
21
- .object({
22
- custom: z.array(validationSchemaStorage.lazy("Avatar")).optional(),
23
- system: z.array(validationSchemaStorage.lazy("Avatar")).optional(),
24
- })
25
- .strict()
26
- .describe("ProjectAvatars"),
27
- );
28
- validationSchemaStorage.registerOnce([registerCommonValidationSchemas]);
29
- }
@@ -1,24 +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, type ZodTypeAny } from "zod";
5
-
6
- import type { CommonValidationSchemaStorage } from "../core/common-validation-schema-storage";
7
- /** The request for updating the default project classification level. */
8
- export interface UpdateDefaultProjectClassificationBean {
9
- /** The ID of the project classification. */
10
- id: string;
11
- }
12
- export function registerProjectClassificationLevelsValidationSchemas(
13
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
14
- ) {
15
- validationSchemaStorage.register(
16
- "UpdateDefaultProjectClassificationBean",
17
- z
18
- .object({
19
- id: z.string(),
20
- })
21
- .strict()
22
- .describe("UpdateDefaultProjectClassificationBean"),
23
- );
24
- }