summaryrefslogtreecommitdiff
path: root/doc/api/users.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/api/users.md')
-rw-r--r--doc/api/users.md25
1 files changed, 25 insertions, 0 deletions
diff --git a/doc/api/users.md b/doc/api/users.md
index 4e427766750..213d1865aca 100644
--- a/doc/api/users.md
+++ b/doc/api/users.md
@@ -164,6 +164,7 @@ the `group_saml` provider option:
...
}
]
+```
You can lookup users by external UID and provider:
@@ -592,6 +593,30 @@ Example responses
}
```
+## User counts
+
+Get the counts (same as in top right menu) of the currently signed in user.
+
+| Attribute | Type | Description |
+| --------- | ---- | ----------- |
+| `merge_requests` | number | Merge requests that are active and assigned to current user. |
+
+```
+GET /user_counts
+```
+
+```bash
+curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/user_counts"
+```
+
+Example response:
+
+```json
+{
+ "merge_requests": 4
+}
+```
+
## List user projects
Please refer to the [List of user projects](projects.md#list-user-projects).