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-05-29 00:08:22 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-05-29 00:08:22 +0300
commitd7b136d5471b5925ff784f78b9c11ec63c2a3549 (patch)
tree6c4417fb367459613e84a2d34625abccd13e6405 /doc/api/oauth2.md
parent1ec60cf53bc498b12c597ff0d91434a1bdb7cba9 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/api/oauth2.md')
-rw-r--r--doc/api/oauth2.md7
1 files changed, 6 insertions, 1 deletions
diff --git a/doc/api/oauth2.md b/doc/api/oauth2.md
index 0bf7ae399f0..cc8b31ecf17 100644
--- a/doc/api/oauth2.md
+++ b/doc/api/oauth2.md
@@ -173,11 +173,14 @@ the following parameters:
}
```
+Also you must use HTTP Basic authentication using the `client_id` and`client_secret`
+values to authenticate the client that performs a request.
+
Example cURL request:
```shell
echo 'grant_type=password&username=<your_username>&password=<your_password>' > auth.txt
-curl --data "@auth.txt" --request POST "https://gitlab.example.com/oauth/token"
+curl --data "@auth.txt" --user client_id:client_secret --request POST "https://gitlab.example.com/oauth/token"
```
Then, you'll receive the access token back in the response:
@@ -190,6 +193,8 @@ Then, you'll receive the access token back in the response:
}
```
+By default, the scope of the access token is `api`, which provides complete read/write access.
+
For testing, you can use the `oauth2` Ruby gem:
```ruby