@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,348 +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 { validationSchemaStorage } from "../validation-schema-storage";
14
- /**
15
- * This resource represents [issue worklog](#api-group-Issue-worklogs) properties,
16
- * which provides for storing custom data against an issue worklog. Use it to get,
17
- * create, and delete issue worklog properties as well as obtain the keys of all
18
- * properties on a issue worklog. Issue worklog properties are a type of [entity
19
- * property](https://developer.atlassian.com/cloud/jira/platform/jira-entity-properties/).
20
- */
21
- export class IssueWorklogPropertiesService extends CommonHttpService {
22
- /**
23
- * Deletes a worklog property.
24
- *
25
- * This operation can be accessed anonymously.
26
- *
27
- * **[Permissions](#permissions) required:**
28
- *
29
- * * *Browse projects* [project
30
- * permission](https://confluence.atlassian.com/x/yodKLg) for the project that the
31
- * issue is in.
32
- * * If [issue-level security](https://confluence.atlassian.com/x/J4lKLg) is
33
- * configured, issue-level security permission to view the issue.
34
- * * If the worklog has visibility restrictions, belongs to the group or has the
35
- * role visibility is restricted to.
36
- *
37
- * @path {DELETE}
38
- * /rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}
39
- * @scopes-current write:jira-work
40
- * @scopes-beta delete:issue-worklog.property:jira
41
- */
42
- deleteWorklogProperty({
43
- issueIdOrKey,
44
- worklogId,
45
- propertyKey,
46
- }: {
47
- /** The ID or key of the issue. */
48
- issueIdOrKey: string;
49
- /** The ID of the worklog. */
50
- worklogId: string;
51
- /** The key of the property. */
52
- propertyKey: string;
53
- }): Promise<void> {
54
- return this.getClientInstance()
55
- .request({
56
- path: "/rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}",
57
- method: "DELETE",
58
- pathParams: {
59
- issueIdOrKey,
60
- worklogId,
61
- propertyKey,
62
- },
63
- })
64
- .then(commonHttpClient.discardResult);
65
- }
66
- /**
67
- * Returns the value of a worklog property.
68
- *
69
- * This operation can be accessed anonymously.
70
- *
71
- * **[Permissions](#permissions) required:**
72
- *
73
- * * *Browse projects* [project
74
- * permission](https://confluence.atlassian.com/x/yodKLg) for the project that the
75
- * issue is in.
76
- * * If [issue-level security](https://confluence.atlassian.com/x/J4lKLg) is
77
- * configured, issue-level security permission to view the issue.
78
- * * If the worklog has visibility restrictions, belongs to the group or has the
79
- * role visibility is restricted to.
80
- *
81
- * @returns Returned if the request is successful.
82
- *
83
- * example: {
84
- * "key": "issue.support",
85
- * "value": {
86
- * "system.conversation.id": "b1bf38be-5e94-4b40-a3b8-9278735ee1e6",
87
- * "system.support.time": "1m"
88
- * }
89
- * }
90
- * @path {GET}
91
- * /rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}
92
- * @scopes-current read:jira-work
93
- * @scopes-beta read:issue-worklog.property:jira
94
- */
95
- getWorklogProperty({
96
- issueIdOrKey,
97
- worklogId,
98
- propertyKey,
99
- }: {
100
- /** The ID or key of the issue. */
101
- issueIdOrKey: string;
102
- /** The ID of the worklog. */
103
- worklogId: string;
104
- /** The key of the property. */
105
- propertyKey: string;
106
- }): Promise<EntityProperty> {
107
- return this.getClientInstance()
108
- .request({
109
- path: "/rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}",
110
- method: "GET",
111
- pathParams: {
112
- issueIdOrKey,
113
- worklogId,
114
- propertyKey,
115
- },
116
- })
117
- .then(
118
- this.getClientInstance().responseHandler({
119
- 200: {
120
- "application/json": "json",
121
- },
122
- }),
123
- )
124
- .then(
125
- commonHttpClient.castResponse<{
126
- status: 200;
127
- mediaType: "application/json";
128
- body: EntityProperty;
129
- }>(),
130
- )
131
- .then(
132
- validationSchemaStorage.validator(
133
- "IssueWorklogPropertiesService.getWorklogProperty.response",
134
- ),
135
- )
136
- .then(commonHttpClient.getBody);
137
- }
138
- /**
139
- * Returns the keys of all properties for a worklog.
140
- *
141
- * This operation can be accessed anonymously.
142
- *
143
- * **[Permissions](#permissions) required:**
144
- *
145
- * * *Browse projects* [project
146
- * permission](https://confluence.atlassian.com/x/yodKLg) for the project that the
147
- * issue is in.
148
- * * If [issue-level security](https://confluence.atlassian.com/x/J4lKLg) is
149
- * configured, issue-level security permission to view the issue.
150
- * * If the worklog has visibility restrictions, belongs to the group or has the
151
- * role visibility is restricted to.
152
- *
153
- * @returns Returned if the request is successful.
154
- *
155
- * example: {
156
- * "keys": [
157
- * {
158
- * "key": "issue.support",
159
- * "self":
160
- * "https://your-domain.atlassian.net/rest/api/3/issue/EX-2/properties/issue.support"
161
- * }
162
- * ]
163
- * }
164
- * @path {GET} /rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties
165
- * @scopes-current read:jira-work
166
- * @scopes-beta read:issue-worklog.property:jira
167
- */
168
- getWorklogPropertyKeys({
169
- issueIdOrKey,
170
- worklogId,
171
- }: {
172
- /** The ID or key of the issue. */
173
- issueIdOrKey: string;
174
- /** The ID of the worklog. */
175
- worklogId: string;
176
- }): Promise<PropertyKeys> {
177
- return this.getClientInstance()
178
- .request({
179
- path: "/rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties",
180
- method: "GET",
181
- pathParams: {
182
- issueIdOrKey,
183
- worklogId,
184
- },
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: PropertyKeys;
198
- }>(),
199
- )
200
- .then(
201
- validationSchemaStorage.validator(
202
- "IssueWorklogPropertiesService.getWorklogPropertyKeys.response",
203
- ),
204
- )
205
- .then(commonHttpClient.getBody);
206
- }
207
- /**
208
- * Sets the value of a worklog property. Use this operation to store custom data
209
- * against the worklog.
210
- *
211
- * The value of the request body must be a
212
- * [valid](http://tools.ietf.org/html/rfc4627), non-empty JSON blob. The maximum
213
- * length is 32768 characters.
214
- *
215
- * This operation can be accessed anonymously.
216
- *
217
- * **[Permissions](#permissions) required:**
218
- *
219
- * * *Browse projects* [project
220
- * permission](https://confluence.atlassian.com/x/yodKLg) for the project that the
221
- * issue is in.
222
- * * If [issue-level security](https://confluence.atlassian.com/x/J4lKLg) is
223
- * configured, issue-level security permission to view the issue.
224
- * * *Edit all worklogs*[ project
225
- * permission](https://confluence.atlassian.com/x/yodKLg) to update any worklog or
226
- * *Edit own worklogs* to update worklogs created by the user.
227
- * * If the worklog has visibility restrictions, belongs to the group or has the
228
- * role visibility is restricted to.
229
- *
230
- * @returns * status: 200, mediaType: application/json
231
- *
232
- * Returned if the worklog property is updated.
233
- *
234
- * * status: 201, mediaType: application/json
235
- *
236
- * Returned if the worklog property is created.
237
- * @path {PUT}
238
- * /rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}
239
- * @scopes-current write:jira-work
240
- * @scopes-beta write:issue-worklog.property:jira
241
- */
242
- setWorklogProperty({
243
- issueIdOrKey,
244
- worklogId,
245
- propertyKey,
246
- requestBody,
247
- }: {
248
- /** The ID or key of the issue. */
249
- issueIdOrKey: string;
250
- /** The ID of the worklog. */
251
- worklogId: string;
252
- /** The key of the issue property. The maximum length is 255 characters. */
253
- propertyKey: string;
254
- /**
255
- * The value of the property. The value has to be a valid, non-empty
256
- * [JSON](https://tools.ietf.org/html/rfc4627) value. The maximum length of the
257
- * property value is 32768 bytes.
258
- */
259
- requestBody: unknown;
260
- }): Promise<{
261
- created: boolean;
262
- body: unknown;
263
- }> {
264
- return this.getClientInstance()
265
- .request({
266
- path: "/rest/api/3/issue/{issueIdOrKey}/worklog/{worklogId}/properties/{propertyKey}",
267
- method: "PUT",
268
- pathParams: {
269
- issueIdOrKey,
270
- worklogId,
271
- propertyKey,
272
- },
273
- headers: {
274
- "Content-Type": "application/json",
275
- },
276
- body: requestBody,
277
- })
278
- .then(
279
- this.getClientInstance().responseHandler({
280
- 200: {
281
- "application/json": "json",
282
- },
283
- 201: {
284
- "application/json": "json",
285
- },
286
- }),
287
- )
288
- .then(
289
- commonHttpClient.castResponse<{
290
- status: 200 | 201;
291
- mediaType: "application/json";
292
- body: unknown;
293
- }>(),
294
- )
295
- .then(
296
- validationSchemaStorage.validator(
297
- "IssueWorklogPropertiesService.setWorklogProperty.response",
298
- ),
299
- )
300
- .then(commonHttpClient.asCreatedResponse("body"));
301
- }
302
- static initialize() {
303
- validationSchemaStorage.registerExtensible(
304
- "IssueWorklogPropertiesService.getWorklogPropertyKeys.response",
305
- z
306
- .object({
307
- status: z.literal(200),
308
- mediaType: z.literal("application/json"),
309
- body: validationSchemaStorage.lazy("PropertyKeys"),
310
- })
311
- .describe(
312
- "IssueWorklogPropertiesService.getWorklogPropertyKeys.response",
313
- ),
314
- );
315
- validationSchemaStorage.registerExtensible(
316
- "IssueWorklogPropertiesService.getWorklogProperty.response",
317
- z
318
- .object({
319
- status: z.literal(200),
320
- mediaType: z.literal("application/json"),
321
- body: validationSchemaStorage.lazy("EntityProperty"),
322
- })
323
- .describe("IssueWorklogPropertiesService.getWorklogProperty.response"),
324
- );
325
- validationSchemaStorage.registerExtensible(
326
- "IssueWorklogPropertiesService.setWorklogProperty.response",
327
- z
328
- .object({
329
- status: z.number(),
330
- mediaType: z.string(),
331
- body: z.unknown(),
332
- })
333
- .superRefine(({ status: status, body: body }, ctx) => {
334
- if (status === 200 || status === 201) {
335
- z.unknown().parse(body);
336
- } else {
337
- ctx.addIssue({
338
- code: z.ZodIssueCode.custom,
339
- path: ["status"],
340
- message: `Unexpected status code: ${status}`,
341
- });
342
- }
343
- })
344
- .describe("IssueWorklogPropertiesService.setWorklogProperty.response"),
345
- );
346
- validationSchemaStorage.registerOnce([registerCommonValidationSchemas]);
347
- }
348
- }