aboutsummaryrefslogtreecommitdiff
path: root/docs/API/admin_api.md
diff options
context:
space:
mode:
authorlain <lain@soykaf.club>2020-11-18 17:51:57 +0000
committerlain <lain@soykaf.club>2020-11-18 17:51:57 +0000
commit6b32e1de234a84d0bdbbee5eeb5b2a543f24ce6b (patch)
tree7507fbe9289a9e4d686e9d65e3e21fb643ece07e /docs/API/admin_api.md
parentfe7008ee395a5275d8d20326ced226eec6db2a6a (diff)
parentd7b63272b8fb0028c9ce45a29ca9a569e5974c87 (diff)
downloadpleroma-6b32e1de234a84d0bdbbee5eeb5b2a543f24ce6b.tar.gz
Merge branch 'frontend-admin-api' into 'develop'
Add an API to manage frontends Closes #2238 See merge request pleroma/pleroma!3108
Diffstat (limited to 'docs/API/admin_api.md')
-rw-r--r--docs/API/admin_api.md63
1 files changed, 63 insertions, 0 deletions
diff --git a/docs/API/admin_api.md b/docs/API/admin_api.md
index f7b5bcae7..19ac6a65f 100644
--- a/docs/API/admin_api.md
+++ b/docs/API/admin_api.md
@@ -1499,3 +1499,66 @@ Returns the content of the document
"url": "https://example.com/instance/panel.html"
}
```
+
+## `GET /api/pleroma/admin/frontends
+
+### List available frontends
+
+- Response:
+
+```json
+[
+ {
+ "build_url": "https://git.pleroma.social/pleroma/fedi-fe/-/jobs/artifacts/${ref}/download?job=build",
+ "git": "https://git.pleroma.social/pleroma/fedi-fe",
+ "installed": true,
+ "name": "fedi-fe",
+ "ref": "master"
+ },
+ {
+ "build_url": "https://git.pleroma.social/lambadalambda/kenoma/-/jobs/artifacts/${ref}/download?job=build",
+ "git": "https://git.pleroma.social/lambadalambda/kenoma",
+ "installed": false,
+ "name": "kenoma",
+ "ref": "master"
+ }
+]
+```
+
+## `POST /api/pleroma/admin/frontends/install`
+
+### Install a frontend
+
+- Params:
+ - `name`: frontend name, required
+ - `ref`: frontend ref
+ - `file`: path to a frontend zip file
+ - `build_url`: build URL
+ - `build_dir`: build directory
+
+- Response:
+
+```json
+[
+ {
+ "build_url": "https://git.pleroma.social/pleroma/fedi-fe/-/jobs/artifacts/${ref}/download?job=build",
+ "git": "https://git.pleroma.social/pleroma/fedi-fe",
+ "installed": true,
+ "name": "fedi-fe",
+ "ref": "master"
+ },
+ {
+ "build_url": "https://git.pleroma.social/lambadalambda/kenoma/-/jobs/artifacts/${ref}/download?job=build",
+ "git": "https://git.pleroma.social/lambadalambda/kenoma",
+ "installed": false,
+ "name": "kenoma",
+ "ref": "master"
+ }
+]
+```
+
+```json
+{
+ "error": "Could not install frontend"
+}
+```