@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,121 +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
- /**
8
- * A [Connect
9
- * module](https://developer.atlassian.com/cloud/jira/platform/about-jira-modules/)
10
- * in the same format as in the
11
- * [app
12
- * descriptor](https://developer.atlassian.com/cloud/jira/platform/app-descriptor/).
13
- *
14
- * @example {
15
- * "description": {
16
- * "value": "field with team"
17
- * },
18
- * "type": "single_select",
19
- * "extractions": [
20
- * {
21
- * "path": "category",
22
- * "type": "text",
23
- * "name": "categoryName"
24
- * }
25
- * ],
26
- * "name": {
27
- * "value": "Team"
28
- * },
29
- * "key": "team-field"
30
- * }
31
- */
32
- export interface ConnectModule {
33
- [key: string]: unknown;
34
- }
35
- /**
36
- * @example {
37
- * "jiraEntityProperties": [
38
- * {
39
- * "keyConfigurations": [
40
- * {
41
- * "extractions": [
42
- * {
43
- * "objectName": "extension",
44
- * "type": "text",
45
- * "alias": "attachmentExtension"
46
- * }
47
- * ],
48
- * "propertyKey": "attachment"
49
- * }
50
- * ],
51
- * "entityType": "issue",
52
- * "name": {
53
- * "value": "Attachment Index Document"
54
- * },
55
- * "key": "dynamic-attachment-entity-property"
56
- * }
57
- * ],
58
- * "jiraIssueFields": [
59
- * {
60
- * "description": {
61
- * "value": "A dynamically added single-select field"
62
- * },
63
- * "type": "single_select",
64
- * "extractions": [
65
- * {
66
- * "path": "category",
67
- * "type": "text",
68
- * "name": "categoryName"
69
- * }
70
- * ],
71
- * "name": {
72
- * "value": "Dynamic single select"
73
- * },
74
- * "key": "dynamic-select-field"
75
- * }
76
- * ]
77
- * }
78
- */
79
- export interface ConnectModules extends Record<string, unknown> {
80
- /**
81
- * A list of app modules in the same format as the `modules` property in the
82
- * [app
83
- * descriptor](https://developer.atlassian.com/cloud/jira/platform/app-descriptor/).
84
- */
85
- modules: ConnectModule[];
86
- }
87
- /**
88
- * @example {
89
- * "message": "The request is not from a Connect app."
90
- * }
91
- */
92
- export interface ErrorMessage {
93
- /** The error message. */
94
- message: string;
95
- }
96
- export function registerDynamicModulesValidationSchemas(
97
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
98
- ) {
99
- validationSchemaStorage.register(
100
- "ConnectModule",
101
- z.object({}).catchall(z.unknown()).describe("ConnectModule"),
102
- );
103
- validationSchemaStorage.register(
104
- "ConnectModules",
105
- z
106
- .object({
107
- modules: z.array(validationSchemaStorage.lazy("ConnectModule")),
108
- })
109
- .catchall(z.unknown())
110
- .describe("ConnectModules"),
111
- );
112
- validationSchemaStorage.register(
113
- "ErrorMessage",
114
- z
115
- .object({
116
- message: z.string(),
117
- })
118
- .strict()
119
- .describe("ErrorMessage"),
120
- );
121
- }
@@ -1,103 +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
- /** Details of the scope of the default sharing for new filters and dashboards. */
8
- export interface DefaultShareScope {
9
- /**
10
- * The scope of the default sharing for new filters and dashboards:
11
- *
12
- * * `AUTHENTICATED` Shared with all logged-in users.
13
- * * `GLOBAL` Shared with all logged-in users. This shows as `AUTHENTICATED` in
14
- * the response.
15
- * * `PRIVATE` Not shared with any users.
16
- */
17
- scope: "GLOBAL" | "AUTHENTICATED" | "PRIVATE";
18
- }
19
- export interface SharePermissionInputBean {
20
- /**
21
- * The user account ID that the filter is shared with. For a request, specify the
22
- * `accountId` property for the user.
23
- */
24
- accountId?: string;
25
- /**
26
- * The ID of the group, which uniquely identifies the group across all Atlassian
27
- * products.For example, *952d12c3-5b5b-4d04-bb32-44d383afc4b2*. Cannot be
28
- * provided with `groupname`.
29
- */
30
- groupId?: string;
31
- /**
32
- * The name of the group to share the filter with. Set `type` to `group`. Please
33
- * note that the name of a group is mutable, to reliably identify a group use
34
- * `groupId`.
35
- */
36
- groupname?: string;
37
- /** The ID of the project to share the filter with. Set `type` to `project`. */
38
- projectId?: string;
39
- /**
40
- * The ID of the project role to share the filter with. Set `type` to
41
- * `projectRole` and the `projectId` for the project that the role is in.
42
- */
43
- projectRoleId?: string;
44
- /** The rights for the share permission. */
45
- rights?: number;
46
- /**
47
- * The type of the share permission.Specify the type as follows:
48
- *
49
- * * `user` Share with a user.
50
- * * `group` Share with a group. Specify `groupname` as well.
51
- * * `project` Share with a project. Specify `projectId` as well.
52
- * * `projectRole` Share with a project role in a project. Specify `projectId`
53
- * and `projectRoleId` as well.
54
- * * `global` Share globally, including anonymous users. If set, this type
55
- * overrides all existing share permissions and must be deleted before any
56
- * non-global share permissions is set.
57
- * * `authenticated` Share with all logged-in users. This shows as `loggedin` in
58
- * the response. If set, this type overrides all existing share permissions and
59
- * must be deleted before any non-global share permissions is set.
60
- */
61
- type:
62
- | "user"
63
- | "project"
64
- | "group"
65
- | "projectRole"
66
- | "global"
67
- | "authenticated";
68
- }
69
- export function registerFilterSharingValidationSchemas(
70
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
71
- ) {
72
- validationSchemaStorage.register(
73
- "DefaultShareScope",
74
- z
75
- .object({
76
- scope: z.enum(["GLOBAL", "AUTHENTICATED", "PRIVATE"]),
77
- })
78
- .strict()
79
- .describe("DefaultShareScope"),
80
- );
81
- validationSchemaStorage.register(
82
- "SharePermissionInputBean",
83
- z
84
- .object({
85
- accountId: z.string().optional(),
86
- groupId: z.string().optional(),
87
- groupname: z.string().optional(),
88
- projectId: z.string().optional(),
89
- projectRoleId: z.string().optional(),
90
- rights: z.number().int().optional(),
91
- type: z.enum([
92
- "user",
93
- "project",
94
- "group",
95
- "projectRole",
96
- "global",
97
- "authenticated",
98
- ]),
99
- })
100
- .strict()
101
- .describe("SharePermissionInputBean"),
102
- );
103
- }
@@ -1,319 +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 GroupName,
9
- registerCommonValidationSchemas,
10
- type SharePermission,
11
- type User,
12
- } from "./common";
13
- /** The account ID of the new owner. */
14
- export interface ChangeFilterOwner {
15
- /** The account ID of the new owner. */
16
- accountId: string;
17
- }
18
- /** Details about a filter. */
19
- export interface Filter {
20
- /**
21
- * \[Experimental\] Approximate last used time. Returns the date and time when the
22
- * filter was last used. Returns `null` if the filter hasn't been used after
23
- * tracking was enabled. For performance reasons, timestamps aren't updated in
24
- * real time and therefore may not be exactly accurate.
25
- */
26
- approximateLastUsed?: string;
27
- /** A description of the filter. */
28
- description?: string;
29
- /** The groups and projects that can edit the filter. */
30
- editPermissions?: SharePermission[];
31
- /** Whether the filter is selected as a favorite. */
32
- favourite?: boolean;
33
- /**
34
- * The count of how many users have selected this filter as a favorite, including
35
- * the filter owner.
36
- */
37
- favouritedCount?: number;
38
- /** The unique identifier for the filter. */
39
- id?: string;
40
- /** The JQL query for the filter. For example, *project = SSP AND issuetype = Bug*. */
41
- jql?: string;
42
- /** The name of the filter. Must be unique. */
43
- name: string;
44
- /**
45
- * The user who owns the filter. This is defaulted to the creator of the filter,
46
- * however Jira administrators can change the owner of a shared filter in the
47
- * admin settings.
48
- */
49
- owner?: User;
50
- /**
51
- * A URL to view the filter results in Jira, using the [Search for issues using
52
- * JQL](#api-rest-api-3-filter-search-get) operation with the filter's JQL string
53
- * to return the filter results. For example,
54
- * *https://your-domain.atlassian.net/rest/api/3/search?jql=project+%3D+SSP+AND+issuetype+%3D+Bug*.
55
- */
56
- searchUrl?: string;
57
- /** The URL of the filter. */
58
- self?: string;
59
- /** The groups and projects that the filter is shared with. */
60
- sharePermissions?: SharePermission[];
61
- /**
62
- * A paginated list of the users that the filter is shared with. This includes
63
- * users that are members of the groups or can browse the projects that the filter
64
- * is shared with.
65
- */
66
- sharedUsers?: UserList;
67
- /** A paginated list of the users that are subscribed to the filter. */
68
- subscriptions?: FilterSubscriptionsList;
69
- /**
70
- * A URL to view the filter results in Jira, using the ID of the filter. For
71
- * example, *https://your-domain.atlassian.net/issues/?filter=10100*.
72
- */
73
- viewUrl?: string;
74
- }
75
- /** Details of a filter. */
76
- export interface FilterDetails {
77
- /**
78
- * \[Experimental\] Approximate last used time. Returns the date and time when the
79
- * filter was last used. Returns `null` if the filter hasn't been used after
80
- * tracking was enabled. For performance reasons, timestamps aren't updated in
81
- * real time and therefore may not be exactly accurate.
82
- */
83
- approximateLastUsed?: string;
84
- /** The description of the filter. */
85
- description?: string;
86
- /**
87
- * The groups and projects that can edit the filter. This can be specified when
88
- * updating a filter, but not when creating a filter.
89
- */
90
- editPermissions?: SharePermission[];
91
- /** Expand options that include additional filter details in the response. */
92
- expand?: string;
93
- /**
94
- * Whether the filter is selected as a favorite by any users, not including the
95
- * filter owner.
96
- */
97
- favourite?: boolean;
98
- /**
99
- * The count of how many users have selected this filter as a favorite, including
100
- * the filter owner.
101
- */
102
- favouritedCount?: number;
103
- /** The unique identifier for the filter. */
104
- id?: string;
105
- /** The JQL query for the filter. For example, *project = SSP AND issuetype = Bug*. */
106
- jql?: string;
107
- /** The name of the filter. */
108
- name: string;
109
- /**
110
- * The user who owns the filter. Defaults to the creator of the filter, however,
111
- * Jira administrators can change the owner of a shared filter in the admin
112
- * settings.
113
- */
114
- owner?: User;
115
- /**
116
- * A URL to view the filter results in Jira, using the [Search for issues using
117
- * JQL](#api-rest-api-3-filter-search-get) operation with the filter's JQL string
118
- * to return the filter results. For example,
119
- * *https://your-domain.atlassian.net/rest/api/3/search?jql=project+%3D+SSP+AND+issuetype+%3D+Bug*.
120
- */
121
- searchUrl?: string;
122
- /** The URL of the filter. */
123
- self?: string;
124
- /**
125
- * The groups and projects that the filter is shared with. This can be specified
126
- * when updating a filter, but not when creating a filter.
127
- */
128
- sharePermissions?: SharePermission[];
129
- /** The users that are subscribed to the filter. */
130
- subscriptions?: FilterSubscription[];
131
- /**
132
- * A URL to view the filter results in Jira, using the ID of the filter. For
133
- * example, *https://your-domain.atlassian.net/issues/?filter=10100*.
134
- */
135
- viewUrl?: string;
136
- }
137
- /** Details of a user or group subscribing to a filter. */
138
- export interface FilterSubscription {
139
- /** The group subscribing to filter. */
140
- group?: GroupName;
141
- /** The ID of the filter subscription. */
142
- id?: number;
143
- /** The user subscribing to filter. */
144
- user?: User;
145
- }
146
- /** A paginated list of subscriptions to a filter. */
147
- export interface FilterSubscriptionsList {
148
- /** The index of the last item returned on the page. */
149
- "end-index"?: number;
150
- /** The list of items. */
151
- items?: FilterSubscription[];
152
- /** The maximum number of results that could be on the page. */
153
- "max-results"?: number;
154
- /** The number of items on the page. */
155
- size?: number;
156
- /** The index of the first item returned on the page. */
157
- "start-index"?: number;
158
- }
159
- /** A page of items. */
160
- export interface PageBeanFilterDetails {
161
- /** Whether this is the last page. */
162
- isLast?: boolean;
163
- /** The maximum number of items that could be returned. */
164
- maxResults?: number;
165
- /** If there is another page of results, the URL of the next page. */
166
- nextPage?: string;
167
- /** The URL of the page. */
168
- self?: string;
169
- /** The index of the first item returned. */
170
- startAt?: number;
171
- /** The number of items returned. */
172
- total?: number;
173
- /** The list of items. */
174
- values?: FilterDetails[];
175
- }
176
- /**
177
- * A paginated list of users sharing the filter. This includes users that are
178
- * members of the groups or can browse the projects that the filter is shared with.
179
- */
180
- export interface UserList {
181
- /** The index of the last item returned on the page. */
182
- "end-index"?: number;
183
- /** The list of items. */
184
- items?: User[];
185
- /** The maximum number of results that could be on the page. */
186
- "max-results"?: number;
187
- /** The number of items on the page. */
188
- size?: number;
189
- /** The index of the first item returned on the page. */
190
- "start-index"?: number;
191
- }
192
- export function registerFiltersValidationSchemas(
193
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
194
- ) {
195
- validationSchemaStorage.register(
196
- "ChangeFilterOwner",
197
- z
198
- .object({
199
- accountId: z.string(),
200
- })
201
- .strict()
202
- .describe("ChangeFilterOwner"),
203
- );
204
- validationSchemaStorage.register(
205
- "Filter",
206
- z
207
- .object({
208
- approximateLastUsed: z.string().optional(),
209
- description: z.string().optional(),
210
- editPermissions: z
211
- .array(validationSchemaStorage.lazy("SharePermission"))
212
- .optional(),
213
- favourite: z.boolean().optional(),
214
- favouritedCount: z.number().int().optional(),
215
- id: z.string().optional(),
216
- jql: z.string().optional(),
217
- name: z.string(),
218
- owner: validationSchemaStorage.lazy("User").optional(),
219
- searchUrl: z.string().optional(),
220
- self: z.string().optional(),
221
- sharePermissions: z
222
- .array(validationSchemaStorage.lazy("SharePermission"))
223
- .optional(),
224
- sharedUsers: validationSchemaStorage.lazy("UserList").optional(),
225
- subscriptions: validationSchemaStorage
226
- .lazy("FilterSubscriptionsList")
227
- .optional(),
228
- viewUrl: z.string().optional(),
229
- })
230
- .strict()
231
- .describe("Filter"),
232
- );
233
- validationSchemaStorage.register(
234
- "FilterDetails",
235
- z
236
- .object({
237
- approximateLastUsed: z.string().optional(),
238
- description: z.string().optional(),
239
- editPermissions: z
240
- .array(validationSchemaStorage.lazy("SharePermission"))
241
- .optional(),
242
- expand: z.string().optional(),
243
- favourite: z.boolean().optional(),
244
- favouritedCount: z.number().int().optional(),
245
- id: z.string().optional(),
246
- jql: z.string().optional(),
247
- name: z.string(),
248
- owner: validationSchemaStorage.lazy("User").optional(),
249
- searchUrl: z.string().optional(),
250
- self: z.string().optional(),
251
- sharePermissions: z
252
- .array(validationSchemaStorage.lazy("SharePermission"))
253
- .optional(),
254
- subscriptions: z
255
- .array(validationSchemaStorage.lazy("FilterSubscription"))
256
- .optional(),
257
- viewUrl: z.string().optional(),
258
- })
259
- .strict()
260
- .describe("FilterDetails"),
261
- );
262
- validationSchemaStorage.register(
263
- "FilterSubscription",
264
- z
265
- .object({
266
- group: validationSchemaStorage.lazy("GroupName").optional(),
267
- id: z.number().int().optional(),
268
- user: validationSchemaStorage.lazy("User").optional(),
269
- })
270
- .strict()
271
- .describe("FilterSubscription"),
272
- );
273
- validationSchemaStorage.register(
274
- "FilterSubscriptionsList",
275
- z
276
- .object({
277
- "end-index": z.number().int().optional(),
278
- items: z
279
- .array(validationSchemaStorage.lazy("FilterSubscription"))
280
- .optional(),
281
- "max-results": z.number().int().optional(),
282
- size: z.number().int().optional(),
283
- "start-index": z.number().int().optional(),
284
- })
285
- .strict()
286
- .describe("FilterSubscriptionsList"),
287
- );
288
- validationSchemaStorage.register(
289
- "PageBeanFilterDetails",
290
- z
291
- .object({
292
- isLast: z.boolean().optional(),
293
- maxResults: z.number().int().optional(),
294
- nextPage: z.string().optional(),
295
- self: z.string().optional(),
296
- startAt: z.number().int().optional(),
297
- total: z.number().int().optional(),
298
- values: z
299
- .array(validationSchemaStorage.lazy("FilterDetails"))
300
- .optional(),
301
- })
302
- .strict()
303
- .describe("PageBeanFilterDetails"),
304
- );
305
- validationSchemaStorage.register(
306
- "UserList",
307
- z
308
- .object({
309
- "end-index": z.number().int().optional(),
310
- items: z.array(validationSchemaStorage.lazy("User")).optional(),
311
- "max-results": z.number().int().optional(),
312
- size: z.number().int().optional(),
313
- "start-index": z.number().int().optional(),
314
- })
315
- .strict()
316
- .describe("UserList"),
317
- );
318
- validationSchemaStorage.registerOnce([registerCommonValidationSchemas]);
319
- }
@@ -1,85 +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 FoundGroups,
9
- type FoundUsers,
10
- registerCommonValidationSchemas,
11
- } from "./common";
12
- /** List of users and groups found in a search. */
13
- export interface FoundUsersAndGroups {
14
- /**
15
- * The list of groups found in a search, including header text (Showing X of Y
16
- * matching groups) and total of matched groups.
17
- */
18
- groups?: FoundGroups;
19
- /**
20
- * The list of users found in a search, including header text (Showing X of Y
21
- * matching users) and total of matched users.
22
- */
23
- users?: FoundUsers;
24
- }
25
- /** A user found in a search. */
26
- export interface UserPickerUser {
27
- /**
28
- * The account ID of the user, which uniquely identifies the user across all
29
- * Atlassian products. For example, *5b10ac8d82e05b22cc7d4ef5*.
30
- */
31
- accountId?: string;
32
- /** The avatar URL of the user. */
33
- avatarUrl?: string;
34
- /**
35
- * The display name of the user. Depending on the user’s privacy setting, this may
36
- * be returned as null.
37
- */
38
- displayName?: string;
39
- /**
40
- * The display name, email address, and key of the user with the matched query
41
- * string highlighted with the HTML bold tag.
42
- */
43
- html?: string;
44
- /**
45
- * This property is no longer available. See the [deprecation
46
- * notice](https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/)
47
- * for details.
48
- */
49
- key?: string;
50
- /**
51
- * This property is no longer available . See the [deprecation
52
- * notice](https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/)
53
- * for details.
54
- */
55
- name?: string;
56
- }
57
- export function registerGroupAndUserPickerValidationSchemas(
58
- validationSchemaStorage: CommonValidationSchemaStorage<ZodTypeAny>,
59
- ) {
60
- validationSchemaStorage.register(
61
- "FoundUsersAndGroups",
62
- z
63
- .object({
64
- groups: validationSchemaStorage.lazy("FoundGroups").optional(),
65
- users: validationSchemaStorage.lazy("FoundUsers").optional(),
66
- })
67
- .strict()
68
- .describe("FoundUsersAndGroups"),
69
- );
70
- validationSchemaStorage.register(
71
- "UserPickerUser",
72
- z
73
- .object({
74
- accountId: z.string().optional(),
75
- avatarUrl: z.string().optional(),
76
- displayName: z.string().optional(),
77
- html: z.string().optional(),
78
- key: z.string().optional(),
79
- name: z.string().optional(),
80
- })
81
- .strict()
82
- .describe("UserPickerUser"),
83
- );
84
- validationSchemaStorage.registerOnce([registerCommonValidationSchemas]);
85
- }