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/users.md')
-rw-r--r--doc/api/users.md28
1 files changed, 27 insertions, 1 deletions
diff --git a/doc/api/users.md b/doc/api/users.md
index 925563aeb1f..de9af59de93 100644
--- a/doc/api/users.md
+++ b/doc/api/users.md
@@ -603,7 +603,7 @@ Parameters:
"avatar_url": "http://localhost:3000/uploads/user/avatar/1/index.jpg",
"web_url": "http://localhost:3000/john_smith",
"created_at": "2012-05-23T08:00:58Z",
- "is_admin": false,
+ "is_admin": true,
"bio": "",
"location": null,
"public_email": "john@example.com",
@@ -958,6 +958,32 @@ Parameters:
}
```
+## Single SSH key for given user
+
+> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/81790) in GitLab 14.9.
+
+Get a single key for a given user.
+
+```plaintext
+GET /users/:id/keys/:key_id
+```
+
+Parameters:
+
+| Attribute | Type | Required | Description |
+|-----------|---------|----------|----------------------|
+| `id` | integer | yes | ID of specified user |
+| `key_id` | integer | yes | SSH key ID |
+
+```json
+{
+ "id": 1,
+ "title": "Public key",
+ "key": "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAiPWx6WM4lhHNedGfBpPJNPpZ7yKu+dnn1SJejgt4596k6YjzGGphH2TUxwKzxcKDKKezwkpfnxPkSMkuEspGRt/aZZ9wa++Oi7Qkr8prgHc4soW6NUlfDzpvZK2H5E7eQaSeP3SAwGmQKUFHCddNaP0L+hM7zhFNzjFvpaMgJw0=",
+ "created_at": "2014-08-01T14:47:39.080Z"
+}
+```
+
## Add SSH key
Creates a new key owned by the currently authenticated user.