@resolution/confluence-api-client 0.4.4 → 0.4.6
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.
- package/CHANGELOG.md +22 -0
- package/README.md +60 -1
- package/lib/openapi/v1/BaseConfluenceApiV1Client.d.ts +32 -33
- package/lib/openapi/v1/BaseConfluenceApiV1Client.js +151 -88
- package/lib/openapi/v1/BaseConfluenceApiV1Client.js.map +1 -1
- package/lib/openapi/v1/core/CommonHttpService.d.ts +2 -0
- package/lib/openapi/v1/core/CommonHttpService.js +9 -0
- package/lib/openapi/v1/core/CommonHttpService.js.map +1 -1
- package/lib/openapi/v1/services/AnalyticsService.d.ts +10 -10
- package/lib/openapi/v1/services/AnalyticsService.js +62 -59
- package/lib/openapi/v1/services/AnalyticsService.js.map +1 -1
- package/lib/openapi/v1/services/AuditService.d.ts +25 -25
- package/lib/openapi/v1/services/AuditService.js +205 -202
- package/lib/openapi/v1/services/AuditService.js.map +1 -1
- package/lib/openapi/v1/services/ContentAttachmentsService.d.ts +20 -20
- package/lib/openapi/v1/services/ContentAttachmentsService.js +317 -314
- package/lib/openapi/v1/services/ContentAttachmentsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentBodyService.d.ts +15 -15
- package/lib/openapi/v1/services/ContentBodyService.js +140 -137
- package/lib/openapi/v1/services/ContentBodyService.js.map +1 -1
- package/lib/openapi/v1/services/ContentChildrenAndDescendantsService.d.ts +27 -27
- package/lib/openapi/v1/services/ContentChildrenAndDescendantsService.js +391 -388
- package/lib/openapi/v1/services/ContentChildrenAndDescendantsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentCommentsService.d.ts +8 -8
- package/lib/openapi/v1/services/ContentCommentsService.js +49 -46
- package/lib/openapi/v1/services/ContentCommentsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentLabelsService.d.ts +11 -11
- package/lib/openapi/v1/services/ContentLabelsService.js +150 -147
- package/lib/openapi/v1/services/ContentLabelsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentMacroBodyService.d.ts +13 -13
- package/lib/openapi/v1/services/ContentMacroBodyService.js +155 -152
- package/lib/openapi/v1/services/ContentMacroBodyService.js.map +1 -1
- package/lib/openapi/v1/services/ContentPermissionsService.d.ts +2 -2
- package/lib/openapi/v1/services/ContentPermissionsService.js +48 -45
- package/lib/openapi/v1/services/ContentPermissionsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentPropertiesService.d.ts +18 -18
- package/lib/openapi/v1/services/ContentPropertiesService.js +237 -234
- package/lib/openapi/v1/services/ContentPropertiesService.js.map +1 -1
- package/lib/openapi/v1/services/ContentRestrictionsService.d.ts +49 -49
- package/lib/openapi/v1/services/ContentRestrictionsService.js +505 -502
- package/lib/openapi/v1/services/ContentRestrictionsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentService.d.ts +50 -50
- package/lib/openapi/v1/services/ContentService.js +475 -472
- package/lib/openapi/v1/services/ContentService.js.map +1 -1
- package/lib/openapi/v1/services/ContentStatesService.d.ts +25 -25
- package/lib/openapi/v1/services/ContentStatesService.js +359 -356
- package/lib/openapi/v1/services/ContentStatesService.js.map +1 -1
- package/lib/openapi/v1/services/ContentVersionsService.d.ts +13 -13
- package/lib/openapi/v1/services/ContentVersionsService.js +144 -141
- package/lib/openapi/v1/services/ContentVersionsService.js.map +1 -1
- package/lib/openapi/v1/services/ContentWatchesService.d.ts +57 -57
- package/lib/openapi/v1/services/ContentWatchesService.js +454 -451
- package/lib/openapi/v1/services/ContentWatchesService.js.map +1 -1
- package/lib/openapi/v1/services/DynamicModulesService.d.ts +5 -5
- package/lib/openapi/v1/services/DynamicModulesService.js +70 -67
- package/lib/openapi/v1/services/DynamicModulesService.js.map +1 -1
- package/lib/openapi/v1/services/ExperimentalService.d.ts +12 -12
- package/lib/openapi/v1/services/ExperimentalService.js +151 -148
- package/lib/openapi/v1/services/ExperimentalService.js.map +1 -1
- package/lib/openapi/v1/services/GroupService.d.ts +52 -52
- package/lib/openapi/v1/services/GroupService.js +445 -442
- package/lib/openapi/v1/services/GroupService.js.map +1 -1
- package/lib/openapi/v1/services/InlineTasksService.d.ts +20 -20
- package/lib/openapi/v1/services/InlineTasksService.js +118 -115
- package/lib/openapi/v1/services/InlineTasksService.js.map +1 -1
- package/lib/openapi/v1/services/LabelInfoService.d.ts +5 -5
- package/lib/openapi/v1/services/LabelInfoService.js +37 -34
- package/lib/openapi/v1/services/LabelInfoService.js.map +1 -1
- package/lib/openapi/v1/services/LongRunningTaskService.d.ts +8 -6
- package/lib/openapi/v1/services/LongRunningTaskService.js +67 -63
- package/lib/openapi/v1/services/LongRunningTaskService.js.map +1 -1
- package/lib/openapi/v1/services/RelationService.d.ts +37 -37
- package/lib/openapi/v1/services/RelationService.js +231 -228
- package/lib/openapi/v1/services/RelationService.js.map +1 -1
- package/lib/openapi/v1/services/SearchService.d.ts +20 -20
- package/lib/openapi/v1/services/SearchService.js +136 -133
- package/lib/openapi/v1/services/SearchService.js.map +1 -1
- package/lib/openapi/v1/services/SettingsService.d.ts +15 -15
- package/lib/openapi/v1/services/SettingsService.js +204 -201
- package/lib/openapi/v1/services/SettingsService.js.map +1 -1
- package/lib/openapi/v1/services/SpacePermissionsService.d.ts +6 -6
- package/lib/openapi/v1/services/SpacePermissionsService.js +99 -96
- package/lib/openapi/v1/services/SpacePermissionsService.js.map +1 -1
- package/lib/openapi/v1/services/SpacePropertiesService.d.ts +16 -16
- package/lib/openapi/v1/services/SpacePropertiesService.js +227 -224
- package/lib/openapi/v1/services/SpacePropertiesService.js.map +1 -1
- package/lib/openapi/v1/services/SpaceService.d.ts +38 -38
- package/lib/openapi/v1/services/SpaceService.js +320 -317
- package/lib/openapi/v1/services/SpaceService.js.map +1 -1
- package/lib/openapi/v1/services/SpaceSettingsService.d.ts +4 -4
- package/lib/openapi/v1/services/SpaceSettingsService.js +68 -65
- package/lib/openapi/v1/services/SpaceSettingsService.js.map +1 -1
- package/lib/openapi/v1/services/TemplateService.d.ts +20 -20
- package/lib/openapi/v1/services/TemplateService.js +214 -211
- package/lib/openapi/v1/services/TemplateService.js.map +1 -1
- package/lib/openapi/v1/services/ThemesService.d.ts +13 -13
- package/lib/openapi/v1/services/ThemesService.js +179 -176
- package/lib/openapi/v1/services/ThemesService.js.map +1 -1
- package/lib/openapi/v1/services/UserPropertiesService.d.ts +12 -12
- package/lib/openapi/v1/services/UserPropertiesService.js +165 -162
- package/lib/openapi/v1/services/UserPropertiesService.js.map +1 -1
- package/lib/openapi/v1/services/UsersService.d.ts +21 -21
- package/lib/openapi/v1/services/UsersService.js +229 -226
- package/lib/openapi/v1/services/UsersService.js.map +1 -1
- package/lib/openapi/v2/BaseConfluenceApiV2Client.d.ts +23 -24
- package/lib/openapi/v2/BaseConfluenceApiV2Client.js +92 -47
- package/lib/openapi/v2/BaseConfluenceApiV2Client.js.map +1 -1
- package/lib/openapi/v2/core/CommonHttpService.d.ts +2 -0
- package/lib/openapi/v2/core/CommonHttpService.js +9 -0
- package/lib/openapi/v2/core/CommonHttpService.js.map +1 -1
- package/lib/openapi/v2/models/user.d.ts +0 -2
- package/lib/openapi/v2/models/user.js +0 -2
- package/lib/openapi/v2/models/user.js.map +1 -1
- package/lib/openapi/v2/services/AncestorsService.d.ts +17 -17
- package/lib/openapi/v2/services/AncestorsService.js +174 -171
- package/lib/openapi/v2/services/AncestorsService.js.map +1 -1
- package/lib/openapi/v2/services/AttachmentService.d.ts +62 -62
- package/lib/openapi/v2/services/AttachmentService.js +261 -258
- package/lib/openapi/v2/services/AttachmentService.js.map +1 -1
- package/lib/openapi/v2/services/BlogPostService.d.ts +70 -70
- package/lib/openapi/v2/services/BlogPostService.js +270 -267
- package/lib/openapi/v2/services/BlogPostService.js.map +1 -1
- package/lib/openapi/v2/services/ChildrenService.d.ts +14 -14
- package/lib/openapi/v2/services/ChildrenService.js +77 -74
- package/lib/openapi/v2/services/ChildrenService.js.map +1 -1
- package/lib/openapi/v2/services/ClassificationLevelService.d.ts +21 -21
- package/lib/openapi/v2/services/ClassificationLevelService.js +304 -301
- package/lib/openapi/v2/services/ClassificationLevelService.js.map +1 -1
- package/lib/openapi/v2/services/CommentService.d.ts +136 -136
- package/lib/openapi/v2/services/CommentService.js +635 -632
- package/lib/openapi/v2/services/CommentService.js.map +1 -1
- package/lib/openapi/v2/services/ContentPropertiesService.d.ts +128 -128
- package/lib/openapi/v2/services/ContentPropertiesService.js +1242 -1239
- package/lib/openapi/v2/services/ContentPropertiesService.js.map +1 -1
- package/lib/openapi/v2/services/ContentService.d.ts +2 -2
- package/lib/openapi/v2/services/ContentService.js +40 -37
- package/lib/openapi/v2/services/ContentService.js.map +1 -1
- package/lib/openapi/v2/services/CustomContentService.d.ts +72 -72
- package/lib/openapi/v2/services/CustomContentService.js +299 -296
- package/lib/openapi/v2/services/CustomContentService.js.map +1 -1
- package/lib/openapi/v2/services/DataPoliciesService.d.ts +10 -10
- package/lib/openapi/v2/services/DataPoliciesService.js +67 -64
- package/lib/openapi/v2/services/DataPoliciesService.js.map +1 -1
- package/lib/openapi/v2/services/DatabaseService.d.ts +17 -17
- package/lib/openapi/v2/services/DatabaseService.js +90 -87
- package/lib/openapi/v2/services/DatabaseService.js.map +1 -1
- package/lib/openapi/v2/services/LabelService.d.ts +57 -57
- package/lib/openapi/v2/services/LabelService.js +263 -260
- package/lib/openapi/v2/services/LabelService.js.map +1 -1
- package/lib/openapi/v2/services/LikeService.d.ts +36 -36
- package/lib/openapi/v2/services/LikeService.js +250 -247
- package/lib/openapi/v2/services/LikeService.js.map +1 -1
- package/lib/openapi/v2/services/OperationService.d.ts +20 -20
- package/lib/openapi/v2/services/OperationService.js +298 -295
- package/lib/openapi/v2/services/OperationService.js.map +1 -1
- package/lib/openapi/v2/services/PageService.d.ts +73 -73
- package/lib/openapi/v2/services/PageService.js +272 -269
- package/lib/openapi/v2/services/PageService.js.map +1 -1
- package/lib/openapi/v2/services/SmartLinkService.d.ts +19 -17
- package/lib/openapi/v2/services/SmartLinkService.js +92 -89
- package/lib/openapi/v2/services/SmartLinkService.js.map +1 -1
- package/lib/openapi/v2/services/SpacePermissionsService.d.ts +6 -6
- package/lib/openapi/v2/services/SpacePermissionsService.js +35 -32
- package/lib/openapi/v2/services/SpacePermissionsService.js.map +1 -1
- package/lib/openapi/v2/services/SpacePropertiesService.d.ts +15 -15
- package/lib/openapi/v2/services/SpacePropertiesService.js +165 -162
- package/lib/openapi/v2/services/SpacePropertiesService.js.map +1 -1
- package/lib/openapi/v2/services/SpaceService.d.ts +28 -28
- package/lib/openapi/v2/services/SpaceService.js +83 -80
- package/lib/openapi/v2/services/SpaceService.js.map +1 -1
- package/lib/openapi/v2/services/TaskService.d.ts +40 -40
- package/lib/openapi/v2/services/TaskService.js +120 -117
- package/lib/openapi/v2/services/TaskService.js.map +1 -1
- package/lib/openapi/v2/services/UserService.d.ts +11 -11
- package/lib/openapi/v2/services/UserService.js +91 -88
- package/lib/openapi/v2/services/UserService.js.map +1 -1
- package/lib/openapi/v2/services/VersionService.d.ts +59 -59
- package/lib/openapi/v2/services/VersionService.js +395 -392
- package/lib/openapi/v2/services/VersionService.js.map +1 -1
- package/lib/openapi/v2/services/WhiteboardService.d.ts +17 -17
- package/lib/openapi/v2/services/WhiteboardService.js +90 -87
- package/lib/openapi/v2/services/WhiteboardService.js.map +1 -1
- package/package.json +4 -3
|
@@ -11,168 +11,171 @@ const userProperties_1 = require("../models/userProperties");
|
|
|
11
11
|
const validationSchemaStorage_1 = require("../validationSchemaStorage");
|
|
12
12
|
/** @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties */
|
|
13
13
|
class UserPropertiesService extends CommonHttpService_1.CommonHttpService {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
14
|
+
constructor() {
|
|
15
|
+
super(...arguments);
|
|
16
|
+
/**
|
|
17
|
+
* Creates a property for a user. For more information about user properties, see
|
|
18
|
+
* [Confluence entity properties]
|
|
19
|
+
* (https://developer.atlassian.com/cloud/confluence/confluence-entity-properties/).
|
|
20
|
+
* `Note`, these properties stored against a user are on a Confluence site level
|
|
21
|
+
* and not space/content level.
|
|
22
|
+
*
|
|
23
|
+
* `Note:` the number of properties which could be created per app in a tenant for
|
|
24
|
+
* each user might be
|
|
25
|
+
* restricted by fixed system limits.
|
|
26
|
+
* **[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
|
|
27
|
+
* Permission to access the Confluence site ('Can use' global permission).
|
|
28
|
+
*
|
|
29
|
+
* @path {POST} /wiki/rest/api/user/{userId}/property/{key}
|
|
30
|
+
* @scopes-current write:user.property:confluence
|
|
31
|
+
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties#api-wiki-rest-api-user-userid-property-key-post
|
|
32
|
+
*/
|
|
33
|
+
this.createUserProperty = ({ userId, key, userPropertyCreate, }) => {
|
|
34
|
+
return this.getClientInstance()
|
|
35
|
+
.request({
|
|
36
|
+
path: "/wiki/rest/api/user/{userId}/property/{key}",
|
|
37
|
+
method: "POST",
|
|
38
|
+
pathParams: {
|
|
39
|
+
userId,
|
|
40
|
+
key,
|
|
41
|
+
},
|
|
42
|
+
headers: {
|
|
43
|
+
"Content-Type": "application/json",
|
|
44
|
+
},
|
|
45
|
+
body: userPropertyCreate,
|
|
46
|
+
})
|
|
47
|
+
.then(commonHttpClient.discardResult);
|
|
48
|
+
};
|
|
49
|
+
/**
|
|
50
|
+
* Deletes a property for the given user.
|
|
51
|
+
* For more information about user properties, see
|
|
52
|
+
* [Confluence entity
|
|
53
|
+
* properties](https://developer.atlassian.com/cloud/confluence/confluence-entity-properties/).
|
|
54
|
+
* `Note`, these properties stored against a user are on a Confluence site level
|
|
55
|
+
* and not space/content level.
|
|
56
|
+
*
|
|
57
|
+
* **[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
|
|
58
|
+
* Permission to access the Confluence site ('Can use' global permission).
|
|
59
|
+
*
|
|
60
|
+
* @path {DELETE} /wiki/rest/api/user/{userId}/property/{key}
|
|
61
|
+
* @scopes-current write:user.property:confluence
|
|
62
|
+
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties#api-wiki-rest-api-user-userid-property-key-delete
|
|
63
|
+
*/
|
|
64
|
+
this.deleteUserProperty = ({ userId, key, }) => {
|
|
65
|
+
return this.getClientInstance()
|
|
66
|
+
.request({
|
|
67
|
+
path: "/wiki/rest/api/user/{userId}/property/{key}",
|
|
68
|
+
method: "DELETE",
|
|
69
|
+
pathParams: {
|
|
70
|
+
userId,
|
|
71
|
+
key,
|
|
72
|
+
},
|
|
73
|
+
})
|
|
74
|
+
.then(commonHttpClient.discardResult);
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
* Returns the properties for a user as list of property keys. For more information
|
|
78
|
+
* about user properties, see [Confluence entity
|
|
79
|
+
* properties](https://developer.atlassian.com/cloud/confluence/confluence-entity-properties/).
|
|
80
|
+
* `Note`, these properties stored against a user are on a Confluence site level
|
|
81
|
+
* and not space/content level.
|
|
82
|
+
*
|
|
83
|
+
* **[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
|
|
84
|
+
* Permission to access the Confluence site ('Can use' global permission).
|
|
85
|
+
*
|
|
86
|
+
* @returns Returned if the requested properties are returned.
|
|
87
|
+
* @path {GET} /wiki/rest/api/user/{userId}/property
|
|
88
|
+
* @scopes-current read:user.property:confluence
|
|
89
|
+
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties#api-wiki-rest-api-user-userid-property-get
|
|
90
|
+
*/
|
|
91
|
+
this.getUserProperties = ({ userId, start, limit, }) => {
|
|
92
|
+
return this.getClientInstance()
|
|
93
|
+
.request({
|
|
94
|
+
path: "/wiki/rest/api/user/{userId}/property",
|
|
95
|
+
method: "GET",
|
|
96
|
+
pathParams: {
|
|
97
|
+
userId,
|
|
98
|
+
},
|
|
99
|
+
query: {
|
|
100
|
+
start,
|
|
101
|
+
limit,
|
|
102
|
+
},
|
|
103
|
+
})
|
|
104
|
+
.then(this.getClientInstance().responseHandler({
|
|
105
|
+
200: {
|
|
106
|
+
"application/json": "json",
|
|
107
|
+
},
|
|
108
|
+
}))
|
|
109
|
+
.then(commonHttpClient.castResponse())
|
|
110
|
+
.then(validationSchemaStorage_1.validationSchemaStorage.validator("UserPropertiesService.getUserProperties.response"))
|
|
111
|
+
.then(commonHttpClient.getBody);
|
|
112
|
+
};
|
|
113
|
+
/**
|
|
114
|
+
* Returns the property corresponding to `key` for a user. For more information
|
|
115
|
+
* about user properties, see [Confluence entity
|
|
116
|
+
* properties](https://developer.atlassian.com/cloud/confluence/confluence-entity-properties/).
|
|
117
|
+
* `Note`, these properties stored against a user are on a Confluence site level
|
|
118
|
+
* and not space/content level.
|
|
119
|
+
*
|
|
120
|
+
* **[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
|
|
121
|
+
* Permission to access the Confluence site ('Can use' global permission).
|
|
122
|
+
*
|
|
123
|
+
* @returns Returned if the requested properties are returned.
|
|
124
|
+
* @path {GET} /wiki/rest/api/user/{userId}/property/{key}
|
|
125
|
+
* @scopes-current read:user.property:confluence
|
|
126
|
+
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties#api-wiki-rest-api-user-userid-property-key-get
|
|
127
|
+
*/
|
|
128
|
+
this.getUserProperty = ({ userId, key, }) => {
|
|
129
|
+
return this.getClientInstance()
|
|
130
|
+
.request({
|
|
131
|
+
path: "/wiki/rest/api/user/{userId}/property/{key}",
|
|
132
|
+
method: "GET",
|
|
133
|
+
pathParams: {
|
|
134
|
+
userId,
|
|
135
|
+
key,
|
|
136
|
+
},
|
|
137
|
+
})
|
|
138
|
+
.then(this.getClientInstance().responseHandler({
|
|
139
|
+
200: {
|
|
140
|
+
"application/json": "json",
|
|
141
|
+
},
|
|
142
|
+
}))
|
|
143
|
+
.then(commonHttpClient.castResponse())
|
|
144
|
+
.then(validationSchemaStorage_1.validationSchemaStorage.validator("UserPropertiesService.getUserProperty.response"))
|
|
145
|
+
.then(commonHttpClient.getBody);
|
|
146
|
+
};
|
|
147
|
+
/**
|
|
148
|
+
* Updates a property for the given user. Note, you cannot update the key of a
|
|
149
|
+
* user property, only the value.
|
|
150
|
+
* For more information about user properties, see
|
|
151
|
+
* [Confluence entity
|
|
152
|
+
* properties](https://developer.atlassian.com/cloud/confluence/confluence-entity-properties/).
|
|
153
|
+
* `Note`, these properties stored against a user are on a Confluence site level
|
|
154
|
+
* and not space/content level.
|
|
155
|
+
*
|
|
156
|
+
* **[Permissions](https://confluence.atlassian.com/x/_AozKw) required**:
|
|
157
|
+
* Permission to access the Confluence site ('Can use' global permission).
|
|
158
|
+
*
|
|
159
|
+
* @path {PUT} /wiki/rest/api/user/{userId}/property/{key}
|
|
160
|
+
* @scopes-current write:user.property:confluence
|
|
161
|
+
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-user-properties#api-wiki-rest-api-user-userid-property-key-put
|
|
162
|
+
*/
|
|
163
|
+
this.updateUserProperty = ({ userId, key, userPropertyUpdate, }) => {
|
|
164
|
+
return this.getClientInstance()
|
|
165
|
+
.request({
|
|
166
|
+
path: "/wiki/rest/api/user/{userId}/property/{key}",
|
|
167
|
+
method: "PUT",
|
|
168
|
+
pathParams: {
|
|
169
|
+
userId,
|
|
170
|
+
key,
|
|
171
|
+
},
|
|
172
|
+
headers: {
|
|
173
|
+
"Content-Type": "application/json",
|
|
174
|
+
},
|
|
175
|
+
body: userPropertyUpdate,
|
|
176
|
+
})
|
|
177
|
+
.then(commonHttpClient.discardResult);
|
|
178
|
+
};
|
|
176
179
|
}
|
|
177
180
|
static initialize() {
|
|
178
181
|
validationSchemaStorage_1.validationSchemaStorage.registerExtensible("UserPropertiesService.getUserProperties.response", zod_1.z
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UserPropertiesService.js","sourceRoot":"","sources":["../../../../src/openapi/v1/services/UserPropertiesService.ts"],"names":[],"mappings":";;;AAAA,eAAe;AACf,wDAAwD;AACxD,gDAAgD;AAChD,6BAAwB;AAExB,6DAA6D;AAC7D,iEAA8D;AAC9D,6DAMkC;AAClC,wEAAqE;AACrE,8FAA8F;AAC9F,MAAa,qBAAsB,SAAQ,qCAAiB;
|
|
1
|
+
{"version":3,"file":"UserPropertiesService.js","sourceRoot":"","sources":["../../../../src/openapi/v1/services/UserPropertiesService.ts"],"names":[],"mappings":";;;AAAA,eAAe;AACf,wDAAwD;AACxD,gDAAgD;AAChD,6BAAwB;AAExB,6DAA6D;AAC7D,iEAA8D;AAC9D,6DAMkC;AAClC,wEAAqE;AACrE,8FAA8F;AAC9F,MAAa,qBAAsB,SAAQ,qCAAiB;IAA5D;;QACE;;;;;;;;;;;;;;;;WAgBG;QACH,uBAAkB,GAAG,CAAC,EACpB,MAAM,EACN,GAAG,EACH,kBAAkB,GAYnB,EAAiB,EAAE;YAClB,OAAO,IAAI,CAAC,iBAAiB,EAAE;iBAC5B,OAAO,CAAC;gBACP,IAAI,EAAE,6C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IAAI,CAAC,sBAAsB,CAAC;SAC3D,CAAC;aACD,QAAQ,CAAC,kDAAkD,CAAC,CAChE,CAAC;QACF,iDAAuB,CAAC,kBAAkB,CACxC,gDAAgD,EAChD,OAAC;aACE,MAAM,CAAC;YACN,MAAM,EAAE,OAAC,CAAC,OAAO,CAAC,GAAG,CAAC;YACtB,SAAS,EAAE,OAAC,CAAC,OAAO,CAAC,kBAAkB,CAAC;YACxC,IAAI,EAAE,iDAAuB,CAAC,IAAI,CAAC,cAAc,CAAC;SACnD,CAAC;aACD,QAAQ,CAAC,gDAAgD,CAAC,CAC9D,CAAC;QACF,iDAAuB,CAAC,YAAY,CAAC;YACnC,wDAAuC;SACxC,CAAC,CAAC;IACL,CAAC;CACF;AArRD,sDAqRC"}
|
|
@@ -16,15 +16,15 @@ export declare class UsersService extends CommonHttpService {
|
|
|
16
16
|
* @scopes-beta read:user:confluence
|
|
17
17
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-anonymous-get
|
|
18
18
|
*/
|
|
19
|
-
getAnonymousUser({ expand, }?: {
|
|
19
|
+
getAnonymousUser: ({ expand, }?: {
|
|
20
20
|
/**
|
|
21
21
|
* A multi-value parameter indicating which properties of the user to
|
|
22
22
|
* expand.
|
|
23
23
|
*
|
|
24
24
|
* - `operations` returns the operations that the user is allowed to do.
|
|
25
25
|
*/
|
|
26
|
-
expand?: "operations"[];
|
|
27
|
-
})
|
|
26
|
+
expand?: "operations"[] | undefined;
|
|
27
|
+
}) => Promise<UserAnonymous>;
|
|
28
28
|
/**
|
|
29
29
|
* Returns user details for the ids provided in request.
|
|
30
30
|
*
|
|
@@ -37,7 +37,7 @@ export declare class UsersService extends CommonHttpService {
|
|
|
37
37
|
* @scopes-beta read:content-details:confluence
|
|
38
38
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-bulk-get
|
|
39
39
|
*/
|
|
40
|
-
getBulkUserLookup({ accountId, expand, limit, }: {
|
|
40
|
+
getBulkUserLookup: ({ accountId, expand, limit, }: {
|
|
41
41
|
/** A list of accountId's of users to be returned. */
|
|
42
42
|
accountId: string;
|
|
43
43
|
/**
|
|
@@ -49,14 +49,14 @@ export declare class UsersService extends CommonHttpService {
|
|
|
49
49
|
* - `isExternalCollaborator` returns whether the user is an external
|
|
50
50
|
* collaborator user.
|
|
51
51
|
*/
|
|
52
|
-
expand?: ("operations" | "
|
|
52
|
+
expand?: ("operations" | "isExternalCollaborator" | "personalSpace")[] | undefined;
|
|
53
53
|
/**
|
|
54
54
|
* The maximum number of results returned.
|
|
55
55
|
* Currently API returns 200 results max.
|
|
56
56
|
* If more that 200 ids are passed first 200 will be returned.
|
|
57
57
|
*/
|
|
58
|
-
limit?: number;
|
|
59
|
-
})
|
|
58
|
+
limit?: number | undefined;
|
|
59
|
+
}) => Promise<BulkUserLookupArray>;
|
|
60
60
|
/**
|
|
61
61
|
* Returns the currently logged-in user. This includes information about
|
|
62
62
|
* the user, like the display name, userKey, account ID, profile picture,
|
|
@@ -71,7 +71,7 @@ export declare class UsersService extends CommonHttpService {
|
|
|
71
71
|
* @scopes-beta read:content-details:confluence
|
|
72
72
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-current-get
|
|
73
73
|
*/
|
|
74
|
-
getCurrentUser({ expand, }?: {
|
|
74
|
+
getCurrentUser: ({ expand, }?: {
|
|
75
75
|
/**
|
|
76
76
|
* A multi-value parameter indicating which properties of the user to
|
|
77
77
|
* expand.
|
|
@@ -81,8 +81,8 @@ export declare class UsersService extends CommonHttpService {
|
|
|
81
81
|
* - `isExternalCollaborator` returns whether the user is an external
|
|
82
82
|
* collaborator user.
|
|
83
83
|
*/
|
|
84
|
-
expand?: ("operations" | "
|
|
85
|
-
})
|
|
84
|
+
expand?: ("operations" | "isExternalCollaborator" | "personalSpace")[] | undefined;
|
|
85
|
+
}) => Promise<UserV1 | null>;
|
|
86
86
|
/**
|
|
87
87
|
* Returns the groups that a user is a member of.
|
|
88
88
|
*
|
|
@@ -95,7 +95,7 @@ export declare class UsersService extends CommonHttpService {
|
|
|
95
95
|
* @scopes-beta read:user:confluence, read:group:confluence
|
|
96
96
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-memberof-get
|
|
97
97
|
*/
|
|
98
|
-
getGroupMembershipsForUser({ accountId, start, limit, }: {
|
|
98
|
+
getGroupMembershipsForUser: ({ accountId, start, limit, }: {
|
|
99
99
|
/**
|
|
100
100
|
* The account ID of the user. The accountId uniquely identifies the user across
|
|
101
101
|
* all Atlassian products.
|
|
@@ -103,13 +103,13 @@ export declare class UsersService extends CommonHttpService {
|
|
|
103
103
|
*/
|
|
104
104
|
accountId: string;
|
|
105
105
|
/** The starting index of the returned groups. */
|
|
106
|
-
start?: number;
|
|
106
|
+
start?: number | undefined;
|
|
107
107
|
/**
|
|
108
108
|
* The maximum number of groups to return per page.
|
|
109
109
|
* Note, this may be restricted by fixed system limits.
|
|
110
110
|
*/
|
|
111
|
-
limit?: number;
|
|
112
|
-
})
|
|
111
|
+
limit?: number | undefined;
|
|
112
|
+
}) => Promise<GroupArrayWithLinks>;
|
|
113
113
|
/**
|
|
114
114
|
* Returns a user's email address. This API is only available to apps approved by
|
|
115
115
|
* Atlassian, according to these
|
|
@@ -122,14 +122,14 @@ export declare class UsersService extends CommonHttpService {
|
|
|
122
122
|
* @path {GET} /wiki/rest/api/user/email
|
|
123
123
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-email-get
|
|
124
124
|
*/
|
|
125
|
-
getPrivacyUnsafeUserEmail({ accountId, }: {
|
|
125
|
+
getPrivacyUnsafeUserEmail: ({ accountId, }: {
|
|
126
126
|
/**
|
|
127
127
|
* The account ID of the user, which uniquely identifies the user across all
|
|
128
128
|
* Atlassian products.
|
|
129
129
|
* For example, `384093:32b4d9w0-f6a5-3535-11a3-9c8c88d10192`. Required.
|
|
130
130
|
*/
|
|
131
131
|
accountId: string;
|
|
132
|
-
})
|
|
132
|
+
}) => Promise<AccountIdEmailRecord>;
|
|
133
133
|
/**
|
|
134
134
|
* Returns user email addresses for a set of accountIds. This API is only
|
|
135
135
|
* available to apps approved by
|
|
@@ -145,10 +145,10 @@ export declare class UsersService extends CommonHttpService {
|
|
|
145
145
|
* @path {GET} /wiki/rest/api/user/email/bulk
|
|
146
146
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-email-bulk-get
|
|
147
147
|
*/
|
|
148
|
-
getPrivacyUnsafeUserEmailBulk({ accountId, }: {
|
|
148
|
+
getPrivacyUnsafeUserEmailBulk: ({ accountId, }: {
|
|
149
149
|
/** The account IDs of the users. */
|
|
150
150
|
accountId: string[];
|
|
151
|
-
})
|
|
151
|
+
}) => Promise<AccountIdEmailRecordArray>;
|
|
152
152
|
/**
|
|
153
153
|
* Returns a user. This includes information about the user, such as the
|
|
154
154
|
* display name, account ID, profile picture, and more. The information returned
|
|
@@ -167,7 +167,7 @@ export declare class UsersService extends CommonHttpService {
|
|
|
167
167
|
* @scopes-beta read:content-details:confluence
|
|
168
168
|
* @see https://developer.atlassian.com/cloud/confluence/rest/v1/api-group-users#api-wiki-rest-api-user-get
|
|
169
169
|
*/
|
|
170
|
-
getUser({ accountId, expand, }: {
|
|
170
|
+
getUser: ({ accountId, expand, }: {
|
|
171
171
|
/**
|
|
172
172
|
* The account ID of the user. The accountId uniquely identifies the user across
|
|
173
173
|
* all Atlassian products.
|
|
@@ -183,7 +183,7 @@ export declare class UsersService extends CommonHttpService {
|
|
|
183
183
|
* - `isExternalCollaborator` returns whether the user is an external
|
|
184
184
|
* collaborator user.
|
|
185
185
|
*/
|
|
186
|
-
expand?: ("operations" | "
|
|
187
|
-
})
|
|
186
|
+
expand?: ("operations" | "isExternalCollaborator" | "personalSpace")[] | undefined;
|
|
187
|
+
}) => Promise<UserV1 | null>;
|
|
188
188
|
static initialize(): void;
|
|
189
189
|
}
|