3 Authentication is required and the user must be an admin.
5 The `/api/v1/pleroma/admin/*` path is backwards compatible with `/api/pleroma/admin/*` (`/api/pleroma/admin/*` will be deprecated in the future).
7 ## `GET /api/v1/pleroma/admin/users`
12 - *optional* `query`: **string** search term (e.g. nickname, domain, nickname@domain)
13 - *optional* `filters`: **string** comma-separated string of filters:
14 - `local`: only local users
15 - `external`: only external users
16 - `active`: only active users
17 - `need_approval`: only unapproved users
18 - `unconfirmed`: only unconfirmed users
19 - `deactivated`: only deactivated users
20 - `is_admin`: users with admin role
21 - `is_moderator`: users with moderator role
22 - *optional* `page`: **integer** page number
23 - *optional* `page_size`: **integer** number of users per page (default is `50`)
24 - *optional* `tags`: **[string]** tags list
25 - *optional* `actor_types`: **[string]** actor type list (`Person`, `Service`, `Application`)
26 - *optional* `name`: **string** user display name
27 - *optional* `email`: **string** user email
28 - Example: `https://mypleroma.org/api/v1/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`
47 "display_name": string,
48 "confirmation_pending": bool,
49 "approval_pending": bool,
50 "registration_reason": string,
57 ## DEPRECATED `DELETE /api/v1/pleroma/admin/users`
63 - Response: User’s nickname
65 ## `DELETE /api/v1/pleroma/admin/users`
71 - Response: Array of user nicknames
84 - Response: User’s nickname
86 ## `POST /api/v1/pleroma/admin/users/follow`
88 ### Make a user follow another user
91 - `follower`: The nickname of the follower
92 - `followed`: The nickname of the followed
96 ## `POST /api/v1/pleroma/admin/users/unfollow`
98 ### Make a user unfollow another user
101 - `follower`: The nickname of the follower
102 - `followed`: The nickname of the followed
106 ## `PATCH /api/v1/pleroma/admin/users/:nickname/toggle_activation`
108 ### Toggle user activation
112 - Response: User’s object
122 ## `PUT /api/v1/pleroma/admin/users/tag`
124 ### Tag a list of users
127 - `nicknames` (array)
130 ## `DELETE /api/v1/pleroma/admin/users/tag`
132 ### Untag a list of users
135 - `nicknames` (array)
138 ## `GET /api/v1/pleroma/admin/users/:nickname/permission_group`
140 ### Get user user permission groups membership
147 "is_moderator": bool,
152 ## `GET /api/v1/pleroma/admin/users/:nickname/permission_group/:permission_group`
154 Note: Available `:permission_group` is currently moderator and admin. 404 is returned when the permission group doesn’t exist.
156 ### Get user user permission groups membership per permission group
163 "is_moderator": bool,
168 ## DEPRECATED `POST /api/v1/pleroma/admin/users/:nickname/permission_group/:permission_group`
170 ### Add user to permission group
174 - On failure: `{"error": "…"}`
175 - On success: JSON of the user
177 ## `POST /api/v1/pleroma/admin/users/permission_group/:permission_group`
179 ### Add users to permission group
182 - `nicknames`: nicknames array
184 - On failure: `{"error": "…"}`
185 - On success: JSON of the user
187 ## DEPRECATED `DELETE /api/v1/pleroma/admin/users/:nickname/permission_group/:permission_group`
189 ## `DELETE /api/v1/pleroma/admin/users/:nickname/permission_group/:permission_group`
191 ### Remove user from permission group
195 - On failure: `{"error": "…"}`
196 - On success: JSON of the user
197 - Note: An admin cannot revoke their own admin status.
199 ## `DELETE /api/v1/pleroma/admin/users/permission_group/:permission_group`
201 ### Remove users from permission group
204 - `nicknames`: nicknames array
206 - On failure: `{"error": "…"}`
207 - On success: JSON of the user
208 - Note: An admin cannot revoke their own admin status.
210 ## `PATCH /api/v1/pleroma/admin/users/activate`
215 - `nicknames`: nicknames array
228 ## `PATCH /api/v1/pleroma/admin/users/deactivate`
233 - `nicknames`: nicknames array
246 ## `PATCH /api/v1/pleroma/admin/users/approve`
251 - `nicknames`: nicknames array
264 ## `GET /api/v1/pleroma/admin/users/:nickname_or_id`
266 ### Retrive the details of a user
271 - On failure: `Not found`
272 - On success: JSON of the user
274 ## `GET /api/v1/pleroma/admin/users/:nickname_or_id/statuses`
276 ### Retrive user's latest statuses
280 - *optional* `page_size`: number of statuses to return (default is `20`)
281 - *optional* `godmode`: `true`/`false` – allows to see private statuses
282 - *optional* `with_reblogs`: `true`/`false` – allows to see reblogs (default is false)
284 - On failure: `Not found`
285 - On success: JSON, where:
286 - `total`: total count of the statuses for the user
287 - `activities`: list of the statuses for the user
298 ## `GET /api/v1/pleroma/admin/instances/:instance/statuses`
300 ### Retrive instance's latest statuses
303 - `instance`: instance name
304 - *optional* `page_size`: number of statuses to return (default is `20`)
305 - *optional* `godmode`: `true`/`false` – allows to see private statuses
306 - *optional* `with_reblogs`: `true`/`false` – allows to see reblogs (default is false)
308 - On failure: `Not found`
309 - On success: JSON, where:
310 - `total`: total count of the statuses for the instance
311 - `activities`: list of the statuses for the instance
322 ## `GET /api/v1/pleroma/admin/statuses`
324 ### Retrives all latest statuses
327 - *optional* `page_size`: number of statuses to return (default is `20`)
328 - *optional* `local_only`: excludes remote statuses
329 - *optional* `godmode`: `true`/`false` – allows to see private statuses
330 - *optional* `with_reblogs`: `true`/`false` – allows to see reblogs (default is false)
332 - On failure: `Not found`
333 - On success: JSON array of user's latest statuses
335 ## `GET /api/v1/pleroma/admin/relay`
342 * On success: JSON array of relays
346 {"actor": "https://example.com/relay", "followed_back": true},
347 {"actor": "https://example2.com/relay", "followed_back": false}
351 ## `POST /api/v1/pleroma/admin/relay`
361 * On success: relay json object
364 {"actor": "https://example.com/relay", "followed_back": true}
367 ## `DELETE /api/v1/pleroma/admin/relay`
373 - *optional* `force`: forcefully unfollow a relay even when the relay is not available. (default is `false`)
377 * On success: URL of the unfollowed relay
380 {"https://example.com/relay"}
383 ## `POST /api/v1/pleroma/admin/users/invite_token`
385 ### Create an account registration invite token
388 - *optional* `max_use` (integer)
389 - *optional* `expires_at` (date string e.g. "2019-04-07")
400 "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
404 ## `GET /api/v1/pleroma/admin/users/invites`
406 ### Get a list of generated invites
422 "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
429 ## `POST /api/v1/pleroma/admin/users/revoke_invite`
431 ### Revoke invite by token
445 "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
450 ## `POST /api/v1/pleroma/admin/users/email_invite`
452 ### Sends registration invite via email
459 - On success: `204`, empty response
461 - 400 Bad Request, JSON:
466 "error": "Appropriate error message here"
471 ## `GET /api/v1/pleroma/admin/users/:nickname/password_reset`
473 ### Get a password reset token for a given nickname
481 "token": "base64 reset token",
482 "link": "https://pleroma.social/api/v1/pleroma/password_reset/url-encoded-base64-token"
486 ## `PATCH /api/v1/pleroma/admin/users/force_password_reset`
488 ### Force passord reset for a user with a given nickname
492 - Response: none (code `204`)
494 ## PUT `/api/v1/pleroma/admin/users/disable_mfa`
496 ### Disable mfa for user's account.
500 - Response: User’s nickname
502 ## `GET /api/v1/pleroma/admin/users/:nickname/credentials`
504 ### Get the user's email, password, display and settings-related fields
513 "actor_type": "Person",
514 "allow_following_move": true,
515 "avatar": "https://pleroma.social/media/7e8e7508fd545ef580549b6881d80ec0ff2c81ed9ad37b9bdbbdf0e0d030159d.jpg",
516 "background": "https://pleroma.social/media/4de34c0bd10970d02cbdef8972bef0ebbf55f43cadc449554d4396156162fe9a.jpg",
517 "banner": "https://pleroma.social/media/8d92ba2bd244b613520abf557dd448adcd30f5587022813ee9dd068945986946.jpg",
519 "default_scope": "public",
520 "discoverable": false,
521 "email": "user@example.com",
525 "value": "<a href=\"https://example.com\" rel=\"ugc\">https://example.com</a>"
528 "hide_favorites": false,
529 "hide_followers": false,
530 "hide_followers_count": false,
531 "hide_follows": false,
532 "hide_follows_count": false,
533 "id": "9oouHaEEUR54hls968",
536 "no_rich_text": true,
537 "pleroma_settings_store": {},
542 "value": "https://example.com"
546 "skip_thread_containment": false
550 ## `PATCH /api/v1/pleroma/admin/users/:nickname/credentials`
552 ### Change the user's email, password, display and settings-related fields
566 * `hide_followers_count`
567 * `hide_follows_count`
569 * `allow_following_move`
572 * `skip_thread_containment`
582 {"status": "success"}
589 {"actor_type": "is invalid"},
590 {"email": "has invalid format"},
598 {"error": "Not found"}
601 ## `GET /api/v1/pleroma/admin/reports`
603 ### Get a list of reports
606 - *optional* `state`: **string** the state of reports. Valid values are `open`, `closed` and `resolved`
607 - *optional* `limit`: **integer** the number of records to retrieve
608 - *optional* `page`: **integer** page number
609 - *optional* `page_size`: **integer** number of log entries per page (default is `50`)
611 - On failure: 403 Forbidden error `{"error": "error_msg"}` when requested by anonymous or non-admin
612 - On success: JSON, returns a list of reports, where:
613 - `account`: the user who has been reported
614 - `actor`: the user who has sent the report
615 - `statuses`: list of statuses that have been included to the report
624 "avatar": "https://pleroma.example.org/images/avi.png",
625 "avatar_static": "https://pleroma.example.org/images/avi.png",
627 "created_at": "2019-04-23T17:32:04.000Z",
628 "display_name": "User",
631 "followers_count": 1,
632 "following_count": 1,
633 "header": "https://pleroma.example.org/images/banner.png",
634 "header_static": "https://pleroma.example.org/images/banner.png",
635 "id": "9i6dAJqSGSKMzLG2Lo",
639 "confirmation_pending": false,
640 "hide_favorites": true,
641 "hide_followers": false,
642 "hide_follows": false,
644 "is_moderator": false,
653 "tags": ["force_unlisted"],
655 "url": "https://pleroma.example.org/users/user",
660 "avatar": "https://pleroma.example.org/images/avi.png",
661 "avatar_static": "https://pleroma.example.org/images/avi.png",
663 "created_at": "2019-03-28T17:36:03.000Z",
664 "display_name": "Roger Braun",
667 "followers_count": 1,
668 "following_count": 1,
669 "header": "https://pleroma.example.org/images/banner.png",
670 "header_static": "https://pleroma.example.org/images/banner.png",
671 "id": "9hEkA5JsvAdlSrocam",
675 "confirmation_pending": false,
676 "hide_favorites": false,
677 "hide_followers": false,
678 "hide_follows": false,
680 "is_moderator": false,
689 "tags": ["force_unlisted"],
691 "url": "https://pleroma.example.org/users/lain",
694 "content": "Please delete it",
695 "created_at": "2019-04-29T19:48:15.000Z",
696 "id": "9iJGOv1j8hxuw19bcm",
707 "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>",
708 "created_at": "2019-04-23T19:15:47.000Z",
711 "favourites_count": 0,
712 "id": "9i6mQ9uVrrOmOime8m",
713 "in_reply_to_account_id": null,
714 "in_reply_to_id": null,
716 "media_attachments": [],
720 "id": "9hEkA5JsvAdlSrocam",
721 "url": "https://pleroma.example.org/users/lain",
726 "id": "9i6dAJqSGSKMzLG2Lo",
727 "url": "https://pleroma.example.org/users/user",
735 "text/plain": "@lain click on my link https://www.google.com/"
737 "conversation_id": 28,
738 "in_reply_to_account_acct": null,
751 "uri": "https://pleroma.example.org/objects/8717b90f-8e09-4b58-97b0-e3305472b396",
752 "url": "https://pleroma.example.org/notice/9i6mQ9uVrrOmOime8m",
753 "visibility": "direct"
761 ## `GET /api/v1/pleroma/admin/grouped_reports`
763 ### Get a list of reports, grouped by status
766 - On success: JSON, returns a list of reports, where:
767 - `date`: date of the latest report
768 - `account`: the user who has been reported (see `/api/v1/pleroma/admin/reports` for reference)
769 - `status`: reported status (see `/api/v1/pleroma/admin/reports` for reference)
770 - `actors`: users who had reported this status (see `/api/v1/pleroma/admin/reports` for reference)
771 - `reports`: reports (see `/api/v1/pleroma/admin/reports` for reference)
776 "date": "2019-10-07T12:31:39.615149Z",
779 "actors": [{ ... }, { ... }],
785 ## `GET /api/v1/pleroma/admin/reports/:id`
787 ### Get an individual report
793 - 403 Forbidden `{"error": "error_msg"}`
794 - 404 Not Found `"Not found"`
795 - On success: JSON, Report object (see above)
797 ## `PATCH /api/v1/pleroma/admin/reports`
799 ### Change the state of one or multiple reports
806 `id`, // required, report id
807 `state` // required, the new state. Valid values are `open`, `closed` and `resolved`
815 - 400 Bad Request, JSON:
821 `error` // error message
826 - On success: `204`, empty response
828 ## `POST /api/v1/pleroma/admin/reports/:id/notes`
830 ### Create report note
833 - `id`: required, report id
834 - `content`: required, the message
837 - 400 Bad Request `"Invalid parameters"` when `status` is missing
838 - On success: `204`, empty response
840 ## `DELETE /api/v1/pleroma/admin/reports/:report_id/notes/:id`
842 ### Delete report note
845 - `report_id`: required, report id
846 - `id`: required, note id
849 - 400 Bad Request `"Invalid parameters"` when `status` is missing
850 - On success: `204`, empty response
852 ## `GET /api/v1/pleroma/admin/statuses/:id`
854 ### Show status by id
857 - `id`: required, status id
860 - 404 Not Found `"Not Found"`
861 - On success: JSON, Mastodon Status entity
863 ## `PUT /api/v1/pleroma/admin/statuses/:id`
865 ### Change the scope of an individual reported status
869 - `sensitive`: optional, valid values are `true` or `false`
870 - `visibility`: optional, valid values are `public`, `private` and `unlisted`
873 - 400 Bad Request `"Unsupported visibility"`
874 - 403 Forbidden `{"error": "error_msg"}`
875 - 404 Not Found `"Not found"`
876 - On success: JSON, Mastodon Status entity
878 ## `DELETE /api/v1/pleroma/admin/statuses/:id`
880 ### Delete an individual reported status
886 - 403 Forbidden `{"error": "error_msg"}`
887 - 404 Not Found `"Not found"`
888 - On success: 200 OK `{}`
890 ## `GET /api/v1/pleroma/admin/restart`
892 ### Restarts pleroma application
894 **Only works when configuration from database is enabled.**
899 - 400 Bad Request `"To use this endpoint you need to enable configuration from database."`
905 ## `GET /api/v1/pleroma/admin/need_reboot`
907 ### Returns the flag whether the pleroma should be restarted
911 - `need_reboot` - boolean
918 ## `GET /api/v1/pleroma/admin/config`
920 ### Get list of merged default settings with saved in database.
922 *If `need_reboot` is `true`, instance must be restarted, so reboot time settings can take effect.*
924 **Only works when configuration from database is enabled.**
927 - `only_db`: true (*optional*, get only saved in database settings)
930 - 400 Bad Request `"To use this endpoint you need to enable configuration from database."`
937 "key": "Pleroma.Upload",
945 ## `POST /api/v1/pleroma/admin/config`
947 ### Update config settings
949 *If `need_reboot` is `true`, instance must be restarted, so reboot time settings can take effect.*
951 **Only works when configuration from database is enabled.**
953 Some modifications are necessary to save the config settings correctly:
955 - strings which start with `Pleroma.`, `Phoenix.`, `Tesla.` or strings like `Oban`, `Ueberauth` will be converted to modules;
957 "Pleroma.Upload" -> Pleroma.Upload
960 - strings starting with `:` will be converted to atoms;
962 ":pleroma" -> :pleroma
964 - objects with `tuple` key and array value will be converted to tuples;
966 {"tuple": ["string", "Pleroma.Upload", []]} -> {"string", Pleroma.Upload, []}
968 - arrays with *tuple objects* will be converted to keywords;
970 [{"tuple": [":key1", "value"]}, {"tuple": [":key2", "value"]}] -> [key1: "value", key2: "value"]
973 Most of the settings will be applied in `runtime`, this means that you don't need to restart the instance. But some settings are applied in `compile time` and require a reboot of the instance, such as:
974 - all settings inside these keys:
976 - `:connections_pool`
979 - partially settings inside these keys:
980 - `:seconds_valid` in `Pleroma.Captcha`
981 - `:proxy_remote` in `Pleroma.Upload`
982 - `:upload_limit` in `:instance`
985 - `configs` - array of config objects
986 - config object params:
987 - `group` - string (**required**)
988 - `key` - string (**required**)
989 - `value` - string, [], {} or {"tuple": []} (**required**)
990 - `delete` - true (*optional*, if setting must be deleted)
991 - `subkeys` - array of strings (*optional*, only works when `delete=true` parameter is passed, otherwise will be ignored)
993 *When a value have several nested settings, you can delete only some nested settings by passing a parameter `subkeys`, without deleting all settings by key.*
995 [subkey: val1, subkey2: val2, subkey3: val3] \\ initial value
996 {"group": ":pleroma", "key": "some_key", "delete": true, "subkeys": [":subkey", ":subkey3"]} \\ passing json for deletion
997 [subkey2: val2] \\ value after deletion
1000 *Most of the settings can be partially updated through merge old values with new values, except settings value of which is list or is not keyword.*
1002 Example of setting without keyword in value:
1004 config :tesla, :adapter, Tesla.Adapter.Hackney
1007 List of settings which support only full update by key:
1010 {:pleroma, :ecto_repos},
1013 {:cors_plug, [:max_age, :methods, :expose, :headers]},
1014 {:auto_linker, :opts},
1015 {:swarm, :node_blacklist},
1016 {:logger, :backends}
1020 List of settings which support only full update by subkey:
1022 @full_subkey_update [
1023 {:pleroma, :assets, :mascots},
1024 {:pleroma, :emoji, :groups},
1025 {:pleroma, :workers, :retries},
1026 {:pleroma, :mrf_subchain, :match_actor},
1027 {:pleroma, :mrf_keyword, :replace}
1031 *Settings without explicit key must be sended in separate config object params.*
1041 {"group": ":quack", "key": ":level", "value": ":debug"},
1042 {"group": ":quack", "key": ":meta", "value": [":all"]},
1053 "group": ":pleroma",
1054 "key": "Pleroma.Upload",
1056 {"tuple": [":uploader", "Pleroma.Uploaders.Local"]},
1057 {"tuple": [":filters", ["Pleroma.Upload.Filter.Dedupe"]]},
1058 {"tuple": [":link_name", true]},
1059 {"tuple": [":proxy_remote", false]},
1060 {"tuple": [":proxy_opts", [
1061 {"tuple": [":redirect_on_failure", false]},
1062 {"tuple": [":max_body_length", 1048576]},
1063 {"tuple": [":http", [
1064 {"tuple": [":follow_redirect", true]},
1065 {"tuple": [":pool", ":upload"]},
1069 {"tuple": [":dispatch", {
1070 "tuple": ["/api/v1/streaming", "Pleroma.Web.MastodonAPI.WebsocketHandler", []]
1080 - 400 Bad Request `"To use this endpoint you need to enable configuration from database."`
1085 "group": ":pleroma",
1086 "key": "Pleroma.Upload",
1094 ## ` GET /api/v1/pleroma/admin/config/descriptions`
1096 ### Get JSON with config descriptions.
1097 Loads json generated from `config/descriptions.exs`.
1104 "group": ":pleroma", // string
1105 "key": "ModuleName", // string
1106 "type": "group", // string or list with possible values,
1107 "description": "Upload general settings", // string
1110 "key": ":uploader", // string or module name `Pleroma.Upload`
1112 "description": "Module which will be used for uploads",
1113 "suggestions": ["module1", "module2"]
1117 "type": ["list", "module"],
1118 "description": "List of filter modules for uploads",
1120 "module1", "module2", "module3"
1127 ## `GET /api/v1/pleroma/admin/moderation_log`
1129 ### Get moderation log
1132 - *optional* `page`: **integer** page number
1133 - *optional* `page_size`: **integer** number of log entries per page (default is `50`)
1134 - *optional* `start_date`: **datetime (ISO 8601)** filter logs by creation date, start from `start_date`. Accepts datetime in ISO 8601 format (YYYY-MM-DDThh:mm:ss), e.g. `2005-08-09T18:31:42`
1135 - *optional* `end_date`: **datetime (ISO 8601)** filter logs by creation date, end by from `end_date`. Accepts datetime in ISO 8601 format (YYYY-MM-DDThh:mm:ss), e.g. 2005-08-09T18:31:42
1136 - *optional* `user_id`: **integer** filter logs by actor's id
1137 - *optional* `search`: **string** search logs by the log message
1149 "action": "relay_follow"
1151 "time": 1502812026, // timestamp
1152 "message": "[2017-08-15 15:47:06] @nick0 followed relay: https://example.org/relay" // log message
1157 ## `POST /api/v1/pleroma/admin/reload_emoji`
1159 ### Reload the instance's custom emoji
1161 - Authentication: required
1163 - Response: JSON, "ok" and 200 status
1165 ## `PATCH /api/v1/pleroma/admin/users/confirm_email`
1167 ### Confirm users' emails
1171 - Response: Array of user nicknames
1173 ## `PATCH /api/v1/pleroma/admin/users/resend_confirmation_email`
1175 ### Resend confirmation email
1179 - Response: Array of user nicknames
1181 ## `GET /api/v1/pleroma/admin/stats`
1186 - *optional* `instance`: **string** instance hostname (without protocol) to get stats for
1187 - Example: `https://mypleroma.org/api/v1/pleroma/admin/stats?instance=lain.com`
1193 "status_visibility": {
1202 ## `GET /api/v1/pleroma/admin/oauth_app`
1208 - *optional* `client_id`
1210 - *optional* `page_size`
1211 - *optional* `trusted`
1221 "client_id": "yHoDSiWYp5mPV6AfsaVOWjdOyt5PhWRiafi6MRd1lSk",
1222 "client_secret": "nLmis486Vqrv2o65eM9mLQx_m_4gH-Q6PcDpGIMl6FY",
1223 "redirect_uri": "https://example.com/oauth-callback",
1224 "website": "https://example.com",
1234 ## `POST /api/v1/pleroma/admin/oauth_app`
1236 ### Create OAuth App
1242 - *optional* `website`
1243 - *optional* `trusted`
1251 "client_id": "yHoDSiWYp5mPV6AfsaVOWjdOyt5PhWRiafi6MRd1lSk",
1252 "client_secret": "nLmis486Vqrv2o65eM9mLQx_m_4gH-Q6PcDpGIMl6FY",
1253 "redirect_uri": "https://example.com/oauth-callback",
1254 "website": "https://example.com",
1262 "redirect_uris": "can't be blank",
1263 "name": "can't be blank"
1267 ## `PATCH /api/v1/pleroma/admin/oauth_app/:id`
1269 ### Update OAuth App
1273 - *optional* `redirect_uris`
1274 - *optional* `scopes`
1275 - *optional* `website`
1276 - *optional* `trusted`
1284 "client_id": "yHoDSiWYp5mPV6AfsaVOWjdOyt5PhWRiafi6MRd1lSk",
1285 "client_secret": "nLmis486Vqrv2o65eM9mLQx_m_4gH-Q6PcDpGIMl6FY",
1286 "redirect_uri": "https://example.com/oauth-callback",
1287 "website": "https://example.com",
1292 ## `DELETE /api/v1/pleroma/admin/oauth_app/:id`
1294 ### Delete OAuth App
1299 - On success: `204`, empty response
1301 - 400 Bad Request `"Invalid parameters"` when `status` is missing
1303 ## `GET /api/v1/pleroma/admin/media_proxy_caches`
1305 ### Get a list of all banned MediaProxy URLs in Cachex
1307 - Authentication: required
1309 - *optional* `page`: **integer** page number
1310 - *optional* `page_size`: **integer** number of log entries per page (default is `50`)
1311 - *optional* `query`: **string** search term
1317 "page_size": integer,
1320 "http://example.com/media/a688346.jpg",
1321 "http://example.com/media/fb1f4d.jpg"
1327 ## `POST /api/v1/pleroma/admin/media_proxy_caches/delete`
1329 ### Remove a banned MediaProxy URL from Cachex
1331 - Authentication: required
1342 ## `POST /api/v1/pleroma/admin/media_proxy_caches/purge`
1344 ### Purge a MediaProxy URL
1346 - Authentication: required
1358 ## GET /api/v1/pleroma/admin/users/:nickname/chats
1360 ### List a user's chats
1370 "id": "someflakeid",
1371 "username": "somenick",
1375 "id": "someflakeid",
1376 "username": "somenick",
1381 "last_message" : {...}, // The last message in that chat
1382 "updated_at": "2020-04-21T15:11:46.000Z"
1387 ## GET /api/v1/pleroma/admin/chats/:chat_id
1389 ### View a single chat
1398 "id": "someflakeid",
1399 "username": "somenick",
1403 "id": "someflakeid",
1404 "username": "somenick",
1409 "last_message" : {...}, // The last message in that chat
1410 "updated_at": "2020-04-21T15:11:46.000Z"
1414 ## GET /api/v1/pleroma/admin/chats/:chat_id/messages
1416 ### List the messages in a chat
1418 - Params: `max_id`, `min_id`
1425 "account_id": "someflakeid",
1427 "content": "Check this out :firefox:",
1428 "created_at": "2020-04-21T15:11:46.000Z",
1431 "shortcode": "firefox",
1432 "static_url": "https://dontbulling.me/emoji/Firefox.gif",
1433 "url": "https://dontbulling.me/emoji/Firefox.gif",
1434 "visible_in_picker": false
1441 "account_id": "someflakeid",
1443 "content": "Whats' up?",
1444 "created_at": "2020-04-21T15:06:45.000Z",
1452 ## DELETE /api/v1/pleroma/admin/chats/:chat_id/messages/:message_id
1454 ### Delete a single message
1462 "account_id": "someflakeid",
1464 "content": "Check this out :firefox:",
1465 "created_at": "2020-04-21T15:11:46.000Z",
1468 "shortcode": "firefox",
1469 "static_url": "https://dontbulling.me/emoji/Firefox.gif",
1470 "url": "https://dontbulling.me/emoji/Firefox.gif",
1471 "visible_in_picker": false
1479 ## `GET /api/v1/pleroma/admin/instance_document/:document_name`
1481 ### Get an instance document
1483 - Authentication: required
1487 Returns the content of the document
1490 <h1>Instance panel</h1>
1493 ## `PATCH /api/v1/pleroma/admin/instance_document/:document_name`
1495 - `file` (the file to be uploaded, using multipart form data.)
1497 ### Update an instance document
1499 - Authentication: required
1505 "url": "https://example.com/instance/panel.html"
1509 ## `DELETE /api/v1/pleroma/admin/instance_document/:document_name`
1511 ### Delete an instance document
1517 "url": "https://example.com/instance/panel.html"
1521 ## `GET /api/v1/pleroma/admin/frontends
1523 ### List available frontends
1530 "build_url": "https://git.pleroma.social/pleroma/fedi-fe/-/jobs/artifacts/${ref}/download?job=build",
1531 "git": "https://git.pleroma.social/pleroma/fedi-fe",
1537 "build_url": "https://git.pleroma.social/lambadalambda/kenoma/-/jobs/artifacts/${ref}/download?job=build",
1538 "git": "https://git.pleroma.social/lambadalambda/kenoma",
1546 ## `POST /api/v1/pleroma/admin/frontends/install`
1548 ### Install a frontend
1551 - `name`: frontend name, required
1552 - `ref`: frontend ref
1553 - `file`: path to a frontend zip file
1554 - `build_url`: build URL
1555 - `build_dir`: build directory
1562 "build_url": "https://git.pleroma.social/pleroma/fedi-fe/-/jobs/artifacts/${ref}/download?job=build",
1563 "git": "https://git.pleroma.social/pleroma/fedi-fe",
1569 "build_url": "https://git.pleroma.social/lambadalambda/kenoma/-/jobs/artifacts/${ref}/download?job=build",
1570 "git": "https://git.pleroma.social/lambadalambda/kenoma",
1580 "error": "Could not install frontend"