Edwin Kempin | 2eebd14 | 2013-03-06 15:28:34 +0100 | [diff] [blame] | 1 | Gerrit Code Review - /groups/ REST API |
| 2 | ====================================== |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 3 | |
| 4 | This page describes the group related REST endpoints. |
| 5 | Please also take note of the general information on the |
| 6 | link:rest-api.html[REST API]. |
| 7 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 8 | [[group-endpoints]] |
| 9 | Group Endpoints |
| 10 | --------------- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 11 | |
Edwin Kempin | 7620274 | 2013-02-15 13:51:50 +0100 | [diff] [blame] | 12 | [[list-groups]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 13 | List Groups |
| 14 | ~~~~~~~~~~~ |
| 15 | [verse] |
| 16 | 'GET /groups/' |
| 17 | |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 18 | Lists the groups accessible by the caller. This is the same as |
| 19 | using the link:cmd-ls-groups.html[ls-groups] command over SSH, |
| 20 | and accepts the same options as query parameters. |
| 21 | |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 22 | As result a map is returned that maps the group names to |
| 23 | link:#group-info[GroupInfo] entries. The entries in the map are sorted |
| 24 | by group name. |
| 25 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 26 | .Request |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 27 | ---- |
| 28 | GET /groups/ HTTP/1.0 |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 29 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 30 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 31 | .Response |
| 32 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 33 | HTTP/1.1 200 OK |
| 34 | Content-Disposition: attachment |
| 35 | Content-Type: application/json;charset=UTF-8 |
| 36 | |
| 37 | )]}' |
| 38 | { |
| 39 | "Administrators": { |
| 40 | "kind": "gerritcodereview#group", |
| 41 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 42 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 43 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 44 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 45 | "description": "Gerrit Site Administrators", |
| 46 | "group_id": 1, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 47 | "owner": "Administrators", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 48 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 49 | }, |
| 50 | "Anonymous Users": { |
| 51 | "kind": "gerritcodereview#group", |
| 52 | "id": "global%3AAnonymous-Users", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 53 | "url": "#/admin/groups/uuid-global%3AAnonymous-Users", |
| 54 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 55 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 56 | "description": "Any user, signed-in or not", |
| 57 | "group_id": 2, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 58 | "owner": "Administrators", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 59 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 60 | }, |
| 61 | "MyProject_Committers": { |
| 62 | "kind": "gerritcodereview#group", |
| 63 | "id": "834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 64 | "url": "#/admin/groups/uuid-834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7", |
| 65 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 66 | "visible_to_all": true, |
| 67 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 68 | "group_id": 6, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 69 | "owner": "MyProject_Committers", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 70 | "owner_id": "834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7" |
| 71 | }, |
| 72 | "Non-Interactive Users": { |
| 73 | "kind": "gerritcodereview#group", |
| 74 | "id": "5057f3cbd3519d6ab69364429a89ffdffba50f73", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 75 | "url": "#/admin/groups/uuid-5057f3cbd3519d6ab69364429a89ffdffba50f73", |
| 76 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 77 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 78 | "description": "Users who perform batch actions on Gerrit", |
| 79 | "group_id": 4, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 80 | "owner": "Administrators", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 81 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 82 | }, |
| 83 | "Project Owners": { |
| 84 | "kind": "gerritcodereview#group", |
| 85 | "id": "global%3AProject-Owners", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 86 | "url": "#/admin/groups/uuid-global%3AProject-Owners", |
| 87 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 88 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 89 | "description": "Any owner of the project", |
| 90 | "group_id": 5, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 91 | "owner": "Administrators", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 92 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 93 | }, |
| 94 | "Registered Users": { |
| 95 | "kind": "gerritcodereview#group", |
| 96 | "id": "global%3ARegistered-Users", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 97 | "url": "#/admin/groups/uuid-global%3ARegistered-Users", |
| 98 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 99 | }, |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 100 | "description": "Any signed-in user", |
| 101 | "group_id": 3, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 102 | "owner": "Administrators", |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 103 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 104 | } |
| 105 | } |
| 106 | ---- |
| 107 | |
Edwin Kempin | a64c4b9 | 2013-01-23 11:30:40 +0100 | [diff] [blame] | 108 | .Get all groups |
| 109 | **** |
| 110 | get::/groups/ |
| 111 | **** |
| 112 | |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 113 | [[group-options]] |
| 114 | Group Options |
| 115 | ^^^^^^^^^^^^^ |
| 116 | Additional fields can be obtained by adding `o` parameters, each option |
| 117 | requires more lookups and slows down the query response time to the |
| 118 | client so they are generally disabled by default. Optional fields are: |
| 119 | |
| 120 | [[includes]] |
| 121 | -- |
| 122 | * `INCLUDES`: include list of directly included groups. |
| 123 | -- |
| 124 | |
| 125 | [[members]] |
| 126 | -- |
| 127 | * `MEMBERS`: include list of direct group members. |
| 128 | -- |
| 129 | |
Edwin Kempin | a3b4b63 | 2013-02-11 10:33:55 +0100 | [diff] [blame] | 130 | Check if a group is owned by the calling user |
| 131 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 132 | By setting the option `owned` and specifying a group to inspect with |
| 133 | the option `q`, it is possible to find out, if this group is owned by |
| 134 | the calling user. |
| 135 | |
| 136 | .Request |
| 137 | ---- |
| 138 | GET /groups/?owned&q=MyProject-Committers HTTP/1.0 |
| 139 | ---- |
| 140 | |
| 141 | If the group is owned by the calling user, the returned map contains |
| 142 | this group. If the calling user doesn't own this group an empty map is |
| 143 | returned. |
| 144 | |
| 145 | .Response |
| 146 | ---- |
| 147 | HTTP/1.1 200 OK |
| 148 | Content-Disposition: attachment |
| 149 | Content-Type: application/json;charset=UTF-8 |
| 150 | |
| 151 | )]}' |
| 152 | { |
| 153 | "MyProject-Committers": { |
| 154 | "kind": "gerritcodereview#group", |
| 155 | "id": "9999c971bb4ab872aab759d8c49833ee6b9ff320", |
Edwin Kempin | a3b4b63 | 2013-02-11 10:33:55 +0100 | [diff] [blame] | 156 | "url": "#/admin/groups/uuid-9999c971bb4ab872aab759d8c49833ee6b9ff320", |
| 157 | "options": { |
Edwin Kempin | a3b4b63 | 2013-02-11 10:33:55 +0100 | [diff] [blame] | 158 | "visible_to_all": true |
| 159 | }, |
| 160 | "description":"contains all committers for MyProject", |
| 161 | "group_id": 551, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 162 | "owner": "MyProject-Owners", |
Edwin Kempin | a3b4b63 | 2013-02-11 10:33:55 +0100 | [diff] [blame] | 163 | "owner_id": "7ca042f4d5847936fcb90ca91057673157fd06fc" |
| 164 | } |
| 165 | } |
| 166 | ---- |
| 167 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 168 | [[get-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 169 | Get Group |
| 170 | ~~~~~~~~~ |
| 171 | [verse] |
| 172 | 'GET /groups/link:#group-id[\{group-id\}]' |
| 173 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 174 | Retrieves a group. |
| 175 | |
| 176 | .Request |
| 177 | ---- |
| 178 | GET /groups/6a1e70e1a88782771a91808c8af9bbb7a9871389 HTTP/1.0 |
| 179 | ---- |
| 180 | |
| 181 | As response a link:#group-info[GroupInfo] entity is returned that |
| 182 | describes the group. |
| 183 | |
| 184 | .Response |
| 185 | ---- |
| 186 | HTTP/1.1 200 OK |
| 187 | Content-Disposition: attachment |
| 188 | Content-Type: application/json;charset=UTF-8 |
| 189 | |
| 190 | )]}' |
| 191 | { |
| 192 | "kind": "gerritcodereview#group", |
| 193 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 194 | "name": "Administrators", |
| 195 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 196 | "options": { |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 197 | }, |
| 198 | "description": "Gerrit Site Administrators", |
| 199 | "group_id": 1, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 200 | "owner": "Administrators", |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 201 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 202 | } |
| 203 | ---- |
| 204 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 205 | [[create-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 206 | Create Group |
| 207 | ~~~~~~~~~~~~ |
| 208 | [verse] |
| 209 | 'PUT /groups/link:#group-name[\{group-name\}]' |
| 210 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 211 | Creates a new Gerrit internal group. |
| 212 | |
| 213 | In the request body additional data for the group can be provided as |
| 214 | link:#group-input[GroupInput]. |
| 215 | |
| 216 | .Request |
| 217 | ---- |
| 218 | PUT /groups/MyProject-Committers HTTP/1.0 |
| 219 | Content-Type: application/json;charset=UTF-8 |
| 220 | |
| 221 | { |
| 222 | "description": "contains all committers for MyProject", |
| 223 | "visible_to_all": true, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 224 | "owner": "MyProject-Owners", |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 225 | "owner_id": "7ca042f4d5847936fcb90ca91057673157fd06fc" |
| 226 | } |
| 227 | ---- |
| 228 | |
| 229 | As response the link:#group-info[GroupInfo] entity is returned that |
| 230 | describes the created group. |
| 231 | |
| 232 | .Response |
| 233 | ---- |
| 234 | HTTP/1.1 201 Created |
| 235 | Content-Disposition: attachment |
| 236 | Content-Type: application/json;charset=UTF-8 |
| 237 | |
| 238 | )]}' |
| 239 | { |
| 240 | "kind": "gerritcodereview#group", |
| 241 | "id": "9999c971bb4ab872aab759d8c49833ee6b9ff320", |
| 242 | "name": "MyProject-Committers", |
| 243 | "url": "#/admin/groups/uuid-9999c971bb4ab872aab759d8c49833ee6b9ff320", |
| 244 | "options": { |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 245 | "visible_to_all": true |
| 246 | }, |
| 247 | "description":"contains all committers for MyProject", |
| 248 | "group_id": 551, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 249 | "owner": "MyProject-Owners", |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 250 | "owner_id": "7ca042f4d5847936fcb90ca91057673157fd06fc" |
| 251 | } |
| 252 | ---- |
| 253 | |
Edwin Kempin | 0aa2710 | 2013-02-27 16:44:16 +0100 | [diff] [blame] | 254 | If the group creation fails because the name is already in use the |
| 255 | response is "`409 Conflict`". |
| 256 | |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 257 | [[get-group-detail]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 258 | Get Group Detail |
| 259 | ~~~~~~~~~~~~~~~~ |
| 260 | [verse] |
| 261 | 'GET /groups/link:#group-id[\{group-id\}]/detail' |
| 262 | |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 263 | Retrieves a group with the direct link:#members[members] and the |
| 264 | directly link:#includes[included groups]. |
| 265 | |
| 266 | .Request |
| 267 | ---- |
| 268 | GET /groups/6a1e70e1a88782771a91808c8af9bbb7a9871389/detail HTTP/1.0 |
| 269 | ---- |
| 270 | |
| 271 | As response a link:#group-info[GroupInfo] entity is returned that |
| 272 | describes the group. |
| 273 | |
| 274 | .Response |
| 275 | ---- |
| 276 | HTTP/1.1 200 OK |
| 277 | Content-Disposition: attachment |
| 278 | Content-Type: application/json;charset=UTF-8 |
| 279 | |
| 280 | )]}' |
| 281 | { |
| 282 | "kind": "gerritcodereview#group", |
| 283 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 284 | "name": "Administrators", |
| 285 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 286 | "options": { |
| 287 | }, |
| 288 | "description": "Gerrit Site Administrators", |
| 289 | "group_id": 1, |
| 290 | "owner": "Administrators", |
| 291 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 292 | "members": [ |
| 293 | { |
Edwin Kempin | 51284e6 | 2013-03-05 15:26:41 +0100 | [diff] [blame] | 294 | "_account_id": 1000097, |
| 295 | "name": "Jane Roe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 296 | "email": "jane.roe@example.com", |
| 297 | "username": "jane" |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 298 | }, |
| 299 | { |
Edwin Kempin | 51284e6 | 2013-03-05 15:26:41 +0100 | [diff] [blame] | 300 | "_account_id": 1000096, |
| 301 | "name": "John Doe", |
| 302 | "email": "john.doe@example.com" |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 303 | "username": "john" |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 304 | } |
| 305 | ], |
| 306 | "includes": [] |
| 307 | } |
| 308 | ---- |
| 309 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 310 | [[get-group-name]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 311 | Get Group Name |
| 312 | ~~~~~~~~~~~~~~ |
| 313 | [verse] |
| 314 | 'GET /groups/link:#group-id[\{group-id\}]/name' |
| 315 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 316 | Retrieves the name of a group. |
| 317 | |
| 318 | .Request |
| 319 | ---- |
| 320 | GET /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/name HTTP/1.0 |
| 321 | ---- |
| 322 | |
| 323 | .Response |
| 324 | ---- |
| 325 | HTTP/1.1 200 OK |
| 326 | Content-Disposition: attachment |
| 327 | Content-Type: application/json;charset=UTF-8 |
| 328 | |
| 329 | )]}' |
| 330 | "MyProject-Committers" |
| 331 | ---- |
| 332 | |
| 333 | [[rename-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 334 | Rename Group |
| 335 | ~~~~~~~~~~~~ |
| 336 | [verse] |
| 337 | 'PUT /groups/link:#group-id[\{group-id\}]/name' |
| 338 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 339 | Renames a Gerrit internal group. |
| 340 | |
| 341 | The new group name must be provided in the request body. |
| 342 | |
| 343 | .Request |
| 344 | ---- |
| 345 | PUT /groups/MyProject-Committers/name HTTP/1.0 |
| 346 | Content-Type: application/json;charset=UTF-8 |
| 347 | |
| 348 | { |
| 349 | "name": "My-Project-Committers" |
| 350 | } |
| 351 | ---- |
| 352 | |
| 353 | As response the new group name is returned. |
| 354 | |
| 355 | .Response |
| 356 | ---- |
| 357 | HTTP/1.1 200 OK |
| 358 | Content-Disposition: attachment |
| 359 | Content-Type: application/json;charset=UTF-8 |
| 360 | |
| 361 | )]}' |
| 362 | "My-Project-Committers" |
| 363 | ---- |
| 364 | |
Edwin Kempin | 0aa2710 | 2013-02-27 16:44:16 +0100 | [diff] [blame] | 365 | If renaming the group fails because the new name is already in use the |
| 366 | response is "`409 Conflict`". |
| 367 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 368 | [[get-group-description]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 369 | Get Group Description |
| 370 | ~~~~~~~~~~~~~~~~~~~~~ |
| 371 | [verse] |
| 372 | 'GET /groups/link:#group-id[\{group-id\}]/description' |
| 373 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 374 | Retrieves the description of a group. |
| 375 | |
| 376 | .Request |
| 377 | ---- |
| 378 | GET /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/description HTTP/1.0 |
| 379 | ---- |
| 380 | |
| 381 | .Response |
| 382 | ---- |
| 383 | HTTP/1.1 200 OK |
| 384 | Content-Disposition: attachment |
| 385 | Content-Type: application/json;charset=UTF-8 |
| 386 | |
| 387 | )]}' |
| 388 | "contains all committers for MyProject" |
| 389 | ---- |
| 390 | |
Edwin Kempin | efec449 | 2013-02-22 10:09:23 +0100 | [diff] [blame] | 391 | If the group does not have a description an empty string is returned. |
| 392 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 393 | [[set-group-description]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 394 | Set Group Description |
| 395 | ~~~~~~~~~~~~~~~~~~~~~ |
| 396 | [verse] |
| 397 | 'PUT /groups/link:#group-id[\{group-id\}]/description' |
| 398 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 399 | Sets the description of a Gerrit internal group. |
| 400 | |
| 401 | The new group description must be provided in the request body. |
| 402 | |
| 403 | .Request |
| 404 | ---- |
| 405 | PUT /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/description HTTP/1.0 |
| 406 | Content-Type: application/json;charset=UTF-8 |
| 407 | |
| 408 | { |
| 409 | "description": "The committers of MyProject." |
| 410 | } |
| 411 | ---- |
| 412 | |
| 413 | As response the new group description is returned. |
| 414 | |
| 415 | .Response |
| 416 | ---- |
| 417 | HTTP/1.1 200 OK |
| 418 | Content-Disposition: attachment |
| 419 | Content-Type: application/json;charset=UTF-8 |
| 420 | |
| 421 | )]}' |
| 422 | "The committers of MyProject." |
| 423 | ---- |
| 424 | |
Edwin Kempin | 114ab16 | 2013-02-28 09:25:37 +0100 | [diff] [blame] | 425 | If the description was deleted the response is "`204 No Content`". |
| 426 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 427 | [[delete-group-description]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 428 | Delete Group Description |
| 429 | ~~~~~~~~~~~~~~~~~~~~~~~~ |
| 430 | [verse] |
| 431 | 'DELETE /groups/link:#group-id[\{group-id\}]/description' |
| 432 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 433 | Deletes the description of a Gerrit internal group. |
| 434 | |
| 435 | .Request |
| 436 | ---- |
| 437 | DELETE /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/description HTTP/1.0 |
| 438 | ---- |
| 439 | |
| 440 | .Response |
| 441 | ---- |
| 442 | HTTP/1.1 204 No Content |
| 443 | ---- |
| 444 | |
| 445 | [[get-group-options]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 446 | Get Group Options |
| 447 | ~~~~~~~~~~~~~~~~~ |
| 448 | [verse] |
| 449 | 'GET /groups/link:#group-id[\{group-id\}]/options' |
| 450 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 451 | Retrieves the options of a group. |
| 452 | |
| 453 | .Request |
| 454 | ---- |
| 455 | GET /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/options HTTP/1.0 |
| 456 | ---- |
| 457 | |
| 458 | As response a link:#group-options-info[GroupOptionsInfo] entity is |
| 459 | returned that describes the options of the group. |
| 460 | |
| 461 | .Response |
| 462 | ---- |
| 463 | HTTP/1.1 200 OK |
| 464 | Content-Disposition: attachment |
| 465 | Content-Type: application/json;charset=UTF-8 |
| 466 | |
| 467 | )]}' |
| 468 | { |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 469 | "visible_to_all": true |
| 470 | } |
| 471 | ---- |
| 472 | |
| 473 | [[set-group-options]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 474 | Set Group Options |
| 475 | ~~~~~~~~~~~~~~~~~ |
| 476 | [verse] |
| 477 | 'PUT /groups/link:#group-id[\{group-id\}]/options' |
| 478 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 479 | Sets the options of a Gerrit internal group. |
| 480 | |
| 481 | The new group options must be provided in the request body as a |
| 482 | link:#group-options-input[GroupOptionsInput] entity. |
| 483 | |
| 484 | .Request |
| 485 | ---- |
| 486 | PUT /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/options HTTP/1.0 |
| 487 | Content-Type: application/json;charset=UTF-8 |
| 488 | |
| 489 | { |
| 490 | "visible_to_all": true |
| 491 | } |
| 492 | ---- |
| 493 | |
| 494 | As response the new group options are returned as a |
| 495 | link:#group-options-info[GroupOptionsInfo] entity. |
| 496 | |
| 497 | .Response |
| 498 | ---- |
| 499 | HTTP/1.1 200 OK |
| 500 | Content-Disposition: attachment |
| 501 | Content-Type: application/json;charset=UTF-8 |
| 502 | |
| 503 | )]}' |
| 504 | { |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 505 | "visible_to_all": true |
| 506 | } |
| 507 | ---- |
| 508 | |
| 509 | [[get-group-owner]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 510 | Get Group Owner |
| 511 | ~~~~~~~~~~~~~~~ |
| 512 | [verse] |
| 513 | 'GET /groups/link:#group-id[\{group-id\}]/owner' |
| 514 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 515 | Retrieves the owner group of a Gerrit internal group. |
| 516 | |
| 517 | .Request |
| 518 | ---- |
| 519 | GET /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/owner HTTP/1.0 |
| 520 | ---- |
| 521 | |
| 522 | As response a link:#group-info[GroupInfo] entity is returned that |
| 523 | describes the owner group. |
| 524 | |
| 525 | .Response |
| 526 | ---- |
| 527 | HTTP/1.1 200 OK |
| 528 | Content-Disposition: attachment |
| 529 | Content-Type: application/json;charset=UTF-8 |
| 530 | |
| 531 | )]}' |
| 532 | { |
| 533 | "kind": "gerritcodereview#group", |
| 534 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 535 | "name": "Administrators", |
| 536 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 537 | "options": { |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 538 | }, |
| 539 | "description": "Gerrit Site Administrators", |
| 540 | "group_id": 1, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 541 | "owner": "Administrators", |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 542 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 543 | } |
| 544 | ---- |
| 545 | |
| 546 | [[set-group-owner]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 547 | Set Group Owner |
| 548 | ~~~~~~~~~~~~~~~ |
| 549 | [verse] |
| 550 | 'PUT /groups/link:#group-id[\{group-id\}]/owner' |
| 551 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 552 | Sets the owner group of a Gerrit internal group. |
| 553 | |
| 554 | The new owner group must be provided in the request body. |
| 555 | |
Edwin Kempin | c977090 | 2013-02-15 15:38:03 +0100 | [diff] [blame] | 556 | The new owner can be specified by name, by group UUID or by the legacy |
| 557 | numeric group ID. |
| 558 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 559 | .Request |
| 560 | ---- |
| 561 | PUT /groups/9999c971bb4ab872aab759d8c49833ee6b9ff320/description HTTP/1.0 |
| 562 | Content-Type: application/json;charset=UTF-8 |
| 563 | |
| 564 | { |
| 565 | "owner": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 566 | } |
| 567 | ---- |
| 568 | |
| 569 | As response a link:#group-info[GroupInfo] entity is returned that |
| 570 | describes the new owner group. |
| 571 | |
| 572 | .Response |
| 573 | ---- |
| 574 | HTTP/1.1 200 OK |
| 575 | Content-Disposition: attachment |
| 576 | Content-Type: application/json;charset=UTF-8 |
| 577 | |
| 578 | )]}' |
| 579 | { |
| 580 | "kind": "gerritcodereview#group", |
| 581 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 582 | "name": "Administrators", |
| 583 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 584 | "options": { |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 585 | }, |
| 586 | "description": "Gerrit Site Administrators", |
| 587 | "group_id": 1, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 588 | "owner": "Administrators", |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 589 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 590 | } |
| 591 | ---- |
| 592 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 593 | [[group-member-endpoints]] |
| 594 | Group Member Endpoints |
| 595 | ---------------------- |
| 596 | |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 597 | [[group-members]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 598 | List Group Members |
| 599 | ~~~~~~~~~~~~~~~~~~ |
| 600 | [verse] |
| 601 | 'GET /groups/link:#group-id[\{group-id\}]/members/' |
| 602 | |
Edwin Kempin | 2dc5edc | 2013-02-11 15:57:36 +0100 | [diff] [blame] | 603 | Lists the direct members of a Gerrit internal group. |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 604 | |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 605 | As result a list of detailed link:rest-api-accounts.html#account-info[ |
| 606 | AccountInfo] entries is returned. The entries in the list are sorted by |
| 607 | full name, preferred email and id. |
Edwin Kempin | 4156d6e0 | 2013-02-04 15:10:39 +0100 | [diff] [blame] | 608 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 609 | .Request |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 610 | ---- |
| 611 | GET /groups/834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7/members/ HTTP/1.0 |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 612 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 613 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 614 | .Response |
| 615 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 616 | HTTP/1.1 200 OK |
| 617 | Content-Disposition: attachment |
| 618 | Content-Type: application/json;charset=UTF-8 |
| 619 | |
| 620 | )]}' |
| 621 | [ |
| 622 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 623 | "_account_id": 1000097, |
| 624 | "name": "Jane Roe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 625 | "email": "jane.roe@example.com", |
| 626 | "username": "jane" |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 627 | }, |
| 628 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 629 | "_account_id": 1000096, |
| 630 | "name": "John Doe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 631 | "email": "john.doe@example.com", |
| 632 | "username": "john" |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 633 | } |
| 634 | ] |
| 635 | ---- |
| 636 | |
Edwin Kempin | a64c4b9 | 2013-01-23 11:30:40 +0100 | [diff] [blame] | 637 | .Get all members of the 'Administrators' group (normally group id = 1) |
| 638 | **** |
| 639 | get::/groups/1/members/ |
| 640 | **** |
| 641 | |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 642 | To resolve the included groups of a group recursively and to list all |
| 643 | members the parameter `recursive` can be set. |
| 644 | |
Edwin Kempin | d54de1c | 2013-03-08 16:37:14 +0100 | [diff] [blame] | 645 | Members from included external groups and from included groups which |
| 646 | are not visible to the calling user are ignored. |
| 647 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 648 | .Request |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 649 | ---- |
| 650 | GET /groups/834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7/members/?recursive HTTP/1.0 |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 651 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 652 | |
Edwin Kempin | 3744083 | 2013-02-06 11:36:00 +0100 | [diff] [blame] | 653 | .Response |
| 654 | ---- |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 655 | HTTP/1.1 200 OK |
| 656 | Content-Disposition: attachment |
| 657 | Content-Type: application/json;charset=UTF-8 |
| 658 | |
| 659 | )]}' |
| 660 | [ |
| 661 | { |
Edwin Kempin | 3e22d48 | 2013-03-05 15:35:25 +0100 | [diff] [blame] | 662 | "_account_id": 1000097, |
| 663 | "name": "Jane Roe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 664 | "email": "jane.roe@example.com", |
| 665 | "username": "jane" |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 666 | }, |
| 667 | { |
Edwin Kempin | 3e22d48 | 2013-03-05 15:35:25 +0100 | [diff] [blame] | 668 | "_account_id": 1000096, |
| 669 | "name": "John Doe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 670 | "email": "john.doe@example.com", |
| 671 | "username": "john" |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 672 | }, |
| 673 | { |
Edwin Kempin | 3e22d48 | 2013-03-05 15:35:25 +0100 | [diff] [blame] | 674 | "_account_id": 1000098, |
| 675 | "name": "Richard Roe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 676 | "email": "richard.roe@example.com", |
| 677 | "username": "rroe" |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 678 | } |
| 679 | ] |
| 680 | ---- |
| 681 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 682 | [[get-group-member]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 683 | Get Group Member |
| 684 | ~~~~~~~~~~~~~~~~ |
| 685 | [verse] |
| 686 | 'GET /groups/link:#group-id[\{group-id\}]/members/link:rest-api-accounts.html#account-id[\{account-id\}]' |
| 687 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 688 | Retrieves a group member. |
| 689 | |
| 690 | .Request |
| 691 | ---- |
| 692 | GET /groups/834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7/members/1000096 HTTP/1.0 |
| 693 | ---- |
| 694 | |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 695 | As response a detailed link:rest-api-accounts.html#account-info[ |
| 696 | AccountInfo] entity is returned that describes the group member. |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 697 | |
| 698 | .Response |
| 699 | ---- |
| 700 | HTTP/1.1 200 OK |
| 701 | Content-Disposition: attachment |
| 702 | Content-Type: application/json;charset=UTF-8 |
| 703 | |
| 704 | )]}' |
| 705 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 706 | "_account_id": 1000096, |
| 707 | "name": "John Doe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 708 | "email": "john.doe@example.com", |
| 709 | "username": "john" |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 710 | } |
| 711 | ---- |
| 712 | |
Edwin Kempin | a5d6ead | 2013-02-06 10:59:06 +0100 | [diff] [blame] | 713 | [[add-group-member]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 714 | Add Group Member |
| 715 | ~~~~~~~~~~~~~~~~ |
| 716 | [verse] |
| 717 | 'PUT /groups/link:#group-id[\{group-id\}]/members/link:rest-api-accounts.html#account-id[\{account-id\}]' |
| 718 | |
Edwin Kempin | a5d6ead | 2013-02-06 10:59:06 +0100 | [diff] [blame] | 719 | Adds a user as member to a Gerrit internal group. |
| 720 | |
| 721 | .Request |
| 722 | ---- |
| 723 | PUT /groups/MyProject-Committers/members/John%20Doe HTTP/1.0 |
| 724 | ---- |
| 725 | |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 726 | As response a detailed link:rest-api-accounts.html#account-info[ |
| 727 | AccountInfo] entity is returned that describes the group member. |
Edwin Kempin | a5d6ead | 2013-02-06 10:59:06 +0100 | [diff] [blame] | 728 | |
| 729 | .Response |
| 730 | ---- |
| 731 | HTTP/1.1 201 Created |
| 732 | Content-Disposition: attachment |
| 733 | Content-Type: application/json;charset=UTF-8 |
| 734 | |
| 735 | )]}' |
| 736 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 737 | "_account_id": 1000037, |
| 738 | "name": "John Doe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 739 | "email": "john.doe@example.com", |
| 740 | "username": "john" |
Edwin Kempin | a5d6ead | 2013-02-06 10:59:06 +0100 | [diff] [blame] | 741 | } |
| 742 | ---- |
| 743 | |
| 744 | The request also succeeds if the user is already a member of this |
| 745 | group, but then the HTTP response code is `200 OK`. |
| 746 | |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 747 | Add Group Members |
| 748 | ~~~~~~~~~~~~~~~~~ |
| 749 | [verse] |
| 750 | 'POST /groups/link:#group-id[\{group-id\}]/members' |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 751 | |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 752 | OR |
| 753 | |
| 754 | [verse] |
| 755 | 'POST /groups/link:#group-id[\{group-id\}]/members.add' |
| 756 | |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 757 | Adds one or several users to a Gerrit internal group. |
| 758 | |
| 759 | The users to be added to the group must be provided in the request body |
Sasa Zivkov | 737e0a3 | 2013-03-18 14:21:42 +0100 | [diff] [blame] | 760 | as a link:#members-input[MembersInput] entity. |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 761 | |
| 762 | .Request |
| 763 | ---- |
| 764 | POST /groups/MyProject-Committers/members.add HTTP/1.0 |
| 765 | Content-Type: application/json;charset=UTF-8 |
| 766 | |
| 767 | { |
| 768 | "members": { |
| 769 | "jane.roe@example.com", |
| 770 | "john.doe@example.com" |
| 771 | } |
| 772 | } |
| 773 | ---- |
| 774 | |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 775 | As response a list of detailed link:rest-api-accounts.html#account-info[ |
| 776 | AccountInfo] entities is returned that describes the group members that |
Sasa Zivkov | 737e0a3 | 2013-03-18 14:21:42 +0100 | [diff] [blame] | 777 | were specified in the link:#members-input[MembersInput]. An |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 778 | link:rest-api-accounts.html#account-info[AccountInfo] entity |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 779 | is returned for each user specified in the input, independently of |
| 780 | whether the user was newly added to the group or whether the user was |
| 781 | already a member of the group. |
| 782 | |
| 783 | .Response |
| 784 | ---- |
| 785 | HTTP/1.1 200 OK |
| 786 | Content-Disposition: attachment |
| 787 | Content-Type: application/json;charset=UTF-8 |
| 788 | |
| 789 | )]}' |
| 790 | [ |
| 791 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 792 | "_account_id": 1000057, |
| 793 | "name": "Jane Roe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 794 | "email": "jane.roe@example.com", |
| 795 | "username": "jane" |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 796 | }, |
| 797 | { |
Edwin Kempin | 963dfd0 | 2013-02-27 12:39:32 +0100 | [diff] [blame] | 798 | "_account_id": 1000037, |
| 799 | "name": "John Doe", |
James Ring | 8e34272 | 2013-05-01 01:40:53 -0700 | [diff] [blame] | 800 | "email": "john.doe@example.com", |
| 801 | "username": "john" |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 802 | } |
| 803 | ] |
| 804 | ---- |
| 805 | |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 806 | [[delete-group-member]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 807 | Delete Group Member |
| 808 | ~~~~~~~~~~~~~~~~~~~ |
| 809 | [verse] |
| 810 | 'DELETE /groups/link:#group-id[\{group-id\}]/members/link:rest-api-accounts.html#account-id[\{account-id\}]' |
| 811 | |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 812 | Deletes a user from a Gerrit internal group. |
| 813 | |
| 814 | .Request |
| 815 | ---- |
| 816 | DELETE /groups/MyProject-Committers/members/John%20Doe HTTP/1.0 |
| 817 | ---- |
| 818 | |
| 819 | .Response |
| 820 | ---- |
| 821 | HTTP/1.1 204 No Content |
| 822 | ---- |
| 823 | |
| 824 | [[delete-group-members]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 825 | Delete Group Members |
| 826 | ~~~~~~~~~~~~~~~~~~~~ |
| 827 | [verse] |
| 828 | 'POST /groups/link:#group-id[\{group-id\}]/members.delete' |
| 829 | |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 830 | Delete one or several users from a Gerrit internal group. |
| 831 | |
| 832 | The users to be deleted from the group must be provided in the request |
Sasa Zivkov | 737e0a3 | 2013-03-18 14:21:42 +0100 | [diff] [blame] | 833 | body as a link:#members-input[MembersInput] entity. |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 834 | |
| 835 | .Request |
| 836 | ---- |
| 837 | POST /groups/MyProject-Committers/members.delete HTTP/1.0 |
| 838 | Content-Type: application/json;charset=UTF-8 |
| 839 | |
| 840 | { |
| 841 | "members": { |
| 842 | "jane.roe@example.com", |
| 843 | "john.doe@example.com" |
| 844 | } |
| 845 | } |
| 846 | ---- |
| 847 | |
| 848 | .Response |
| 849 | ---- |
| 850 | HTTP/1.1 204 No Content |
| 851 | ---- |
| 852 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 853 | [[group-include-endpoints]] |
| 854 | Group Include Endpoints |
| 855 | ----------------------- |
| 856 | |
| 857 | [[included-groups]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 858 | List Included Groups |
| 859 | ~~~~~~~~~~~~~~~~~~~~ |
| 860 | [verse] |
| 861 | 'GET /groups/link:#group-id[\{group-id\}]/groups/' |
| 862 | |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 863 | Lists the directly included groups of a group. |
| 864 | |
| 865 | As result a list of link:#group-info[GroupInfo] entries is returned. |
| 866 | The entries in the list are sorted by group name and UUID. |
| 867 | |
| 868 | .Request |
| 869 | ---- |
| 870 | GET /groups/834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7/groups/ HTTP/1.0 |
| 871 | ---- |
| 872 | |
| 873 | .Response |
| 874 | ---- |
| 875 | HTTP/1.1 200 OK |
| 876 | Content-Disposition: attachment |
| 877 | Content-Type: application/json;charset=UTF-8 |
| 878 | |
| 879 | )]}' |
| 880 | [ |
| 881 | { |
| 882 | "kind": "gerritcodereview#group", |
| 883 | "id": "7ca042f4d5847936fcb90ca91057673157fd06fc", |
| 884 | "name": "MyProject-Verifiers", |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 885 | "url": "#/admin/groups/uuid-7ca042f4d5847936fcb90ca91057673157fd06fc", |
| 886 | "options": { |
Edwin Kempin | e05c964 | 2013-02-11 09:36:21 +0100 | [diff] [blame] | 887 | }, |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 888 | "group_id": 38, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 889 | "owner": "MyProject-Verifiers", |
Edwin Kempin | 578fff7 | 2013-02-11 08:08:27 +0100 | [diff] [blame] | 890 | "owner_id": "7ca042f4d5847936fcb90ca91057673157fd06fc" |
| 891 | } |
| 892 | ] |
| 893 | ---- |
| 894 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 895 | [[get-included-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 896 | Get Included Group |
| 897 | ~~~~~~~~~~~~~~~~~~ |
| 898 | [verse] |
| 899 | 'GET /groups/link:#group-id[\{group-id\}]/groups/link:#group-id[\{group-id\}]' |
| 900 | |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 901 | Retrieves an included group. |
| 902 | |
| 903 | .Request |
| 904 | ---- |
| 905 | GET /groups/834ec36dd5e0ed21a2ff5d7e2255da082d63bbd7/groups/7ca042f4d5847936fcb90ca91057673157fd06fc HTTP/1.0 |
| 906 | ---- |
| 907 | |
| 908 | As response a link:#group-info[GroupInfo] entity is returned that |
| 909 | describes the included group. |
| 910 | |
| 911 | .Response |
| 912 | ---- |
| 913 | HTTP/1.1 200 OK |
| 914 | Content-Disposition: attachment |
| 915 | Content-Type: application/json;charset=UTF-8 |
| 916 | |
| 917 | )]}' |
| 918 | { |
| 919 | "kind": "gerritcodereview#group", |
| 920 | "id": "7ca042f4d5847936fcb90ca91057673157fd06fc", |
| 921 | "name": "MyProject-Verifiers", |
| 922 | "url": "#/admin/groups/uuid-7ca042f4d5847936fcb90ca91057673157fd06fc", |
| 923 | "options": { |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 924 | }, |
| 925 | "group_id": 38, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 926 | "owner": "Administrators", |
Edwin Kempin | a5cc112 | 2013-02-11 09:26:20 +0100 | [diff] [blame] | 927 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 928 | } |
| 929 | ---- |
| 930 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 931 | [[include-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 932 | Include Group |
| 933 | ~~~~~~~~~~~~~ |
| 934 | [verse] |
| 935 | 'PUT /groups/link:#group-id[\{group-id\}]/groups/link:#group-id[\{group-id\}]' |
| 936 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 937 | Includes a group into a Gerrit internal group. |
| 938 | |
| 939 | .Request |
| 940 | ---- |
| 941 | PUT /groups/MyProject-Committers/groups/MyGroup HTTP/1.0 |
| 942 | ---- |
| 943 | |
| 944 | As response a link:#group-info[GroupInfo] entity is returned that |
| 945 | describes the included group. |
| 946 | |
| 947 | .Response |
| 948 | ---- |
| 949 | HTTP/1.1 201 Created |
| 950 | Content-Disposition: attachment |
| 951 | Content-Type: application/json;charset=UTF-8 |
| 952 | |
| 953 | )]}' |
| 954 | { |
| 955 | "kind": "gerritcodereview#group", |
| 956 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 957 | "name": "MyGroup", |
| 958 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 959 | "options": { |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 960 | }, |
| 961 | "group_id": 8, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 962 | "owner": "Administrators", |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 963 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 964 | } |
| 965 | ---- |
| 966 | |
| 967 | The request also succeeds if the group is already included in this |
| 968 | group, but then the HTTP response code is `200 OK`. |
| 969 | |
John Spurlock | d25fad1 | 2013-03-09 11:48:49 -0500 | [diff] [blame] | 970 | [[include-groups]] |
Edwin Kempin | 7722cc6 | 2013-03-08 09:03:15 +0100 | [diff] [blame] | 971 | Include Groups |
| 972 | ~~~~~~~~~~~~~~ |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 973 | [verse] |
| 974 | 'POST /groups/link:#group-id[\{group-id\}]/groups' |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 975 | |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 976 | OR |
| 977 | |
| 978 | [verse] |
| 979 | 'POST /groups/link:#group-id[\{group-id\}]/groups.add' |
| 980 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 981 | Includes one or several groups into a Gerrit internal group. |
| 982 | |
| 983 | The groups to be included into the group must be provided in the |
| 984 | request body as a link:#groups-input[GroupsInput] entity. |
| 985 | |
| 986 | .Request |
| 987 | ---- |
| 988 | POST /groups/MyProject-Committers/groups.add HTTP/1.0 |
| 989 | Content-Type: application/json;charset=UTF-8 |
| 990 | |
| 991 | { |
| 992 | "groups": { |
| 993 | "MyGroup", |
| 994 | "MyOtherGroup" |
| 995 | } |
| 996 | } |
| 997 | ---- |
| 998 | |
| 999 | As response a list of link:#group-info[GroupInfo] entities is |
| 1000 | returned that describes the groups that were specified in the |
| 1001 | link:#groups-input[GroupsInput]. A link:#group-info[GroupInfo] entity |
| 1002 | is returned for each group specified in the input, independently of |
| 1003 | whether the group was newly included into the group or whether the |
| 1004 | group was already included in the group. |
| 1005 | |
| 1006 | .Response |
| 1007 | ---- |
| 1008 | HTTP/1.1 200 OK |
| 1009 | Content-Disposition: attachment |
| 1010 | Content-Type: application/json;charset=UTF-8 |
| 1011 | |
| 1012 | )]}' |
| 1013 | [ |
| 1014 | { |
| 1015 | "kind": "gerritcodereview#group", |
| 1016 | "id": "6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 1017 | "name": "MyGroup", |
| 1018 | "url": "#/admin/groups/uuid-6a1e70e1a88782771a91808c8af9bbb7a9871389", |
| 1019 | "options": { |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1020 | }, |
| 1021 | "group_id": 8, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 1022 | "owner": "Administrators", |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1023 | "owner_id": "6a1e70e1a88782771a91808c8af9bbb7a9871389" |
| 1024 | }, |
| 1025 | { |
| 1026 | "kind": "gerritcodereview#group", |
| 1027 | "id": "5057f3cbd3519d6ab69364429a89ffdffba50f73", |
| 1028 | "name": "MyOtherGroup", |
| 1029 | "url": "#/admin/groups/uuid-5057f3cbd3519d6ab69364429a89ffdffba50f73", |
| 1030 | "options": { |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1031 | }, |
| 1032 | "group_id": 10, |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 1033 | "owner": "MyOtherGroup", |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1034 | "owner_id": "5057f3cbd3519d6ab69364429a89ffdffba50f73" |
| 1035 | } |
| 1036 | ] |
| 1037 | ---- |
| 1038 | |
| 1039 | [[delete-included-group]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 1040 | Delete Included Group |
| 1041 | ~~~~~~~~~~~~~~~~~~~~~ |
| 1042 | [verse] |
| 1043 | 'DELETE /groups/link:#group-id[\{group-id\}]/groups/link:#group-id[\{group-id\}]' |
| 1044 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1045 | Deletes an included group from a Gerrit internal group. |
| 1046 | |
| 1047 | .Request |
| 1048 | ---- |
| 1049 | DELETE /groups/MyProject-Committers/groups/MyGroup HTTP/1.0 |
| 1050 | ---- |
| 1051 | |
| 1052 | .Response |
| 1053 | ---- |
| 1054 | HTTP/1.1 204 No Content |
| 1055 | ---- |
| 1056 | |
| 1057 | [[delete-included-groups]] |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 1058 | Delete Included Groups |
| 1059 | ~~~~~~~~~~~~~~~~~~~~~~ |
| 1060 | [verse] |
| 1061 | 'POST /groups/link:#group-id[\{group-id\}]/groups.delete' |
| 1062 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1063 | Delete one or several included groups from a Gerrit internal group. |
| 1064 | |
| 1065 | The groups to be deleted from the group must be provided in the request |
| 1066 | body as a link:#groups-input[GroupsInput] entity. |
| 1067 | |
| 1068 | .Request |
| 1069 | ---- |
| 1070 | POST /groups/MyProject-Committers/groups.delete HTTP/1.0 |
| 1071 | Content-Type: application/json;charset=UTF-8 |
| 1072 | |
| 1073 | { |
| 1074 | "members": { |
| 1075 | "MyGroup", |
| 1076 | "MyOtherGroup" |
| 1077 | } |
| 1078 | } |
| 1079 | ---- |
| 1080 | |
| 1081 | .Response |
| 1082 | ---- |
| 1083 | HTTP/1.1 204 No Content |
| 1084 | ---- |
| 1085 | |
Edwin Kempin | aa266ff | 2013-02-05 12:41:09 +0100 | [diff] [blame] | 1086 | |
Edwin Kempin | 34d8335 | 2013-02-06 10:40:17 +0100 | [diff] [blame] | 1087 | [[ids]] |
| 1088 | IDs |
| 1089 | --- |
| 1090 | |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 1091 | [[account-id]] |
Edwin Kempin | 4efe257 | 2013-02-27 10:16:17 +0100 | [diff] [blame] | 1092 | link:rest-api-accounts.html#account-id[\{account-id\}] |
| 1093 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 1094 | -- |
| 1095 | -- |
Edwin Kempin | a5d6ead | 2013-02-06 10:59:06 +0100 | [diff] [blame] | 1096 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1097 | [[group-id]] |
Edwin Kempin | 34d8335 | 2013-02-06 10:40:17 +0100 | [diff] [blame] | 1098 | \{group-id\} |
| 1099 | ~~~~~~~~~~~~ |
| 1100 | Identifier for a group. |
| 1101 | |
| 1102 | This can be: |
| 1103 | |
| 1104 | * the UUID of the group |
| 1105 | * the legacy numeric ID of the group |
| 1106 | * the name of the group if it is unique |
| 1107 | |
Edwin Kempin | 50d3d9b | 2013-03-06 16:38:26 +0100 | [diff] [blame] | 1108 | [[group-name]] |
Edwin Kempin | 34d8335 | 2013-02-06 10:40:17 +0100 | [diff] [blame] | 1109 | \{group-name\} |
| 1110 | ~~~~~~~~~~~~~~ |
| 1111 | Group name that uniquely identifies one group. |
| 1112 | |
| 1113 | |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1114 | [[json-entities]] |
| 1115 | JSON Entities |
| 1116 | ------------- |
| 1117 | |
| 1118 | [[group-info]] |
| 1119 | GroupInfo |
| 1120 | ~~~~~~~~~ |
| 1121 | The `GroupInfo` entity contains information about a group. This can be |
| 1122 | a Gerrit internal group, or an external group that is known to Gerrit. |
| 1123 | |
| 1124 | [options="header",width="50%",cols="1,^1,5"] |
| 1125 | |=========================== |
| 1126 | |Field Name ||Description |
| 1127 | |`kind` ||`gerritcodereview#group` |
| 1128 | |`id` ||The URL encoded UUID of the group. |
Edwin Kempin | 5b591d1 | 2013-03-08 09:18:35 +0100 | [diff] [blame] | 1129 | |`name` | |
| 1130 | not set if returned in a map where the group name is used as map key| |
| 1131 | The name of the group. |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1132 | |`url` |optional| |
| 1133 | URL to information about the group. Typically a URL to a web page that |
| 1134 | permits users to apply to join the group, or manage their membership. |
| 1135 | |`options` ||link:#group-options-info[Options of the group] |
| 1136 | |`description` |only for internal groups|The description of the group. |
| 1137 | |`group_id` |only for internal groups|The numeric ID of the group. |
Edwin Kempin | c6993fb | 2013-02-11 12:39:13 +0100 | [diff] [blame] | 1138 | |`owner` |only for internal groups|The name of the owner group. |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1139 | |`owner_id` |only for internal groups|The URL encoded UUID of the owner group. |
Edwin Kempin | abaab546 | 2013-02-11 15:30:19 +0100 | [diff] [blame] | 1140 | |`members` |optional, only for internal groups| |
| 1141 | A list of link:rest-api-accounts.html#account-info[AccountInfo] |
| 1142 | entities describing the direct members. + |
| 1143 | Only set if link:#members[members] are requested. |
| 1144 | |`includes` |optional, only for internal groups| |
| 1145 | A list of link:#group-info[GroupInfo] entities describing the directly |
| 1146 | included groups. + |
| 1147 | Only set if link:#includes[included groups] are requested. |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1148 | |=========================== |
| 1149 | |
Edwin Kempin | c42abb9 | 2013-02-04 14:52:41 +0100 | [diff] [blame] | 1150 | The type of a group can be deduced from the group's UUID: |
| 1151 | [width="50%"] |
| 1152 | |============ |
| 1153 | |UUID matches "^[0-9a-f]\{40\}$"|Gerrit internal group |
| 1154 | |UUID starts with "global:"|Gerrit system group |
| 1155 | |UUID starts with "ldap:"|LDAP group |
| 1156 | |UUID starts with "<prefix>:"|other external group |
| 1157 | |============ |
| 1158 | |
Edwin Kempin | aa266ff | 2013-02-05 12:41:09 +0100 | [diff] [blame] | 1159 | [[group-input]] |
| 1160 | GroupInput |
| 1161 | ~~~~~~~~~~ |
| 1162 | The 'GroupInput' entity contains information for the creation of |
| 1163 | a new internal group. |
| 1164 | |
| 1165 | [options="header",width="50%",cols="1,^1,5"] |
| 1166 | |=========================== |
| 1167 | |Field Name ||Description |
| 1168 | |`name` |optional|The name of the group (not encoded). + |
| 1169 | If set, must match the group name in the URL. |
| 1170 | |`description` |optional|The description of the group. |
| 1171 | |`visible_to_all`|optional| |
| 1172 | Whether the group is visible to all registered users. + |
| 1173 | `false` if not set. |
| 1174 | |`owner_id`|optional|The URL encoded ID of the owner group. + |
| 1175 | This can be a group UUID, a legacy numeric group ID or a unique group |
| 1176 | name. + |
| 1177 | If not set, the new group will be self-owned. |
| 1178 | |=========================== |
| 1179 | |
Edwin Kempin | 2689e3d | 2013-02-07 15:52:36 +0100 | [diff] [blame] | 1180 | [[groups-input]] |
| 1181 | GroupsInput |
| 1182 | ~~~~~~~~~~~ |
| 1183 | The `GroupsInput` entity contains information about groups that should |
| 1184 | be included into a group or that should be deleted from a group. |
| 1185 | |
| 1186 | [options="header",width="50%",cols="1,^1,5"] |
| 1187 | |========================== |
| 1188 | |Field Name ||Description |
| 1189 | |`_one_group` |optional| |
| 1190 | The link:#group-id[id] of one group that should be included or deleted. |
| 1191 | |`groups` |optional| |
| 1192 | A list of link:#group-id[group ids] that identify the groups that |
| 1193 | should be included or deleted. |
| 1194 | |========================== |
| 1195 | |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1196 | [[group-options-info]] |
| 1197 | GroupOptionsInfo |
| 1198 | ~~~~~~~~~~~~~~~~ |
| 1199 | Options of the group. |
| 1200 | |
| 1201 | [options="header",width="50%",cols="1,^1,5"] |
Edwin Kempin | f04fc9c | 2013-02-05 14:09:45 +0100 | [diff] [blame] | 1202 | |============================= |
| 1203 | |Field Name ||Description |
Edwin Kempin | f04fc9c | 2013-02-05 14:09:45 +0100 | [diff] [blame] | 1204 | |`visible_to_all`|not set if `false`| |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1205 | Whether the group is visible to all registered users. |
Edwin Kempin | f04fc9c | 2013-02-05 14:09:45 +0100 | [diff] [blame] | 1206 | |============================= |
Edwin Kempin | 987d543 | 2013-02-04 10:20:44 +0100 | [diff] [blame] | 1207 | |
Edwin Kempin | 1461c22 | 2013-02-11 08:41:08 +0100 | [diff] [blame] | 1208 | [[group-options-input]] |
| 1209 | GroupOptionsInput |
| 1210 | ~~~~~~~~~~~~~~~~~ |
| 1211 | New options for a group. |
| 1212 | |
| 1213 | [options="header",width="50%",cols="1,^1,5"] |
| 1214 | |============================= |
| 1215 | |Field Name ||Description |
| 1216 | |`visible_to_all`|not set if `false`| |
| 1217 | Whether the group is visible to all registered users. |
| 1218 | |============================= |
| 1219 | |
Sasa Zivkov | 737e0a3 | 2013-03-18 14:21:42 +0100 | [diff] [blame] | 1220 | [[members-input]] |
| 1221 | MembersInput |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 1222 | ~~~~~~~~~~~ |
Sasa Zivkov | 737e0a3 | 2013-03-18 14:21:42 +0100 | [diff] [blame] | 1223 | The `MembersInput` entity contains information about accounts that should |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 1224 | be added as members to a group or that should be deleted from the group. |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 1225 | |
| 1226 | [options="header",width="50%",cols="1,^1,5"] |
| 1227 | |========================== |
| 1228 | |Field Name ||Description |
| 1229 | |`_one_member`|optional| |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 1230 | The link:#account-id[id] of one account that should be added or |
| 1231 | deleted. |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 1232 | |`members` |optional| |
| 1233 | A list of link:#account-id[account ids] that identify the accounts that |
Edwin Kempin | acbdfd3 | 2013-02-07 12:38:53 +0100 | [diff] [blame] | 1234 | should be added or deleted. |
Edwin Kempin | 2cdef5f | 2013-02-06 16:50:15 +0100 | [diff] [blame] | 1235 | |========================== |
| 1236 | |
| 1237 | |
Edwin Kempin | d0a6392 | 2013-01-23 16:32:59 +0100 | [diff] [blame] | 1238 | GERRIT |
| 1239 | ------ |
| 1240 | Part of link:index.html[Gerrit Code Review] |