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>2021-06-29 15:08:48 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-06-29 15:08:48 +0300
commite5f2a04e9d54615fded2ca05d0d5eef464795a8f (patch)
tree5412fccdb0a63b449fba4d7998eaa05ca70091ba /doc/api/resource_access_tokens.md
parentad2789aeba21edaadcbdc06523462e6fd87d4ba1 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/api/resource_access_tokens.md')
-rw-r--r--doc/api/resource_access_tokens.md5
1 files changed, 3 insertions, 2 deletions
diff --git a/doc/api/resource_access_tokens.md b/doc/api/resource_access_tokens.md
index a134eb5adca..3532cfda47b 100644
--- a/doc/api/resource_access_tokens.md
+++ b/doc/api/resource_access_tokens.md
@@ -59,12 +59,13 @@ POST projects/:id/access_tokens
| `id` | integer or string | yes | The ID or [URL-encoded path of the project](index.md#namespaced-path-encoding) |
| `name` | String | yes | The name of the project access token |
| `scopes` | `Array[String]` | yes | [List of scopes](../user/project/settings/project_access_tokens.md#limiting-scopes-of-a-project-access-token) |
+| `access_level` | Integer | no | A valid access level. Default value is 40 (Maintainer). Other allowed values are 10 (Guest), 20 (Reporter), and 30 (Developer). |
| `expires_at` | Date | no | The token expires at midnight UTC on that date |
```shell
curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" \
--header "Content-Type:application/json" \
---data '{ "name":"test_token", "scopes":["api", "read_repository"], "expires_at":"2021-01-31" }' \
+--data '{ "name":"test_token", "scopes":["api", "read_repository"], "expires_at":"2021-01-31", "access_level": 30 }' \
"https://gitlab.example.com/api/v4/projects/<project_id>/access_tokens"
```
@@ -82,7 +83,7 @@ curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" \
"id" : 58,
"expires_at" : "2021-01-31",
"token" : "D4y...Wzr",
- "access_level": 40
+ "access_level": 30
}
```