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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-29 18:08:59 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-29 18:08:59 +0300
commit23288f62da73fb0e30d8e7ce306665e8fda1b932 (patch)
tree2baf1339e4d7c7c35d6b8a52cfb90597a5d4cdf1 /doc/api/merge_request_context_commits.md
parent7cc6872401eb487ed20dbb9d455f8bb9c97d9e39 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/api/merge_request_context_commits.md')
-rw-r--r--doc/api/merge_request_context_commits.md97
1 files changed, 97 insertions, 0 deletions
diff --git a/doc/api/merge_request_context_commits.md b/doc/api/merge_request_context_commits.md
new file mode 100644
index 00000000000..4b8edf657e4
--- /dev/null
+++ b/doc/api/merge_request_context_commits.md
@@ -0,0 +1,97 @@
+# Merge request context commits API
+
+## List MR context commits
+
+Get a list of merge request context commits.
+
+```
+GET /projects/:id/merge_requests/:merge_request_iid/context_commits
+```
+
+Parameters:
+
+- `id` (required) - The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user
+- `merge_request_iid` (required) - The internal ID of the merge request
+
+```json
+[
+ {
+ "id": "4a24d82dbca5c11c61556f3b35ca472b7463187e",
+ "short_id": "4a24d82d",
+ "created_at": "2017-04-11T10:08:59.000Z",
+ "parent_ids": null,
+ "title": "Update README.md to include `Usage in testing and development`",
+ "message": "Update README.md to include `Usage in testing and development`",
+ "author_name": "Luke \"Jared\" Bennett",
+ "author_email": "lbennett@gitlab.com",
+ "authored_date": "2017-04-11T10:08:59.000Z",
+ "committer_name": "Luke \"Jared\" Bennett",
+ "committer_email": "lbennett@gitlab.com",
+ "committed_date": "2017-04-11T10:08:59.000Z",
+ "author": null,
+ "author_gravatar_url": "https://www.gravatar.com/avatar/2acf1fb99417a2b3971def5a294abbeb?s=80&d=identicon",
+ "commit_url": "http://127.0.0.1:3000/gitlab-org/gitlab-test/commit/4a24d82dbca5c11c61556f3b35ca472b7463187e",
+ "commit_path": "/gitlab-org/gitlab-test/commit/4a24d82dbca5c11c61556f3b35ca472b7463187e",
+ "description_html": "",
+ "title_html": "Update README.md to include `Usage in testing and development`",
+ "signature_html": null,
+ "pipeline_status_path": null
+ }
+]
+```
+
+## Create MR context commits
+
+Create a list of merge request context commits.
+
+```
+POST /projects/:id/merge_requests/:merge_request_iid/context_commits
+```
+
+Parameters:
+
+- `id` (required) - The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user
+- `merge_request_iid` (required) - The internal ID of the merge request
+
+```
+POST /projects/:id/merge_requests/
+```
+
+| Attribute | Type | Required | Description |
+| --------- | ---- | -------- | ----------- |
+| `commits` | string array | yes | The context commits' sha |
+
+```json
+[
+ {
+ "id": "6d394385cf567f80a8fd85055db1ab4c5295806f",
+ "message": "Added contributing guide\n\nSigned-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>\n",
+ "parent_ids": [
+ "1a0b36b3cdad1d2ee32457c102a8c0b7056fa863"
+ ],
+ "authored_date": "2014-02-27T10:05:10.000+02:00",
+ "author_name": "Dmitriy Zaporozhets",
+ "author_email": "dmitriy.zaporozhets@gmail.com",
+ "committed_date": "2014-02-27T10:05:10.000+02:00",
+ "committer_name": "Dmitriy Zaporozhets",
+ "committer_email": "dmitriy.zaporozhets@gmail.com"
+ }
+]
+```
+
+## Delete MR context commits
+
+Delete a list of merge request context commits.
+
+```
+DELETE /projects/:id/merge_requests/:merge_request_iid/context_commits
+```
+
+Parameters:
+
+- `id` (required) - The ID or [URL-encoded path of the project](README.md#namespaced-path-encoding) owned by the authenticated user
+- `merge_request_iid` (required) - The internal ID of the merge request
+
+| Attribute | Type | Required | Description |
+| --------- | ---- | -------- | ----------- |
+| `commits` | string array | yes | The context commits' sha |