summaryrefslogtreecommitdiff
path: root/docs/api/admin_api.md
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2019-05-04 15:00:45 +0200
committerlain <lain@soykaf.club>2019-05-04 15:00:45 +0200
commit6ad8ddfd290f0239956874ccc9dc181167e84647 (patch)
tree83c5b59d055d3b98c1ebbba66351b7cbdb49bd99 /docs/api/admin_api.md
parent629ad1766ce5da434bf095f6baa81a460334e1b2 (diff)
parentd089ff24600455fefc17e91807c61ddc61ba107a (diff)
downloadpleroma-6ad8ddfd290f0239956874ccc9dc181167e84647.tar.gz
pleroma-6ad8ddfd290f0239956874ccc9dc181167e84647.zip
Merge remote-tracking branch 'origin/develop' into feature/bbs
Diffstat (limited to 'docs/api/admin_api.md')
-rw-r--r--docs/api/admin_api.md79
1 files changed, 76 insertions, 3 deletions
diff --git a/docs/api/admin_api.md b/docs/api/admin_api.md
index 53b68ffd4..8befa8ea0 100644
--- a/docs/api/admin_api.md
+++ b/docs/api/admin_api.md
@@ -58,6 +58,26 @@ Authentication is required and the user must be an admin.
- `password`
- Response: User’s nickname
+## `/api/pleroma/admin/user/follow`
+### Make a user follow another user
+
+- Methods: `POST`
+- Params:
+ - `follower`: The nickname of the follower
+ - `followed`: The nickname of the followed
+- Response:
+ - "ok"
+
+## `/api/pleroma/admin/user/unfollow`
+### Make a user unfollow another user
+
+- Methods: `POST`
+- Params:
+ - `follower`: The nickname of the follower
+ - `followed`: The nickname of the followed
+- Response:
+ - "ok"
+
## `/api/pleroma/admin/users/:nickname/toggle_activation`
### Toggle user activation
@@ -180,12 +200,65 @@ Note: Available `:permission_group` is currently moderator and admin. 404 is ret
## `/api/pleroma/admin/invite_token`
-### Get a account registeration invite token
+### Get an account registration invite token
- Methods: `GET`
-- Params: none
+- Params:
+ - *optional* `invite` => [
+ - *optional* `max_use` (integer)
+ - *optional* `expires_at` (date string e.g. "2019-04-07")
+ ]
- Response: invite token (base64 string)
+## `/api/pleroma/admin/invites`
+
+### Get a list of generated invites
+
+- Methods: `GET`
+- Params: none
+- Response:
+
+```JSON
+{
+
+ "invites": [
+ {
+ "id": integer,
+ "token": string,
+ "used": boolean,
+ "expires_at": date,
+ "uses": integer,
+ "max_use": integer,
+ "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
+ },
+ ...
+ ]
+}
+```
+
+## `/api/pleroma/admin/revoke_invite`
+
+### Revoke invite by token
+
+- Methods: `POST`
+- Params:
+ - `token`
+- Response:
+
+```JSON
+{
+ "id": integer,
+ "token": string,
+ "used": boolean,
+ "expires_at": date,
+ "uses": integer,
+ "max_use": integer,
+ "invite_type": string (possible values: `one_time`, `reusable`, `date_limited`, `reusable_date_limited`)
+
+}
+```
+
+
## `/api/pleroma/admin/email_invite`
### Sends registration invite via email
@@ -193,7 +266,7 @@ Note: Available `:permission_group` is currently moderator and admin. 404 is ret
- Methods: `POST`
- Params:
- `email`
- - `name`, optionnal
+ - `name`, optional
## `/api/pleroma/admin/password_reset`