Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'doc/api/group_relations_export.md')
-rw-r--r--doc/api/group_relations_export.md43
1 files changed, 30 insertions, 13 deletions
diff --git a/doc/api/group_relations_export.md b/doc/api/group_relations_export.md
index 3721e712dd9..8e8eb05b6b9 100644
--- a/doc/api/group_relations_export.md
+++ b/doc/api/group_relations_export.md
@@ -8,11 +8,13 @@ info: To determine the technical writer assigned to the Stage/Group associated w
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/59978) in GitLab 13.12.
-The group relations export API partially exports a group's structure as separate files for each top-level
+The group relations export API partially exports a group's structure as separate files for each
+top-level
relation (for example, milestones, boards, and labels).
The group relations export API is primarily used in
-[group migration by direct transfer](../user/group/import/index.md#migrate-groups-by-direct-transfer-recommended) and
+[group migration by direct transfer](../user/group/import/index.md#migrate-groups-by-direct-transfer-recommended)
+and
can't be used with the [group import and export API](group_import_export.md).
## Schedule new export
@@ -23,9 +25,10 @@ Start a new group relations export:
POST /groups/:id/export_relations
```
-| Attribute | Type | Required | Description |
-| --------- | -------------- | -------- | ---------------------------------------- |
+| Attribute | Type | Required | Description |
+|-----------|----------------|----------|--------------------------------------------------|
| `id` | integer/string | yes | ID of the group owned by the authenticated user. |
+| `batched` | boolean | no | Whether to export in batches. |
```shell
curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/1/export_relations"
@@ -45,9 +48,10 @@ View the status of the relations export:
GET /groups/:id/export_relations/status
```
-| Attribute | Type | Required | Description |
-| --------- | -------------- | -------- | ---------------------------------------- |
-| `id` | integer/string | yes | ID of the group owned by the authenticated user. |
+| Attribute | Type | Required | Description |
+|------------|----------------|----------|--------------------------------------------------|
+| `id` | integer/string | yes | ID of the group owned by the authenticated user. |
+| `relation` | string | no | Name of the project top-level relation to view. |
```shell
curl --request GET --header "PRIVATE-TOKEN: <your_access_token>" \
@@ -70,13 +74,24 @@ The status can be one of the following:
"relation": "badges",
"status": 1,
"error": null,
- "updated_at": "2021-05-04T11:25:20.423Z"
+ "updated_at": "2021-05-04T11:25:20.423Z",
+ "batched": true,
+ "batches": [
+ {
+ "status": 1,
+ "batch_number": 1,
+ "objects_count": 1,
+ "error": null,
+ "updated_at": "2021-05-04T11:25:20.423Z"
+ }
+ ]
},
{
"relation": "boards",
"status": 1,
"error": null,
- "updated_at": "2021-05-04T11:25:20.085Z"
+ "updated_at": "2021-05-04T11:25:20.085Z",
+ "batched": false
}
]
```
@@ -89,10 +104,12 @@ Download the finished relations export:
GET /groups/:id/export_relations/download
```
-| Attribute | Type | Required | Description |
-| --------------- | -------------- | -------- | ---------------------------------------- |
-| `id` | integer/string | yes | ID of the group owned by the authenticated user. |
-| `relation` | string | yes | Name of the group top-level relation to download. |
+| Attribute | Type | Required | Description |
+|----------------|----------------|----------|---------------------------------------------------|
+| `id` | integer/string | yes | ID of the group owned by the authenticated user. |
+| `relation` | string | yes | Name of the group top-level relation to download. |
+| `batched` | boolean | no | Whether the export is batched. |
+| `batch_number` | integer | no | Number of export batch to download. |
```shell
curl --header "PRIVATE-TOKEN: <your_access_token>" --remote-header-name \