diff options
author | Ariadne Conill <ariadne@dereferenced.org> | 2019-09-27 11:04:52 +0000 |
---|---|---|
committer | Ariadne Conill <ariadne@dereferenced.org> | 2019-09-30 10:39:17 +0000 |
commit | 5fd29edac47de145fb7025a99137a69072dca3bb (patch) | |
tree | 6acd4e6ed99afb24203b19fc610a6c50d7ce1be2 | |
parent | 90537f398160eddfb8033c1cdfe1acc21ee63c4a (diff) | |
download | pleroma-5fd29edac47de145fb7025a99137a69072dca3bb.tar.gz |
docs: add scrobble API description
-rw-r--r-- | docs/api/pleroma_api.md | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/docs/api/pleroma_api.md b/docs/api/pleroma_api.md index ac5489aa3..183cf8a28 100644 --- a/docs/api/pleroma_api.md +++ b/docs/api/pleroma_api.md @@ -439,3 +439,33 @@ 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/:uid/now-playing` +### 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 +[ + { + "id": "1234", + "title": "Some Title", + "artist": "Some Artist", + "album": "Some Album", + "length": 180000 + } +] +``` + +## `POST /api/v1/pleroma/now-playing` +### 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 |