3 Authentication is required and the user must be an admin.
5 ## `/api/pleroma/admin/users`
11 - *optional* `query`: **string** search term (e.g. nickname, domain, nickname@domain)
12 - *optional* `filters`: **string** comma-separated string of filters:
13 - `local`: only local users
14 - `external`: only external users
15 - `active`: only active users
16 - `deactivated`: only deactivated users
17 - `is_admin`: users with admin role
18 - `is_moderator`: users with moderator role
19 - *optional* `page`: **integer** page number
20 - *optional* `page_size`: **integer** number of users per page (default is `50`)
21 - *optional* `tags`: **[string]** tags list
22 - *optional* `name`: **string** user display name
23 - *optional* `email`: **string** user email
24 - Example: `https://mypleroma.org/api/pleroma/admin/users?query=john&filters=local,active&page=1&page_size=10&tags[]=some_tag&tags[]=another_tag&name=display_name&email=email@example.com`
48 ## `/api/pleroma/admin/users`
55 - Response: User’s nickname
64 - Response: User’s nickname
66 ## `/api/pleroma/admin/users/follow`
67 ### Make a user follow another user
71 - `follower`: The nickname of the follower
72 - `followed`: The nickname of the followed
76 ## `/api/pleroma/admin/users/unfollow`
77 ### Make a user unfollow another user
81 - `follower`: The nickname of the follower
82 - `followed`: The nickname of the followed
86 ## `/api/pleroma/admin/users/:nickname/toggle_activation`
88 ### Toggle user activation
93 - Response: User’s object
103 ## `/api/pleroma/admin/users/tag`
105 ### Tag a list of users
109 - `nicknames` (array)
112 ### Untag a list of users
116 - `nicknames` (array)
119 ## `/api/pleroma/admin/users/:nickname/permission_group`
121 ### Get user user permission groups membership
129 "is_moderator": bool,
134 ## `/api/pleroma/admin/users/:nickname/permission_group/:permission_group`
136 Note: Available `:permission_group` is currently moderator and admin. 404 is returned when the permission group doesn’t exist.
138 ### Get user user permission groups membership per permission group
146 "is_moderator": bool,
151 ### Add user in permission group
156 - On failure: `{"error": "…"}`
157 - On success: JSON of the `user.info`
159 ### Remove user from permission group
164 - On failure: `{"error": "…"}`
165 - On success: JSON of the `user.info`
166 - Note: An admin cannot revoke their own admin status.
168 ## `/api/pleroma/admin/users/:nickname/activation_status`
170 ### Active or deactivate a user
175 - `status` BOOLEAN field, false value means deactivation.
177 ## `/api/pleroma/admin/users/:nickname`
179 ### Retrive the details of a user
185 - On failure: `Not found`
186 - On success: JSON of the user
188 ## `/api/pleroma/admin/relay`
196 - On success: URL of the followed relay
204 - On success: URL of the unfollowed relay
206 ## `/api/pleroma/admin/users/invite_token`
208 ### Get an account registration invite token
212 - *optional* `invite` => [
213 - *optional* `max_use` (integer)
214 - *optional* `expires_at` (date string e.g. "2019-04-07")
216 - Response: invite token (base64 string)
218 ## `/api/pleroma/admin/users/invites`
220 ### Get a list of generated invites
237 "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
244 ## `/api/pleroma/admin/users/revoke_invite`
246 ### Revoke invite by token
261 "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
267 ## `/api/pleroma/admin/users/email_invite`
269 ### Sends registration invite via email
276 ## `/api/pleroma/admin/users/:nickname/password_reset`
278 ### Get a password reset token for a given nickname
282 - Response: password reset token (base64 string)
284 ## `/api/pleroma/admin/reports`
285 ### Get a list of reports
288 - `state`: optional, the state of reports. Valid values are `open`, `closed` and `resolved`
289 - `limit`: optional, the number of records to retrieve
290 - `since_id`: optional, returns results that are more recent than the specified id
291 - `max_id`: optional, returns results that are older than the specified id
293 - On failure: 403 Forbidden error `{"error": "error_msg"}` when requested by anonymous or non-admin
294 - On success: JSON, returns a list of reports, where:
295 - `account`: the user who has been reported
296 - `actor`: the user who has sent the report
297 - `statuses`: list of statuses that have been included to the report
305 "avatar": "https://pleroma.example.org/images/avi.png",
306 "avatar_static": "https://pleroma.example.org/images/avi.png",
308 "created_at": "2019-04-23T17:32:04.000Z",
309 "display_name": "User",
312 "followers_count": 1,
313 "following_count": 1,
314 "header": "https://pleroma.example.org/images/banner.png",
315 "header_static": "https://pleroma.example.org/images/banner.png",
316 "id": "9i6dAJqSGSKMzLG2Lo",
320 "confirmation_pending": false,
321 "hide_favorites": true,
322 "hide_followers": false,
323 "hide_follows": false,
325 "is_moderator": false,
335 "url": "https://pleroma.example.org/users/user",
340 "avatar": "https://pleroma.example.org/images/avi.png",
341 "avatar_static": "https://pleroma.example.org/images/avi.png",
343 "created_at": "2019-03-28T17:36:03.000Z",
344 "display_name": "Roger Braun",
347 "followers_count": 1,
348 "following_count": 1,
349 "header": "https://pleroma.example.org/images/banner.png",
350 "header_static": "https://pleroma.example.org/images/banner.png",
351 "id": "9hEkA5JsvAdlSrocam",
355 "confirmation_pending": false,
356 "hide_favorites": false,
357 "hide_followers": false,
358 "hide_follows": false,
360 "is_moderator": false,
370 "url": "https://pleroma.example.org/users/lain",
373 "content": "Please delete it",
374 "created_at": "2019-04-29T19:48:15.000Z",
375 "id": "9iJGOv1j8hxuw19bcm",
386 "content": "<span class=\"h-card\"><a data-user=\"9hEkA5JsvAdlSrocam\" class=\"u-url mention\" href=\"https://pleroma.example.org/users/lain\">@<span>lain</span></a></span> click on my link <a href=\"https://www.google.com/\">https://www.google.com/</a>",
387 "created_at": "2019-04-23T19:15:47.000Z",
390 "favourites_count": 0,
391 "id": "9i6mQ9uVrrOmOime8m",
392 "in_reply_to_account_id": null,
393 "in_reply_to_id": null,
395 "media_attachments": [],
399 "id": "9hEkA5JsvAdlSrocam",
400 "url": "https://pleroma.example.org/users/lain",
405 "id": "9i6dAJqSGSKMzLG2Lo",
406 "url": "https://pleroma.example.org/users/user",
414 "text/plain": "@lain click on my link https://www.google.com/"
416 "conversation_id": 28,
417 "in_reply_to_account_acct": null,
430 "uri": "https://pleroma.example.org/objects/8717b90f-8e09-4b58-97b0-e3305472b396",
431 "url": "https://pleroma.example.org/notice/9i6mQ9uVrrOmOime8m",
432 "visibility": "direct"
440 ## `/api/pleroma/admin/reports/:id`
441 ### Get an individual report
447 - 403 Forbidden `{"error": "error_msg"}`
448 - 404 Not Found `"Not found"`
449 - On success: JSON, Report object (see above)
451 ## `/api/pleroma/admin/reports/:id`
452 ### Change the state of the report
456 - `state`: required, the new state. Valid values are `open`, `closed` and `resolved`
459 - 400 Bad Request `"Unsupported state"`
460 - 403 Forbidden `{"error": "error_msg"}`
461 - 404 Not Found `"Not found"`
462 - On success: JSON, Report object (see above)
464 ## `/api/pleroma/admin/reports/:id/respond`
465 ### Respond to a report
469 - `status`: required, the message
472 - 400 Bad Request `"Invalid parameters"` when `status` is missing
473 - 403 Forbidden `{"error": "error_msg"}`
474 - 404 Not Found `"Not found"`
475 - On success: JSON, created Mastodon Status entity
486 "content": "Your claim is going to be closed",
487 "created_at": "2019-05-11T17:13:03.000Z",
490 "favourites_count": 0,
491 "id": "9ihuiSL1405I65TmEq",
492 "in_reply_to_account_id": null,
493 "in_reply_to_id": null,
495 "media_attachments": [],
499 "id": "9i6dAJqSGSKMzLG2Lo",
500 "url": "https://pleroma.example.org/users/user",
505 "id": "9hEkA5JsvAdlSrocam",
506 "url": "https://pleroma.example.org/users/admin",
514 "text/plain": "Your claim is going to be closed"
516 "conversation_id": 35,
517 "in_reply_to_account_acct": null,
530 "uri": "https://pleroma.example.org/objects/cab0836d-9814-46cd-a0ea-529da9db5fcb",
531 "url": "https://pleroma.example.org/notice/9ihuiSL1405I65TmEq",
532 "visibility": "direct"
536 ## `/api/pleroma/admin/statuses/:id`
537 ### Change the scope of an individual reported status
541 - `sensitive`: optional, valid values are `true` or `false`
542 - `visibility`: optional, valid values are `public`, `private` and `unlisted`
545 - 400 Bad Request `"Unsupported visibility"`
546 - 403 Forbidden `{"error": "error_msg"}`
547 - 404 Not Found `"Not found"`
548 - On success: JSON, Mastodon Status entity
550 ## `/api/pleroma/admin/statuses/:id`
551 ### Delete an individual reported status
557 - 403 Forbidden `{"error": "error_msg"}`
558 - 404 Not Found `"Not found"`
559 - On success: 200 OK `{}`