summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/api/admin_api.md12
-rw-r--r--docs/api/pleroma_api.md32
2 files changed, 38 insertions, 6 deletions
diff --git a/docs/api/admin_api.md b/docs/api/admin_api.md
index fcdb33944..ee9e68cb1 100644
--- a/docs/api/admin_api.md
+++ b/docs/api/admin_api.md
@@ -312,8 +312,8 @@ Note: Available `:permission_group` is currently moderator and admin. 404 is ret
```json
{
- "token": "U13DX6muOvpRsj35_ij9wLxUbkU-eFvfKttxs6gIajo=", // password reset token (base64 string)
- "link": "https://pleroma.social/api/pleroma/password_reset/U13DX6muOvpRsj35_ij9wLxUbkU-eFvfKttxs6gIajo%3D"
+ "token": "base64 reset token",
+ "link": "https://pleroma.social/api/pleroma/password_reset/url-encoded-base64-token"
}
```
@@ -330,10 +330,10 @@ Note: Available `:permission_group` is currently moderator and admin. 404 is ret
### Get a list of reports
- Method `GET`
- Params:
- - `state`: optional, the state of reports. Valid values are `open`, `closed` and `resolved`
- - `limit`: optional, the number of records to retrieve
- - `since_id`: optional, returns results that are more recent than the specified id
- - `max_id`: optional, returns results that are older than the specified id
+ - *optional* `state`: **string** the state of reports. Valid values are `open`, `closed` and `resolved`
+ - *optional* `limit`: **integer** the number of records to retrieve
+ - *optional* `page`: **integer** page number
+ - *optional* `page_size`: **integer** number of log entries per page (default is `50`)
- Response:
- On failure: 403 Forbidden error `{"error": "error_msg"}` when requested by anonymous or non-admin
- On success: JSON, returns a list of reports, where:
diff --git a/docs/api/pleroma_api.md b/docs/api/pleroma_api.md
index ac5489aa3..41889a0ef 100644
--- a/docs/api/pleroma_api.md
+++ b/docs/api/pleroma_api.md
@@ -439,3 +439,35 @@ The status posting endpoint takes an additional parameter, `in_reply_to_conversa
* Params: None
* Response: the archive of the pack with a 200 status code, 403 if the pack is not set as shared,
404 if the pack does not exist
+
+## `GET /api/v1/pleroma/accounts/:id/scrobbles`
+### Requests a list of current and recent Listen activities for an account
+* Method `GET`
+* Authentication: not required
+* Params: None
+* Response: An array of media metadata entities.
+* Example response:
+```json
+[
+ {
+ "account": {...},
+ "id": "1234",
+ "title": "Some Title",
+ "artist": "Some Artist",
+ "album": "Some Album",
+ "length": 180000,
+ "created_at": "2019-09-28T12:40:45.000Z"
+ }
+]
+```
+
+## `POST /api/v1/pleroma/scrobble`
+### Creates a new Listen activity for an account
+* Method `POST`
+* Authentication: required
+* Params:
+ * `title`: the title of the media playing
+ * `album`: the album of the media playing [optional]
+ * `artist`: the artist of the media playing [optional]
+ * `length`: the length of the media playing [optional]
+* Response: the newly created media metadata entity representing the Listen activity