2021-02-06 03:49:02 +00:00
asyncapi : 2.0 .0
info :
title : Lemmy WebSocket API
version : '2.0'
2021-02-17 15:47:42 +00:00
contact :
name : Mastodon
url : https://mastodon.social/@LemmyDev
2021-02-06 03:49:02 +00:00
description : |-
### About Lemmy
[ **Lemmy**](https://github.com/LemmyNet/lemmy) is a decentralized alternative to widely-used proprietary link aggregators like Reddit.
2021-02-19 13:32:34 +00:00
### How to use this WebSocket API document
2021-02-06 03:49:02 +00:00
You can either use it to :
- **Interactively browse the WebSocket API.** Browse the *Channels*, check out the responses and examples (tailor the *PUBLISH* requests to suit with your favorite WebSocket API client). For testing purposes, either [set up your own server](https://lemmy.ml/docs/en/administration/administration.html) or use the Enterprise server (*ws://enterprise.lemmy.ml/api/v2/ws*)
- **[Open and save](asyncapi.yaml) this specification file** and use it with the various [AsyncAPI tools](https://www.asyncapi.com/docs/community/tooling) (perhaps to generate code or documentation).
2021-02-10 13:35:06 +00:00
### The HTTP API
2021-02-17 15:47:42 +00:00
Lemmy also has an HTTP API. The WebSocket and HTTP API are almost identical :
2021-02-10 13:35:06 +00:00
- WebSocket API needs `let send = { op: userOperation[op], data: form}` as shown below
- HTTP API requires the form at the top level and an HTTP operation (GET, PUT or POST) and endpoint. For example : `PUT /comment`. For more information, see [http.ts](https://github.com/LemmyNet/lemmy-js-client/blob/main/src/http.ts)
2021-02-06 03:49:02 +00:00
license :
name : AGPL
url : 'https://www.gnu.org/licenses/agpl-3.0.en.html'
servers :
2021-02-17 15:47:42 +00:00
ds9 :
2021-02-10 13:35:06 +00:00
url : ds9.lemmy.ml/api/v2/ws
protocol : WebSocket
description : DS9 test server
enterprise :
2021-02-06 03:49:02 +00:00
url : enterprise.lemmy.ml/api/v2/ws
2021-02-10 13:35:06 +00:00
protocol : WebSocket
description : Enterprise test server
2021-02-17 15:47:42 +00:00
voyager :
2021-02-10 13:35:06 +00:00
url : voyager.lemmy.ml/api/v2/ws
protocol : WebSocket
description : Voyager test server
2021-02-06 03:49:02 +00:00
local :
url : localhost:1235/api/v2/ws
2021-02-10 13:35:06 +00:00
protocol : WebSocket
2021-02-06 03:49:02 +00:00
description : Local Docker container
externalDocs :
description : Lemmy documentation
url : 'https://lemmy.ml/docs/index.html'
tags :
- name : User, authentication and admin
2021-02-10 13:35:06 +00:00
- name : Site
2021-02-16 10:58:06 +00:00
- name : Community
2021-02-17 15:47:42 +00:00
- name : Post
2021-02-19 13:32:34 +00:00
- name : Comments
2021-02-06 03:49:02 +00:00
channels :
Login :
publish :
2021-02-10 13:35:06 +00:00
summary : Login (request)
description : |-
Login with username or registered email.
#### HTTP API - operation and endpoint.
`POST /user/login`
2021-02-06 03:49:02 +00:00
operationId : loginRequestMessage
tags :
- name : User, authentication and admin
message :
$ref : '#/components/messages/loginRequest'
subscribe :
2021-02-10 13:35:06 +00:00
summary : Login (response)
2021-02-23 14:49:01 +00:00
description : Returns an authentication string (`jwt`) for the supplied username or emal
2021-02-06 03:49:02 +00:00
operationId : loginResponseMessage
tags :
- name : User, authentication and admin
message :
2021-02-10 13:35:06 +00:00
oneOf :
- $ref : '#/components/messages/loginResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-06 03:49:02 +00:00
GetCaptcha :
publish :
2021-02-10 13:35:06 +00:00
summary : GetCaptcha (request)
description : |-
Get Captcha details for registering a user. These details expire after 10 minutes.
#### HTTP API - operation and endpoint.
`GET /user/get_captcha`
2021-02-06 03:49:02 +00:00
operationId : getCaptchaRequestMessage
tags :
- name : User, authentication and admin
message :
$ref : '#/components/messages/getCaptchaRequest'
subscribe :
2021-02-10 13:35:06 +00:00
summary : GetCaptcha (response)
description : Captcha details returned from the server
2021-02-06 03:49:02 +00:00
operationId : getCaptchaResponseMessage
tags :
- name : User, authentication and admin
message :
2021-02-10 13:35:06 +00:00
oneOf :
- $ref : '#/components/messages/getCaptchaResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-06 03:49:02 +00:00
Register :
publish :
2021-02-10 13:35:06 +00:00
summary : Register (request)
description : |-
Register a user on the Lemmy server. If Captcha is enabled on the server, obtain those details by using **GetCaptcha** (*before* attempting to register)
#### HTTP API - operation and endpoint.
`POST /user/register`
2021-02-06 03:49:02 +00:00
operationId : registerRequestMessage
tags :
- name : User, authentication and admin
message :
$ref : '#/components/messages/registerRequest'
subscribe :
2021-02-10 13:35:06 +00:00
summary : Register (response)
description : 'The response to the registration request will be an authentication string (`jwt`) for that user'
2021-02-06 03:49:02 +00:00
operationId : registerResponseMessage
tags :
- name : User, authentication and admin
message :
$ref : '#/components/messages/registerResponse'
GetUserDetails :
publish :
2021-02-10 13:35:06 +00:00
summary : GetUserDetails (request)
2021-02-06 03:49:02 +00:00
description : |-
2021-02-10 13:35:06 +00:00
- Use the `username` field to return details about a local user
2021-02-23 14:38:17 +00:00
- Use the `user_id` field to return details about a federated user.
2021-02-10 13:35:06 +00:00
#### HTTP API - operation and endpoint.
2021-02-06 03:49:02 +00:00
2021-02-10 13:35:06 +00:00
`GET /user`
2021-02-06 03:49:02 +00:00
operationId : getUserDetailsMessage
tags :
- name : User, authentication and admin
message :
$ref : '#/components/messages/getUserDetailsRequest'
subscribe :
2021-02-10 13:35:06 +00:00
summary : GetUserDetails (response)
description : Returns full details about a specified user (including the last post the user wrote)
2021-02-06 03:49:02 +00:00
operationId : getUserDetailsResponseMessage
tags :
- name : User, authentication and admin
message :
2021-02-10 13:35:06 +00:00
oneOf :
- $ref : '#/components/messages/getUserDetailsResponse'
- $ref : '#/components/messages/errorResponse'
SaveUserSettings :
publish :
summary : SaveUserSettings (request)
description : |-
Set profile for an existing user.
If you want to set a new password, you *must* provide **old_password**.
#### HTTP API - operation and endpoint.
`PUT /user/save_user_settings`
operationId : saverUserSettingsRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/saveUserSettingsRequest'
subscribe :
summary : SaveUserSettings (response)
description : Get details about a specified user
operationId : saveUserSettingsResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/saveUserSettingsResponse'
- $ref : '#/components/messages/errorResponse'
GetReplies :
publish :
summary : GetReplies (request)
description : |-
See all notifications and comments on all a user's posts
#### HTTP API - operation and endpoint.
`GET /user/replies`
operationId : getUserRepliesRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/getUserRepliesRequest'
subscribe :
summary : GetReplies (response)
description : Returns detailed reply data
operationId : getRepliesResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/repliesResponse'
- $ref : '#/components/messages/errorResponse'
GetUserMentions :
publish :
summary : GetUserMentions (request)
description : |-
Return any @ mentions of the user in posts and comments
#### HTTP API - operation and endpoint.
`GET /user/mention`
operationId : getUserMentionsRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/getUserMentionsRequest'
subscribe :
summary : GetUserMentions (response)
description : Returns detailed data about mentions
operationId : getMentionsResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/mentionsResponse'
- $ref : '#/components/messages/errorResponse'
MarkUserMentionAsRead :
publish :
summary : MarkUserMentionAsRead (request)
description : |-
Mark a specified mention as read. Only the recipient of a mention can do this.
#### HTTP API - operation and endpoint.
`POST /user/mention/mark_as_read`
operationId : markMentionsRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/markMentionsRequest'
subscribe :
summary : MarkUserMentionAsRead (response)
description : Returns detailed data about the mention
operationId : markMentionResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/markMentionResponse'
- $ref : '#/components/messages/errorResponse'
GetPrivateMessages :
publish :
summary : GetPrivateMessages (request)
description : |-
Request a list of messages sent to the user.
#### HTTP API - operation and endpoint.
`GET /private_message/list`
operationId : getPrivateMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/privateMessageRequest'
subscribe :
summary : GetPrivateMessages (response)
description : Returns list of messages
operationId : getMessagesResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/privateMessagesResponse'
- $ref : '#/components/messages/errorResponse'
CreatePrivateMessage :
publish :
summary : CreatePrivateMessage (request)
description : |-
Send a private message to another user.
#### HTTP API - operation and endpoint.
`POST /private_message`
operationId : createPrivateMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/createPrivateMessageRequest'
subscribe :
summary : CreatePrivateMessage (response)
description : Confirm sending of a private message
operationId : createPrivateMessageResponse
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/createPrivateMessageResponse'
- $ref : '#/components/messages/errorResponse'
EditPrivateMessage :
publish :
summary : EditPrivateMessage (request)
description : |-
Replace an existing private message with the provided content.
#### HTTP API - operation and endpoint.
`PUT /private_message`
operationId : editPrivateMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/editPrivateMessageRequest'
subscribe :
summary : EditPrivateMessage (response)
description : Confirm replacement of a private message
operationId : editPrivateMessageResponse
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/editPrivateMessageResponse'
- $ref : '#/components/messages/errorResponse'
DeletePrivateMessage :
publish :
summary : DeletePrivateMessage (request)
description : |-
Delete a specified private message.
#### HTTP API - operation and endpoint.
`POST /private_message/delete`
operationId : deletePrivateMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/deletePrivateMessageRequest'
subscribe :
summary : DeletePrivateMessage (response)
description : Confirm deletion of a private message
operationId : deletePrivateMessageResponse
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/deletePrivateMessageResponse'
- $ref : '#/components/messages/errorResponse'
MarkPrivateMessageAsRead :
publish :
summary : MarkPrivateMessageAsRead (request)
description : |-
Mark a specified private message as read. Only the recipient of a message can do this.
#### HTTP API - operation and endpoint.
`POST /private_message/mark_as_read`
operationId : markPrivateMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/markPrivateMessageRequest'
subscribe :
summary : MarkPrivateMessageAsRead (response)
description : 'Confirm that a private message has been marked as *read*'
operationId : markPrivateMessageResponse
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/markPrivateMessageResponse'
- $ref : '#/components/messages/errorResponse'
MarkAllAsRead :
publish :
summary : MarkAllAsRead (request)
description : |-
Marks all user replies and mentions as read.
#### HTTP API - operation and endpoint.
`POST /user/mark_all_as_read`
operationId : markAllReadMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/markAllReadRequest'
subscribe :
summary : MarkAllAsRead (response)
description : 'Confirm that all replies and mentions have been marked as *read*'
operationId : markAllReadResponse
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/markAllReadResponse'
- $ref : '#/components/messages/errorResponse'
DeleteAccount :
publish :
summary : DeleteAccount (request)
description : |-
Deletes user account and permanently deletes that user's posts and comments.
#### HTTP API - operation and endpoint.
`POST /user/delete_account`
operationId : deleteAccountRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/deleteAccountRequest'
subscribe :
summary : DeleteAccount (response)
description : Confirm that the account has been deleted
operationId : deleteAccountResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/deleteAccountResponse'
- $ref : '#/components/messages/errorResponse'
AddAdmin :
publish :
summary : AddAdmin (request)
description : |-
Grant admin rights to the specified user.
2021-02-17 15:47:42 +00:00
2021-02-10 13:35:06 +00:00
Only admin users can do this - `auth` must be the authentication string for an existing admin user.
#### HTTP API - operation and endpoint.
`POST /admin/add`
operationId : addAdminRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/addAdminRequest'
subscribe :
summary : AddAdmin (response)
description : Confirm that the user has been given admin privileges
operationId : addAdminResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/addAdminResponse'
- $ref : '#/components/messages/errorResponse'
BanUser :
publish :
summary : BanUser (request)
description : |-
Ban user from posting, commenting or adding communities. Optionally, remove all comments, posts and communities at the same time.
Only admin users can do this - `auth` must be the authentication string for an existing admin user.
#### HTTP API - operation and endpoint.
`POST /user/ban`
operationId : banUserRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/banUserRequest'
subscribe :
summary : BanUser (response)
description : Confirm that the user has been banned
operationId : banUserResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/banUserResponse'
- $ref : '#/components/messages/errorResponse'
UserJoin :
publish :
summary : UserJoin (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /user/join`
operationId : userJoinRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/userJoinRequest'
subscribe :
summary : UserJoin (response)
description : Forthcoming...
operationId : userJoinResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/userJoinResponse'
- $ref : '#/components/messages/errorResponse'
GetReportCount :
publish :
summary : GetReportCount (request)
description : |-
- If `community` is specified, returns the *report count* (number of posts and comments) for that community
- If it is not specified, returns the report count for all communities the user moderates.
User must either be a moderator of a community or an admin user.
#### HTTP API - operation and endpoint.
`GET /user/report_count`
operationId : getReportCountRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : User, authentication and admin
message :
$ref : '#/components/messages/getReportCountRequest'
subscribe :
summary : GetReportCount (response)
description : |-
Report on the number of posts and comments in one or all of the user's communities
operationId : getReportCountResponseMessage
tags :
- name : User, authentication and admin
message :
oneOf :
- $ref : '#/components/messages/getReportCountResponse'
- $ref : '#/components/messages/errorResponse'
ListCategories :
publish :
summary : ListCategories (request)
description : |-
List all community categories.
#### HTTP API - operation and endpoint.
`GET /categories`
operationId : getCategoriesMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/getCategoriesRequest'
subscribe :
summary : ListCategories (response)
description : List all options for community categories
operationId : getCategoriesResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/getCategoriesResponse'
- $ref : '#/components/messages/errorResponse'
Search :
publish :
summary : Search (request)
description : |-
Find comments, posts, communities users and links.
#### HTTP API - operation and endpoint.
`GET /search`
operationId : searchMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/searchRequest'
subscribe :
summary : Search (response)
description : Search results
operationId : searchResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/searchResponse'
- $ref : '#/components/messages/errorResponse'
GetModLog :
publish :
summary : GetModLog (request)
description : |-
2021-02-16 10:58:06 +00:00
Details of the site's *Modlog* : sticky and lockwed posts and so on.
2021-02-10 13:35:06 +00:00
#### HTTP API - operation and endpoint.
`GET /modlog`
operationId : getmodLogRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/getModLogRequest'
2021-02-16 10:58:06 +00:00
subscribe :
summary : GetModLog (response)
description : Modlog request results
operationId : getModLogResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/getModLogResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-10 13:35:06 +00:00
CreateSite :
publish :
summary : CreateSite (request)
description : |-
Creates a site on a 'virgin' server (that is one that does't have Lemmy installed on it already)
#### HTTP API - operation and endpoint.
`POST /site`
operationId : createSiteRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/createSiteRequest'
2021-02-23 14:38:17 +00:00
subscribe :
summary : CreateSite (response)
description : Returns site details
operationId : createSiteResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/createSiteResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-10 13:35:06 +00:00
EditSite :
publish :
summary : EditSite (Request)
description : |-
Change the name and, optionally other details of the Lemmy site.
Only admin users can do this - `auth` must be the authentication string for an existing admin user.
#### HTTP API - operation and endpoint.
`PUT /site`
operationId : editSiteRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
2021-02-17 15:47:42 +00:00
$ref : '#/components/messages/editSiteRequest'
2021-02-10 13:35:06 +00:00
subscribe :
summary : EditSite (response)
description : Returns confirmation of site edit
operationId : editSiteResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/editSiteResponse'
- $ref : '#/components/messages/errorResponse'
GetSite :
publish :
summary : GetSite (request)
description : |-
Get the basic details of the Lemmy site, assoicated with the authentication string `auth`
#### HTTP API - operation and endpoint.
`GET /site`
operationId : getSiteRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
2021-02-17 15:47:42 +00:00
$ref : '#/components/messages/getSiteRequest'
2021-02-10 13:35:06 +00:00
subscribe :
summary : GetSite (response)
description : Return full details about the site
operationId : getSiteResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/getSiteResponse'
- $ref : '#/components/messages/errorResponse'
TransferSite :
publish :
summary : TransferSite (request)
description : |-
Transfer ownership of the site from one admin user (`auth`) to another (`user_id`)
#### HTTP API - operation and endpoint.
`POST /site/transfer`
operationId : transferSiteRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/transferSiteRequest'
subscribe :
summary : TransferSite (response)
description : Return full details about the site
operationId : transferSiteResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/transferSiteResponse'
- $ref : '#/components/messages/errorResponse'
GetSiteConfig :
publish :
summary : GetSiteConfig (request)
description : |-
Request the configuration data file for a Lemmy server
#### HTTP API - operation and endpoint.
`GET /site/config`
operationId : getSiteConfigRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/getSiteConfigRequest'
subscribe :
summary : GetSiteConfig (response)
description : Return the configuration data for a Lemmy server
operationId : getSiteConfigResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/getSiteConfigResponse'
- $ref : '#/components/messages/errorResponse'
SaveSiteConfig :
publish :
summary : SaveSiteConfig (request)
description : |-
Request to send configuration data to a Lemmy server
#### HTTP API - operation and endpoint.
`PUT /site/config`
operationId : saveSiteConfigRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-10 13:35:06 +00:00
- name : Site
message :
$ref : '#/components/messages/saveSiteConfigRequest'
subscribe :
summary : SaveSiteConfig (response)
description : Return the configuration data file for a Lemmy server
operationId : saveSiteConfigResponseMessage
tags :
- name : Site
message :
oneOf :
- $ref : '#/components/messages/saveSiteConfigResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-16 10:58:06 +00:00
GetCommunity :
publish :
summary : GetCommunity (request)
description : |-
Request to get details of a specified community
#### HTTP API - operation and endpoint.
`GET /community`
operationId : getCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/getCommunityRequest'
subscribe :
summary : GetCommunity (response)
description : Return the details for a community
operationId : getCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/getCommunityResponse'
- $ref : '#/components/messages/errorResponse'
CreateCommunity :
publish :
summary : CreateCommunity (request)
description : |-
Request to create a new community
#### HTTP API - operation and endpoint.
`POST /community`
operationId : createCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/createCommunityRequest'
subscribe :
summary : CreateCommunity (response)
description : Return the details for a community
operationId : createCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/createCommunityResponse'
- $ref : '#/components/messages/errorResponse'
ListCommunities :
publish :
summary : ListCommunities (request)
description : |-
Request to list all communities on the Lemmy server
#### HTTP API - operation and endpoint.
`GET /community/list`
operationId : listCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
2021-02-17 15:47:42 +00:00
$ref : '#/components/messages/listCommunityRequest'
2021-02-16 10:58:06 +00:00
subscribe :
summary : ListCommunities (response)
description : Return the details for all communities
operationId : listCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/listCommunityResponse'
- $ref : '#/components/messages/errorResponse'
BanFromCommunity :
publish :
summary : BanFromCommunity (request)
description : |-
Request to ban a user (`user_id`) from a specified community.
#### HTTP API - operation and endpoint.
`POST /community/ban_user`
operationId : banFromCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/banFromCommunityRequest'
2021-02-23 14:38:17 +00:00
subscribe :
summary : BanFromCommunity (response)
description : Confirmation after a ban request
operationId : banFromCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/banFromCommunityResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-16 10:58:06 +00:00
AddModToCommunity :
publish :
summary : AddModToCommunity (request)
description : |-
Request to add another moderator (`user_id`) to the specified community (`community_id`).
The account making the request (`auth`) must be either an admin or a moderator of that community.
#### HTTP API - operation and endpoint.
`POST /community/mod`
operationId : addModToCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
2021-02-17 15:47:42 +00:00
$ref : '#/components/messages/addModToCommunityRequest'
2021-02-23 14:38:17 +00:00
subscribe :
summary : AddModToCommunity (response)
description : Confirmation that the new moderator has been added
operationId : addModToCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/addModToCommunityResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-22 15:48:59 +00:00
EditCommunity :
publish :
description : |-
Request to edit a community.
The account making the request (`auth`) must be either an admin or a moderator of that community.
#### HTTP API - operation and endpoint.
`PUT /community`
operationId : editCommunityRequestMessage
tags :
- name : Community
message :
$ref : '#/components/messages/editCommunityRequest'
subscribe :
summary : EditCommunity (response)
description : Return the details for the requested community
operationId : editCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/editCommunityResponse'
- $ref : '#/components/messages/errorResponse'
DeleteCommunity :
publish :
summary : DeleteCommunity (request)
description : |-
Request to delete a community.
The account making the request (`auth`) must be the creator of that community.
#### HTTP API - operation and endpoint.
`POST /community/delete`
operationId : deleteCommunityRequestMessage
tags :
- name : Community
message :
$ref : '#/components/messages/deleteCommunityRequest'
subscribe :
summary : DeleteCommunity (response)
description : Return the details for the deleted community
operationId : deleteCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/deleteCommunityResponse'
- $ref : '#/components/messages/errorResponse'
RemoveCommunity :
publish :
summary : RemoveCommunity (request)
description : |-
Request to *permanently* delete a community.
The account making the request (`auth`) must be and admin.
#### HTTP API - operation and endpoint.
`POST /community/remove`
operationId : removeCommunityRequestMessage
tags :
- name : Community
message :
$ref : '#/components/messages/removeCommunityRequest'
subscribe :
summary : RemoveCommunity (response)
description : Return the details for the deleted community
2021-02-23 14:38:17 +00:00
operationId : removeCommunityResponseMessage
2021-02-22 15:48:59 +00:00
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/removeCommunityResponse'
- $ref : '#/components/messages/errorResponse'
FollowCommunity :
publish :
summary : FollowCommunity (request)
description : |-
Request to follow (join) a community.
#### HTTP API - operation and endpoint.
`POST /community/follow`
operationId : followCommunityRequestMessage
tags :
- name : Community
message :
$ref : '#/components/messages/followCommunityRequest'
subscribe :
summary : FollowCommunity (response)
description : Return the details for the followed community
operationId : followCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/followCommunityResponse'
- $ref : '#/components/messages/errorResponse'
GetFollowedCommunities :
publish :
summary : GetFollowedCommunities (request)
description : |-
Request to list all followed (joined) communities.
#### HTTP API - operation and endpoint.
`GET /user/followed_communities`
operationId : getFollowedCommunitiesRequestMessage
tags :
- name : Community
message :
$ref : '#/components/messages/getFollowedCommunitiesRequest'
subscribe :
summary : GetFollowedCommunities (response)
description : Return the details for the followed communities
operationId : getFollowedCommunitiesResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/getFollowedCommunitiesResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-16 10:58:06 +00:00
TransferCommunity :
publish :
summary : TransferCommunity (Request)
description : |-
Request to transfer ownership of a community from one person (`auth`) to another (`user_id`).
The account making the request (`auth`) must be an admin user.
#### HTTP API - operation and endpoint.
`POST /community/transfer`
operationId : transferCommunityRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/transferCommunityRequest'
2021-02-23 14:38:17 +00:00
subscribe :
summary : TransferCommunity (response)
description : Response to a request to transfer community ownership
operationId : transferCommunityResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/transferCommunityResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-16 10:58:06 +00:00
CommunityJoin :
publish :
summary : CommunityJoin (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /community/join`
operationId : communityJoinRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/communityJoinRequest'
subscribe :
summary : CommunityJoin (response)
description : Forthcoming...
operationId : CommunityJoinResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/communityJoinResponse'
- $ref : '#/components/messages/errorResponse'
ModJoin :
publish :
summary : ModJoin (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /community/mod/join`
operationId : modJoinRequestMessage
2021-02-17 15:47:42 +00:00
tags :
2021-02-16 10:58:06 +00:00
- name : Community
message :
$ref : '#/components/messages/modJoinRequest'
subscribe :
summary : ModJoin (response)
description : Forthcoming...
operationId : modJoinResponseMessage
tags :
- name : Community
message :
oneOf :
- $ref : '#/components/messages/modJoinResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-17 15:47:42 +00:00
CreatePost :
publish :
summary : CreatePost (request)
description : |-
Create a new post.
#### HTTP API - operation and endpoint.
`POST /post`
operationId : createPostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/createPostRequest'
subscribe :
summary : CreatePost (response)
description : Forthcoming...
operationId : createPostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/createPostResponse'
- $ref : '#/components/messages/errorResponse'
GetPost :
publish :
summary : GetPost (request)
description : |-
Request details of a post.
#### HTTP API - operation and endpoint.
`GET /post`
operationId : getPostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/getPostRequest'
subscribe :
summary : GetPost (response)
description : Details of a post
operationId : getPostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/getPostResponse'
- $ref : '#/components/messages/errorResponse'
GetPosts :
publish :
summary : GetPosts (request)
description : |-
Request details of all posts on the Lemmy server (or, optionally, in a community).
If specifying a community, use :
- `community_name` for a local community
- `community_id` for a federated community.
#### HTTP API - operation and endpoint.
`GET /post/list`
operationId : getPostListRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/getPostListRequest'
subscribe :
summary : GetPost (response)
description : Details of a post
operationId : getPostListResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/getPostListResponse'
- $ref : '#/components/messages/errorResponse'
CreatePostLike :
publish :
summary : CreatePostLike (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /post/like`
operationId : createPostLikeRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/createPostLikeRequest'
subscribe :
summary : CreatePostLike (response)
description : Forthcoming...
operationId : createPostLikeResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/createPostLikeResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-22 15:48:59 +00:00
EditPost :
publish :
summary : EditPost (request)
description : |-
Request to edit an existing post
#### HTTP API - operation and endpoint.
`PUT /post`
operationId : editPostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/editPostRequest'
subscribe :
summary : EditPost (response)
description : Response to request to edit a post
operationId : editPostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/editPostResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-17 15:47:42 +00:00
DeletePost :
publish :
summary : DeletePost (request)
description : |-
Request that a post is deleted. *Deleted posts can be restored later.*
#### HTTP API - operation and endpoint.
`POST /post/delete`
operationId : deletePostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/deletePostRequest'
subscribe :
summary : DeletePost (response)
description : Response to a post deletion request
operationId : deletePostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/deletePostResponse'
- $ref : '#/components/messages/errorResponse'
RemovePost :
publish :
summary : RemovePost (request)
description : |-
Request that a post is *permanently* deleted.
Only admin and moderator roles can do this.
#### HTTP API - operation and endpoint.
`POST /post/remove`
operationId : removePostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/removePostRequest'
subscribe :
summary : RemovePost (response)
description : Response to a post removal request
operationId : removePostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/removePostResponse'
- $ref : '#/components/messages/errorResponse'
LockPost :
publish :
summary : LockPost (request)
description : |-
Request to lock a post.
Only admin and moderator roles can do this.
#### HTTP API - operation and endpoint.
`POST /post/lock`
operationId : postLockRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/postLockRequest'
subscribe :
summary : LockPost (response)
description : Response to a post lock request
operationId : postLockResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/postLockResponse'
- $ref : '#/components/messages/errorResponse'
StickyPost :
publish :
summary : StickyPost (request)
description : |-
Request to make a post 'sticky' (sit at the top of a list of posts).
Only admin and moderator roles can do this.
#### HTTP API - operation and endpoint.
`POST /post/sticky`
operationId : stickyPostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/stickyPostRequest'
subscribe :
summary : StickyPost (response)
description : |-
Response to a request to make a post 'sticky'
operationId : stickyPostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/stickyPostResponse'
- $ref : '#/components/messages/errorResponse'
SavePost :
publish :
summary : SavePost (request)
description : |-
Add a post to the user's list of saved posts.
#### HTTP API - operation and endpoint.
`POST /post/save`
operationId : savePostRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/savePostRequest'
subscribe :
summary : SavePost (response)
description : Response to a request to add a post to the list of saved posts
operationId : savePostResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/savePostResponse'
- $ref : '#/components/messages/errorResponse'
PostJoin :
publish :
summary : PostJoin (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /post/join`
operationId : postJoinRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/postJoinRequest'
subscribe :
summary : PostJoin (response)
description : Forthcoming...
operationId : postJoinResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/postJoinResponse'
- $ref : '#/components/messages/errorResponse'
CreatePostReport :
publish :
summary : CreatePostReport (request)
description : |-
Raise a report (query) against a post.
#### HTTP API - operation and endpoint.
`POST /post/report`
2021-02-19 13:32:34 +00:00
operationId : createPostReportRequestMessage
2021-02-17 15:47:42 +00:00
tags :
- name : Post
message :
$ref : '#/components/messages/createPostReportRequest'
subscribe :
summary : CreatePostReport (response)
description : Forthcoming...
operationId : createPostReportResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/createPostReportResponse'
- $ref : '#/components/messages/errorResponse'
ResolvePostReport :
publish :
summary : ResolvePostReport (request)
description : |-
Resolve (clear) a report against a post.
2021-02-19 13:32:34 +00:00
See `ListPostReports` for a list of all reported posts.
2021-02-17 15:47:42 +00:00
#### HTTP API - operation and endpoint.
`PUT /post/report/resolve`
operationId : resolvePostReportRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/resolvePostReportRequest'
subscribe :
summary : ResolvePostReport (response)
description : Response to request to resolve a report against a post
operationId : resolvePostReportResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/resolvePostReportResponse'
- $ref : '#/components/messages/errorResponse'
ListPostReports :
publish :
summary : ListPostReports (request)
description : |-
- If `community` is supplied, returns reports for only that community
- Otherwise returns reports for all communities the user (`auth`) moderates.
#### HTTP API - operation and endpoint.
`GET /post/report/list`
operationId : listPostReportsRequestMessage
tags :
- name : Post
message :
$ref : '#/components/messages/listPostReportsRequest'
subscribe :
summary : ListPostReports (response)
description : Response to request to list all reports against posts
operationId : listPostReportsResponseMessage
tags :
- name : Post
message :
oneOf :
- $ref : '#/components/messages/listPostReportsResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-19 13:32:34 +00:00
CreateComment :
publish :
summary : CreateComment (request)
description : |-
Add a comment to a post.
#### HTTP API - operation and endpoint.
`POST /comment`
operationId : createCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/createCommentRequest'
subscribe :
summary : CreateComment (response)
description : Response to request to create a comment
operationId : createCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/createCommentResponse'
- $ref : '#/components/messages/errorResponse'
EditComment :
publish :
summary : EditComment (request)
description : |-
Edit a comment (only the comment's creator can do this).
#### HTTP API - operation and endpoint.
`PUT /comment`
operationId : editCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/createCommentRequest'
subscribe :
summary : EditComment (response)
description : Response to request to edit a comment
operationId : editCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/editCommentResponse'
- $ref : '#/components/messages/errorResponse'
DeleteComment :
publish :
summary : DeleteComment (request)
description : |-
Delete a comment (only the comment's creator can do this).
#### HTTP API - operation and endpoint.
`POST /comment/delete`
operationId : deleteCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/deleteCommentRequest'
subscribe :
summary : DeleteComment (response)
description : Response to request to delete a comment
operationId : deleteCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/deleteCommentResponse'
- $ref : '#/components/messages/errorResponse'
RemoveComment :
publish :
summary : RemoveComment (request)
description : |-
Request that a comment is *permanently* deleted.
Only admin and moderator roles can do this.
#### HTTP API - operation and endpoint.
`POST /comment/remove`
operationId : removeCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/removeCommentRequest'
subscribe :
summary : RemoveComment (response)
description : Response to request to permanently delete a comment
operationId : removeCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/removeCommentResponse'
- $ref : '#/components/messages/errorResponse'
GetComments :
publish :
summary : GetComments (request)
description : |-
Request details of all comments on the Lemmy server (or, optionally, in a community).
If specifying a community, use :
- `community_name` for a local community
- `community_id` for a federated community.
#### HTTP API - operation and endpoint.
`GET /comment/list`
operationId : getCommentsRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/getCommentsRequest'
subscribe :
summary : GetComments (response)
description : Response to request to list all comments
operationId : getCommentsResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/getCommentsResponse'
- $ref : '#/components/messages/errorResponse'
MarkCommentAsRead :
publish :
summary : MarkCommentAsRead (request)
description : |-
Mark a specified comment as read. Only the recipient of a comment can do this.
#### HTTP API - operation and endpoint.
`POST /comment/mark_as_read`
operationId : markCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/markCommentRequest'
subscribe :
summary : MarkCommentAsRead (response)
description : Response to request mark a comment as read
operationId : markCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/markCommentResponse'
- $ref : '#/components/messages/errorResponse'
SaveComment :
publish :
summary : SaveComment (request)
description : |-
Add comment to the user's list of saved comments.
#### HTTP API - operation and endpoint.
`PUT /comment/save`
operationId : saveCommentRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/saveCommentRequest'
subscribe :
summary : SaveComment (response)
description : Response to request to save a comment
operationId : saveCommentResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/saveCommentResponse'
- $ref : '#/components/messages/errorResponse'
CreateCommentLike :
publish :
summary : CreateCommentLike (request)
description : |-
Forthcoming...
#### HTTP API - operation and endpoint.
`POST /comment/like`
operationId : createCommentLikeRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/createCommentLikeRequest'
subscribe :
summary : CreateCommentLike (response)
description : Forthcoming...
operationId : createCommentLikeResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/createCommentLikeResponse'
- $ref : '#/components/messages/errorResponse'
CreateCommentReport :
publish :
summary : CreateCommentReport (request)
description : |-
Raise a report (query) against a comment.
#### HTTP API - operation and endpoint.
`POST /comment/report`
operationId : createCommentReportRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/createCommentReportRequest'
subscribe :
summary : CreateCommentReport(response)
description : Response to raising a report against a comment
operationId : createCommentReportResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/createCommentReportResponse'
- $ref : '#/components/messages/errorResponse'
ResolveCommentReport :
publish :
summary : ResolveCommentReport (request)
description : |-
Resolve (clear) a report against a comment.
See `ListCommentReports` for a list of all reported comments.
#### HTTP API - operation and endpoint.
`PUT /comment/report/resolve`
operationId : resolveCommentReportRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/resolveCommentReportRequest'
subscribe :
summary : ResolveCommentReport (response)
description : Response to a request to clear a report against a comment
operationId : resolveCommentReportResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/resolveCommentReportResponse'
- $ref : '#/components/messages/errorResponse'
ListCommentReports :
publish :
summary : ListCommentReports (request)
description : |-
- If `community` is supplied, returns reports for only that community
- Otherwise returns reports for all communities the user (`auth`) moderates.
#### HTTP API - operation and endpoint.
`GET /comment/report/list`
operationId : listCommentReportsRequestMessage
tags :
- name : Comment
message :
$ref : '#/components/messages/listCommentReportsRequest'
subscribe :
summary : ListCommentReports (response)
description : Response to a request to list all comment reports
operationId : listCommentReportsResponseMessage
tags :
- name : Comment
message :
oneOf :
- $ref : '#/components/messages/listCommentReportsResponse'
- $ref : '#/components/messages/errorResponse'
2021-02-06 03:49:02 +00:00
components :
messages :
2021-02-10 13:35:06 +00:00
errorResponse :
name : Error response
payload :
type : object
properties :
error :
description : 'The error message'
type : string
example : 'passwords_dont_match'
2021-02-06 03:49:02 +00:00
loginRequest :
2021-02-10 13:35:06 +00:00
name : Login request
2021-02-06 03:49:02 +00:00
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-06 03:49:02 +00:00
properties :
op :
type : string
pattern : '^Login$'
default : 'Login'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- username_or_email
- password
2021-02-06 03:49:02 +00:00
properties :
username_or_email :
type : string
2021-02-22 15:48:59 +00:00
description : 'Username or registered email'
2021-02-06 03:49:02 +00:00
example : 'lemmy'
password :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-06 03:49:02 +00:00
loginResponse :
name : Login response
payload :
type : object
properties :
op :
type : string
pattern : '^Login$'
default : 'Login'
data :
$ref : '#/components/schemas/authSchema'
2021-02-10 13:35:06 +00:00
getUserRepliesRequest :
name : User replies request
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetReplies$'
default : 'GetReplies'
data :
$ref : '#/components/schemas/repliesMentionsRequest'
getUserMentionsRequest :
name : User mentions request
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetUserMentions$'
default : 'GetUserMentions'
data :
$ref : '#/components/schemas/repliesMentionsRequest'
2021-02-06 03:49:02 +00:00
getCaptchaRequest :
name : Captcha request
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-06 03:49:02 +00:00
properties :
op :
type : string
pattern : '^GetCaptcha$'
default : 'GetCaptcha'
data :
type : object
getCaptchaResponse :
name : Return Captcha request details
payload :
type : object
properties :
op :
type : string
pattern : '^GetCaptcha$'
default : 'GetCaptcha'
data :
type : object
properties :
ok :
type : object
description : 'Will be *undefined* if Captcha is disabled on the Lemmy server'
properties :
png :
type : string
description : 'A [Base64 encoded](https://www.base64encode.org/) representation of the Captcha image (in .PNG format)'
wav :
type : string
description : 'A [Base64 encoded](https://www.base64encode.org/) representation of the Captcha audio (in .WAV format)'
uuid :
type : string
description : The unique id of the Catpcha request
example : '77cfa414-999e-4445-9940-cebe86139d14'
registerRequest :
name : Register a user on the Lemmy server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-06 03:49:02 +00:00
properties :
op :
type : string
pattern : '^Register$'
default : 'Register'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- username
- password
- admin
- password_verify
- show_nsfw
2021-02-06 03:49:02 +00:00
properties :
username :
type : string
2021-02-22 15:48:59 +00:00
description : 'The name for the new user'
2021-02-06 03:49:02 +00:00
example : 'testuser'
2021-02-22 15:48:59 +00:00
email :
description : |-
The user's email address
type : string
format : email
2021-02-06 03:49:02 +00:00
password :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-06 03:49:02 +00:00
password_verify :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-06 03:49:02 +00:00
admin :
type : boolean
description : 'Set to *true* if this is to be the admin user. Only the user who was *first* registered on the Lemmy server is allowed to be admin.'
example : false
default : false
show_nsfw :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/show_nsfw'
2021-02-06 03:49:02 +00:00
captcha_uuid :
type : string
description : 'The unique id of the Catpcha request (as reported by **GetCaptcha**)'
example : '77cfa414-999e-4445-9940-cebe86139d14'
captcha_answer :
type : string
description : 'The *answer* to the Captcha test'
example : 'EjhBi7'
registerResponse :
name : Registration request response
payload :
type : object
properties :
op :
type : string
pattern : '^Register$'
default : 'Register'
data :
$ref : '#/components/schemas/authSchema'
2021-02-10 13:35:06 +00:00
saveUserSettingsRequest :
name : Save user settings - response
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^SaveUserSettings$'
default : 'SaveUserSettings'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- show_nsfw
2021-02-10 13:35:06 +00:00
properties :
show_nsfw :
$ref : '#/components/schemas/show_nsfw'
theme :
$ref : '#/components/schemas/theme'
default_sort_type :
$ref : '#/components/schemas/default_sort_type'
default_listing_type :
$ref : '#/components/schemas/default_listing_type'
lang :
$ref : '#/components/schemas/lang'
avatar :
$ref : '#/components/schemas/avatar'
banner :
$ref : '#/components/schemas/banner'
preferred_username :
$ref : '#/components/schemas/preferred_username'
email :
$ref : '#/components/schemas/email'
bio :
$ref : '#/components/schemas/bio'
matrix_user_id :
$ref : '#/components/schemas/matrix_user_id'
new_password :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-10 13:35:06 +00:00
new_password_verify :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-10 13:35:06 +00:00
old_password :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-10 13:35:06 +00:00
show_avatars :
$ref : '#/components/schemas/show_avatars'
send_notifications_to_email :
$ref : '#/components/schemas/send_notifications_to_email'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-06 03:49:02 +00:00
getUserDetailsRequest :
name : Return requested user details
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-06 03:49:02 +00:00
properties :
op :
type : string
pattern : '^GetUserDetails$'
default : 'GetUserDetails'
2021-02-10 13:35:06 +00:00
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- sort
- saved_only
2021-02-10 13:35:06 +00:00
properties :
2021-02-23 14:38:17 +00:00
user_id :
$ref : '#/components/schemas/user_id'
username :
$ref : '#/components/schemas/user_name'
2021-02-10 13:35:06 +00:00
sort :
$ref : '#/components/schemas/sort'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
community_id :
$ref : '#/components/schemas/community_id'
saved_only :
type : boolean
description : Forthcoming...
default : false
example : false
auth :
$ref : '#/components/schemas/authStringSchema'
saveUserSettingsResponse :
name : Response to saving user settings (profile)
payload :
type : object
properties :
op :
type : string
pattern : '^SaveUserSettings$'
default : 'SaveUserSettings'
2021-02-23 14:38:17 +00:00
data :
type : object
properties :
jwt :
$ref : '#/components/schemas/authStringSchema'
2021-02-10 13:35:06 +00:00
getUserDetailsResponse :
2021-02-23 14:38:17 +00:00
name : User details request response
2021-02-06 03:49:02 +00:00
payload :
type : object
properties :
op :
type : string
pattern : '^GetUserDetails$'
default : 'GetUserDetails'
data :
type : object
2021-02-16 10:58:06 +00:00
user :
$ref : '#/components/schemas/user_view'
posts :
$ref : '#/components/schemas/replies'
comments :
$ref : '#/components/schemas/comments'
moderates :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/moderators'
2021-02-16 10:58:06 +00:00
follows :
description : The list of followers (members) for each community
type : array
items :
properties :
follower :
$ref : '#/components/schemas/user'
community :
$ref : '#/components/schemas/community'
2021-02-10 13:35:06 +00:00
repliesResponse :
name : Returning user replies response
payload :
type : object
properties :
data :
type : object
properties :
replies :
$ref : '#/components/schemas/replies'
op :
type : string
pattern : '^GetReplies$'
default : 'GetReplies'
mentionsResponse :
name : Returning user mentions response
payload :
type : object
properties :
data :
type : object
properties :
mentions :
description : A list of all user mentions
type : array
items :
properties :
UserMentionView :
$ref : '#/components/schemas/mentions'
op :
type : string
pattern : '^GetUserMentions$'
default : 'GetUserMentions'
markMentionsRequest :
name : Request to make a user mention as read
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^MarkUserMentionAsRead$'
default : 'MarkUserMentionAsRead'
data :
type : object
properties :
user_mention_id :
description : 'The id of the recipient'
type : integer
format : int32
read :
description : 'Forthcoming...'
type : boolean
example : false
auth :
$ref : '#/components/schemas/authStringSchema'
markMentionResponse :
name : Returning response for marked mention
payload :
type : object
properties :
2021-02-22 15:48:59 +00:00
op :
type : string
pattern : '^MarkUserMentionAsRead$'
default : 'MarkUserMentionAsRead'
2021-02-10 13:35:06 +00:00
data :
type : object
properties :
mention :
$ref : '#/components/schemas/mentions'
privateMessageRequest :
name : Request to list all a user's private messages
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetPrivateMessages$'
default : 'GetPrivateMessages'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- unread_only
- auth
2021-02-10 13:35:06 +00:00
properties :
unread_only :
$ref : '#/components/schemas/unread_only'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
auth :
$ref : '#/components/schemas/authStringSchema'
privateMessagesResponse :
name : List of all a user's private messages
payload :
type : object
properties :
data :
type : object
properties :
private_messages :
type : array
items :
$ref : '#/components/schemas/private_message_view'
op :
type : string
pattern : '^GetPrivateMessages$'
default : 'GetPrivateMessages'
createPrivateMessageRequest :
name : |-
Request to create a private message
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^CreatePrivateMessage$'
default : 'CreatePrivateMessage'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- content
- recipient_id
- auth
2021-02-10 13:35:06 +00:00
properties :
content :
$ref : '#/components/schemas/content'
recipient_id :
$ref : '#/components/schemas/recipient'
auth :
$ref : '#/components/schemas/authStringSchema'
createPrivateMessageResponse :
name : |-
Confirmation of the sent private message
payload :
type : object
properties :
op :
type : string
pattern : '^CreatePrivateMessage$'
default : 'CreatePrivateMessage'
data :
type : object
properties :
private_message_view :
$ref : '#/components/schemas/private_message_view'
editPrivateMessageRequest :
name : Request to edit a private message
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^EditPrivateMessage$'
default : 'EditPrivateMessage'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- private_message_id
- content
- auth
2021-02-10 13:35:06 +00:00
properties :
private_message_id :
$ref : '#/components/schemas/private_message_id'
content :
$ref : '#/components/schemas/content'
auth :
$ref : '#/components/schemas/authStringSchema'
editPrivateMessageResponse :
name : Confirmation of the edited private message
payload :
type : object
properties :
data :
type : object
properties :
private_message_view :
$ref : '#/components/schemas/private_message_view'
op :
type : string
pattern : '^EditPrivateMessage$'
default : 'EditPrivateMessage'
deletePrivateMessageRequest :
name : Request to delete a private message
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^DeletePrivateMessage$'
default : 'DeletePrivateMessage'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- private_message_id
- deleted
- auth
2021-02-10 13:35:06 +00:00
properties :
private_message_id :
$ref : '#/components/schemas/private_message_id'
deleted :
$ref : '#/components/schemas/deleted'
auth :
$ref : '#/components/schemas/authStringSchema'
deletePrivateMessageResponse :
name : Confirmation of the deleted private message
payload :
type : object
properties :
data :
type : object
properties :
private_message_view :
$ref : '#/components/schemas/private_message_view'
op :
type : string
pattern : '^DeletePrivateMessage$'
default : 'DeletePrivateMessage'
markPrivateMessageRequest :
name : Request to mark a private message as read
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^MarkPrivateMessageAsRead$'
default : 'MarkPrivateMessageAsRead'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- private_message_id
- read
- auth
2021-02-10 13:35:06 +00:00
properties :
private_message_id :
$ref : '#/components/schemas/private_message_id'
read :
$ref : '#/components/schemas/read'
auth :
$ref : '#/components/schemas/authStringSchema'
markPrivateMessageResponse :
name : 'Confirmation that the private message has been marked as *read*'
payload :
type : object
properties :
data :
type : object
properties :
private_message_view :
$ref : '#/components/schemas/private_message_view'
op :
type : string
pattern : '^MarkPrivateMessageAsRead$'
default : 'MarkPrivateMessageAsRead'
markAllReadRequest :
name : Request to mark all user replies and mentions as read
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^MarkAllAsRead$'
default : 'MarkAllAsRead'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- auth
2021-02-10 13:35:06 +00:00
properties :
auth :
$ref : '#/components/schemas/authStringSchema'
markAllReadResponse :
name : 'Confirmation that all replies and mentions have been marked as *read*'
payload :
type : object
properties :
data :
type : object
properties :
replies :
$ref : '#/components/schemas/replies'
op :
type : string
pattern : '^MarkAllAsRead$'
default : 'MarkAllAsRead'
deleteAccountRequest :
name : Request to delete a user account
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^DeleteAccount$'
default : 'DeleteAccount'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- password
- auth
2021-02-10 13:35:06 +00:00
properties :
password :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/password'
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
deleteAccountResponse :
name : Confirmation that the account has been deleted
payload :
type : object
properties :
data :
type : object
properties :
jwt :
$ref : '#/components/schemas/authStringSchema'
op :
type : string
pattern : '^DeleteAccount$'
default : 'DeleteAccount'
addAdminRequest :
name : Request to grant admin privileges to a user
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^AddAdmin$'
default : 'AddAdmin'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- user_id
- added
- auth
2021-02-10 13:35:06 +00:00
properties :
user_id :
$ref : '#/components/schemas/user_id'
added :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/added'
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
addAdminResponse :
name : Confirmation that the user has been given admin privileges
payload :
type : object
properties :
op :
type : string
pattern : '^AddAdmin$'
default : 'AddAdmin'
2021-02-16 10:58:06 +00:00
data :
type : object
properties :
admins :
$ref : '#/components/schemas/user_view'
2021-02-10 13:35:06 +00:00
banUserRequest :
name : Request to ban a user
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^BanUser$'
default : 'BanUser'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- user_id
- ban
- auth
2021-02-10 13:35:06 +00:00
properties :
user_id :
$ref : '#/components/schemas/user_id'
ban :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/ban'
2021-02-10 13:35:06 +00:00
remove_data :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/remove_data'
2021-02-10 13:35:06 +00:00
reason :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/reason'
2021-02-10 13:35:06 +00:00
expires :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/expires'
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
banUserResponse :
name : Confirmation that the user has been banned
payload :
type : object
properties :
op :
type : string
pattern : '^BanUser$'
default : 'BanUser'
2021-02-16 10:58:06 +00:00
data :
$ref : '#/components/schemas/ban_view'
2021-02-10 13:35:06 +00:00
userJoinRequest :
2021-02-17 15:47:42 +00:00
name : Forthcoming...
2021-02-10 13:35:06 +00:00
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^UserJoin$'
default : 'UserJoin'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- auth
2021-02-10 13:35:06 +00:00
properties :
auth :
$ref : '#/components/schemas/authStringSchema'
userJoinResponse :
name : Forthcoming...
payload :
type : object
properties :
op :
type : string
pattern : '^UserJoin$'
default : 'UserJoin'
2021-02-17 15:47:42 +00:00
data :
type : object
properties :
joined :
$ref : '#/components/schemas/joined'
2021-02-10 13:35:06 +00:00
getReportCountRequest :
name : Request to return report count numbers
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetReportCount$'
default : 'GetReportCount'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- auth
2021-02-10 13:35:06 +00:00
properties :
community :
$ref : '#/components/schemas/community_id'
auth :
$ref : '#/components/schemas/authStringSchema'
getReportCountResponse :
name : Report on the number of posts and comments
payload :
type : object
properties :
2021-02-22 15:48:59 +00:00
op :
type : string
pattern : '^GetReportCount$'
default : 'GetReportCount'
2021-02-10 13:35:06 +00:00
data :
type : object
properties :
comment_reports :
description : The number of comments in the community/communities
type : integer
format : int64
example : 123
community :
$ref : '#/components/schemas/community_id'
post_reports :
description : The number of posts in the community/communities
type : integer
format : int64
example : 23
getCategoriesRequest :
name : Request to list categories on the Lemmy server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^ListCategories$'
default : 'ListCategories'
data :
type : object
getCategoriesResponse :
name : Returns list of categories on the server
payload :
type : object
properties :
data :
type : object
properties :
categories :
type : array
items :
properties :
id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/category_id'
2021-02-10 13:35:06 +00:00
name :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/category_name'
2021-02-10 13:35:06 +00:00
op :
type : string
pattern : '^ListCategories$'
default : 'ListCategories'
searchRequest :
name : Request to find information on the Lemmy server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^Search$'
default : 'Search'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- q
- type_
- sort
2021-02-10 13:35:06 +00:00
properties :
q :
description : The text to search for on the Lemmy server
type : string
example : 'lemmy'
type_ :
$ref : '#/components/schemas/type_'
community_id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/community_id'
2021-02-10 13:35:06 +00:00
community_name :
$ref : '#/components/schemas/community_name'
sort :
$ref : '#/components/schemas/sort'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
auth :
$ref : '#/components/schemas/authStringSchema'
searchResponse :
name : The search results
payload :
type : object
properties :
2021-02-16 10:58:06 +00:00
op :
type : string
pattern : '^Search$'
2021-02-17 15:47:42 +00:00
default : 'Search'
2021-02-10 13:35:06 +00:00
data :
type : object
properties :
communities :
type : array
items :
properties :
community :
$ref : '#/components/schemas/community'
posts :
$ref : '#/components/schemas/replies'
type_ :
$ref : '#/components/schemas/type_'
users :
type : array
items :
properties :
user :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/user_view'
2021-02-10 13:35:06 +00:00
comments :
$ref : '#/components/schemas/comments'
getModLogRequest :
2021-02-16 10:58:06 +00:00
name : Request the site's Modlog
2021-02-10 13:35:06 +00:00
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetModLog$'
default : 'GetModLog'
data :
type : object
properties :
mod_user_id :
$ref : '#/components/schemas/user_id'
community_id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/community_id'
2021-02-10 13:35:06 +00:00
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
2021-02-16 10:58:06 +00:00
getModLogResponse :
name : Modlog request results
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^GetModLog$'
default : 'GetModLog'
data :
type : object
properties :
removed_posts :
type : array
locked_posts :
type : array
items :
properties :
mod_lock_post :
type : object
properties :
id :
description : Forthcoming...
type : number
example : 1
mod_user_id :
$ref : '#/components/schemas/user_id'
post_id :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/post_id'
2021-02-16 10:58:06 +00:00
locked :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/locked'
2021-02-16 10:58:06 +00:00
when_ :
description : 'The date this post was locked (in [ISO8601 format](https://www.w3.org/TR/NOTE-datetime))'
type : string
example : '2021-01-26T14:15:21.922339'
moderator :
$ref : '#/components/schemas/creator'
post :
$ref : '#/components/schemas/post'
community :
$ref : '#/components/schemas/community'
stickied_posts :
type : array
items :
properties :
mod_sticky_post :
type : object
properties :
id :
description : Forthcoming...
type : number
example : 1
mod_user_id :
$ref : '#/components/schemas/user_id'
post_id :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/post_id'
2021-02-16 10:58:06 +00:00
stickied :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/stickied'
2021-02-16 10:58:06 +00:00
when_ :
description : 'The date this post was made sticky (in [ISO8601 format](https://www.w3.org/TR/NOTE-datetime))'
type : string
example : '2021-01-26T14:16:03.899093'
moderator :
$ref : '#/components/schemas/creator'
post :
$ref : '#/components/schemas/post'
community :
$ref : '#/components/schemas/community'
removed_comments :
description : Forthcoming...
type : array
removed_communities :
description : Forthcoming...
type : array
banned_from_community :
description : Forthcoming...
type : array
banned :
description : Forthcoming...
type : array
added_to_community :
description : Forthcoming...
type : array
added :
description : Forthcoming...
type : array
2021-02-10 13:35:06 +00:00
createSiteRequest :
name : Create Lemmy site on a server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^CreateSite$'
default : 'CreateSite'
data :
$ref : '#/components/schemas/site_properties'
2021-02-23 14:38:17 +00:00
createSiteResponse :
name : Returns Lemmy site details
payload :
type : object
properties :
op :
type : string
pattern : '^CreateSite$'
default : 'CreateSite'
data :
type : object
properties :
site_view :
$ref : '#/components/schemas/site_view'
2021-02-10 13:35:06 +00:00
editSiteRequest :
name : Request to edit Lemmy site details
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^EditSite$'
default : 'EditSite'
data :
$ref : '#/components/schemas/site_properties'
editSiteResponse :
name : The response after a site edit
payload :
type : object
properties :
op :
type : string
pattern : '^EditSite$'
default : 'EditSite'
data :
type : object
properties :
site_view :
$ref : '#/components/schemas/site_view'
getSiteRequest :
name : Request to return Lemmy site details
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetSite$'
default : 'GetSite'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- auth
2021-02-10 13:35:06 +00:00
properties :
auth :
$ref : '#/components/schemas/authStringSchema'
getSiteResponse :
name : Returns Lemmy site details
payload :
type : object
properties :
2021-02-23 14:38:17 +00:00
op :
type : string
pattern : '^GetSite$'
default : 'GetSite'
2021-02-10 13:35:06 +00:00
data :
type : object
properties :
site_view :
2021-02-23 14:38:17 +00:00
$ref : '#/components/schemas/site_view'
2021-02-10 13:35:06 +00:00
federated_instances :
$ref : '#/components/schemas/federated_instances'
my_user :
$ref : '#/components/schemas/my_user'
version :
$ref : '#/components/schemas/version'
banned :
$ref : '#/components/schemas/banned_list'
online :
$ref : '#/components/schemas/online'
admins :
type : array
items :
properties :
counts :
type : object
properties :
comment_score :
description : Forthcoming...
type : number
example : 8
user_id :
2021-02-23 14:38:17 +00:00
$ref : '#/components/schemas/user_id'
2021-02-10 13:35:06 +00:00
post_score :
description : Forthcoming...
type : number
example : 13
id :
description : Forthcoming...
type : number
example : 1
post_count :
description : Forthcoming...
type : number
example : 10
comment_count :
description : Forthcoming...
type : number
example : 9
user :
$ref : '#/components/schemas/creator'
transferSiteRequest :
name : Request to transfer ownership of the site
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^TransferSite$'
default : 'TransferSite'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- user_id
- auth
2021-02-10 13:35:06 +00:00
properties :
user_id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/user_id'
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
transferSiteResponse :
name : Request to transfer ownership of the site
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^TransferSite$'
default : 'TransferSite'
data :
type : object
properties :
site_view :
$ref : '#/components/schemas/site_view'
admins :
description : The list of administrators for this site
type : array
items :
properties :
user :
$ref : '#/components/schemas/user'
counts :
$ref : '#/components/schemas/counts'
banned :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/banned_list'
2021-02-10 13:35:06 +00:00
online :
$ref : '#/components/schemas/online'
version :
$ref : '#/components/schemas/version'
my_user :
$ref : '#/components/schemas/my_user'
federated_instances :
$ref : '#/components/schemas/federated_instances'
getSiteConfigRequest :
name : Request the configuration data for a Lemmy server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^GetSiteConfig$'
2021-02-16 10:58:06 +00:00
default : 'GetSiteConfig'
2021-02-10 13:35:06 +00:00
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- auth
2021-02-17 15:47:42 +00:00
properties :
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
getSiteConfigResponse :
name : Returns the configuration data for a Lemmy server
payload :
type : object
properties :
op :
type : string
pattern : '^GetSiteConfig$'
2021-02-16 10:58:06 +00:00
default : 'GetSiteConfig'
2021-02-10 13:35:06 +00:00
data :
type : object
properties :
config_hjson :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/config_hjson'
2021-02-10 13:35:06 +00:00
saveSiteConfigRequest :
name : Request to send a configuration data file for a Lemmy server
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-10 13:35:06 +00:00
properties :
op :
type : string
pattern : '^SaveSiteConfig$'
2021-02-16 10:58:06 +00:00
default : 'SaveSiteConfig'
2021-02-10 13:35:06 +00:00
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- config_hjson
- auth
2021-02-10 13:35:06 +00:00
properties :
config_hjson :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/config_hjson'
2021-02-10 13:35:06 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
saveSiteConfigResponse :
name : Returns the configuration data for a Lemmy server
payload :
type : object
properties :
op :
type : string
pattern : '^SaveSiteConfig$'
default : '^SaveSiteConfig$'
data :
type : object
properties :
config_hjson :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/config_hjson'
getCommunityRequest :
name : Request to get details of a commmunity
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^GetCommunity$'
default : 'GetCommunity'
data :
type : object
properties :
id :
$ref : '#/components/schemas/community_id'
name :
$ref : '#/components/schemas/community_name'
auth :
$ref : '#/components/schemas/authStringSchema'
getCommunityResponse :
name : Returns the details for a community
payload :
type : object
properties :
op :
type : string
pattern : '^GetCommunity$'
default : 'GetCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
online :
type : number
moderators :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/moderators'
2021-02-16 10:58:06 +00:00
createCommunityRequest :
name : Request to get details of a commmunity
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^CreateCommunity$'
default : 'CreateCommunity'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- name
- title
- category_id
- nsfw
- auth
2021-02-16 10:58:06 +00:00
properties :
name :
$ref : '#/components/schemas/community_name'
title :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/title'
2021-02-16 10:58:06 +00:00
description :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/description'
2021-02-16 10:58:06 +00:00
icon :
$ref : '#/components/schemas/icon'
banner :
$ref : '#/components/schemas/banner'
category_id :
$ref : '#/components/schemas/category_id'
nsfw :
$ref : '#/components/schemas/nsfw'
auth :
$ref : '#/components/schemas/authStringSchema'
createCommunityResponse :
name : Response to the request to create a community
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^CreateCommunity$'
default : 'CreateCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
listCommunityRequest :
2021-02-23 14:38:17 +00:00
name : Request list of communities on the Lemmy server
2021-02-16 10:58:06 +00:00
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^ListCommunities$'
default : 'ListCommunities'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
2021-02-23 14:38:17 +00:00
- type_
2021-02-22 15:48:59 +00:00
- sort
2021-02-16 10:58:06 +00:00
properties :
type_ :
$ref : '#/components/schemas/type_'
sort :
$ref : '#/components/schemas/sort'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
auth :
$ref : '#/components/schemas/authStringSchema'
listCommunityResponse :
2021-02-22 15:48:59 +00:00
name : Response to the request to list all communities
2021-02-16 10:58:06 +00:00
payload :
type : object
properties :
op :
type : string
pattern : '^ListCommunities$'
default : 'ListCommunities'
data :
type : object
properties :
communities :
type : array
$ref : '#/components/schemas/community_view'
banFromCommunityRequest :
name : Request to ban a user from a specified community.
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^BanFromCommunity$'
default : 'BanFromCommunity'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- community_id
- user_id
- ban
- auth
2021-02-16 10:58:06 +00:00
properties :
community_id :
$ref : '#/components/schemas/community_id'
user_id :
$ref : '#/components/schemas/user_id'
ban :
$ref : '#/components/schemas/ban'
remove_data :
$ref : '#/components/schemas/remove_data'
reason :
$ref : '#/components/schemas/reason'
expires :
$ref : '#/components/schemas/expires'
auth :
$ref : '#/components/schemas/authStringSchema'
banFromCommunityResponse :
name : Response to the request to ban a user from a community
payload :
type : object
properties :
op :
type : string
pattern : '^BanFromCommunity$'
default : 'BanFromCommunity'
data :
$ref : '#/components/schemas/ban_view'
addModToCommunityRequest :
name : Request to add a moderator to a community
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^AddModToCommunity$'
default : 'AddModToCommunity'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- community_id
- user_id
- added
- auth
2021-02-16 10:58:06 +00:00
properties :
community_id :
$ref : '#/components/schemas/community_id'
user_id :
$ref : '#/components/schemas/user_id'
added :
$ref : '#/components/schemas/added'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-23 14:38:17 +00:00
addModToCommunityResponse :
name : Confirmation that a moderator has been added to the community
payload :
type : object
properties :
op :
type : string
pattern : '^AddModToCommunity$'
default : 'AddModToCommunity'
data :
type : object
properties :
moderators :
$ref : '#/components/schemas/moderators'
2021-02-22 15:48:59 +00:00
editCommunityRequest :
name : Request to edit a community
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^EditCommunity$'
default : 'EditCommunity'
data :
type : object
required :
- community_id
- title
- category_id
- nsfw
- auth
properties :
community_id :
$ref : '#/components/schemas/community_id'
title :
$ref : '#/components/schemas/title'
description :
$ref : '#/components/schemas/description'
icon :
$ref : '#/components/schemas/icon'
banner :
$ref : '#/components/schemas/banner'
category_id :
$ref : '#/components/schemas/category_id'
nsfw :
$ref : '#/components/schemas/nsfw'
auth :
$ref : '#/components/schemas/authStringSchema'
editCommunityResponse :
name : Response to the request to edit a community
payload :
type : object
properties :
op :
type : string
pattern : '^EditCommunity$'
default : 'EditCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
deleteCommunityRequest :
name : Request to delete a community
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^DeleteCommunity$'
default : 'DeleteCommunity'
data :
type : object
required :
- community_id
- deleted
- auth
properties :
community_id :
$ref : '#/components/schemas/community_id'
deleted :
$ref : '#/components/schemas/deleted'
auth :
$ref : '#/components/schemas/authStringSchema'
deleteCommunityResponse :
name : Response to the request to delete a community
payload :
type : object
properties :
op :
type : string
pattern : '^DeleteCommunity$'
default : 'DeleteCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
removeCommunityRequest :
name : Request to permanently delete a community
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^RemoveCommunity$'
default : 'RemoveCommunity'
data :
type : object
required :
- community_id
- removed
- auth
properties :
community_id :
$ref : '#/components/schemas/community_id'
removed :
$ref : '#/components/schemas/removed'
reason :
$ref : '#/components/schemas/reason'
expires :
$ref : '#/components/schemas/expires'
auth :
$ref : '#/components/schemas/authStringSchema'
removeCommunityResponse :
name : Response to the request to permanently delete a community
payload :
type : object
properties :
op :
type : string
pattern : '^RemoveCommunity$'
default : 'RemoveCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
followCommunityRequest :
name : Request to follow a community
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^FollowCommunity$'
default : 'FollowCommunity'
data :
type : object
required :
- community_id
- follow
- auth
properties :
community_id :
$ref : '#/components/schemas/community_id'
follow :
description : Forthcoming...
type : boolean
example : true
auth :
$ref : '#/components/schemas/authStringSchema'
followCommunityResponse :
name : Response to the request to follow a community
payload :
type : object
properties :
op :
type : string
pattern : '^FollowCommunity$'
default : 'FollowCommunity'
data :
type : object
properties :
community_view :
$ref : '#/components/schemas/community_view'
getFollowedCommunitiesRequest :
name : Request to list all followed communities
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^GetFollowedCommunities$'
default : 'GetFollowedCommunities'
data :
type : object
required :
- auth
properties :
auth :
$ref : '#/components/schemas/authStringSchema'
getFollowedCommunitiesResponse :
name : List of followed communities
payload :
type : object
properties :
op :
type : string
pattern : '^GetFollowedCommunities$'
default : 'GetFollowedCommunities'
data :
type : object
properties :
communities :
type : array
items :
properties :
community :
$ref : '#/components/schemas/community'
follower :
$ref : '#/components/schemas/user'
2021-02-16 10:58:06 +00:00
transferCommunityRequest :
name : Request to transfer ownership of a community from one person to another
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^TransferCommunity$'
default : 'TransferCommunity'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- community_id
- user_id
- auth
2021-02-16 10:58:06 +00:00
properties :
community_id :
$ref : '#/components/schemas/community_id'
user_id :
$ref : '#/components/schemas/user_id'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-23 14:38:17 +00:00
transferCommunityResponse :
name : Response to a request to transfer community ownership
payload :
type : object
properties :
op :
type : string
pattern : '^TransferCommunity$'
default : 'TransferCommunity'
data :
type : object
properties :
moderators :
$ref : '#/components/schemas/moderators'
online :
$ref : '#/components/schemas/online'
community_view :
$ref : '#/components/schemas/community_view'
2021-02-16 10:58:06 +00:00
communityJoinRequest :
name : Forthcoming...
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^CommunityJoin$'
default : 'CommunityJoin'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- community_id
2021-02-16 10:58:06 +00:00
properties :
community_id :
$ref : '#/components/schemas/community_id'
communityJoinResponse :
name : Forthcoming...
payload :
type : object
properties :
op :
type : string
pattern : '^CommunityJoin$'
default : 'CommunityJoin'
data :
properties :
joined :
$ref : '#/components/schemas/joined'
modJoinRequest :
name : Forthcoming...
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-16 10:58:06 +00:00
properties :
op :
type : string
pattern : '^ModJoin$'
default : 'ModJoin'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- community_id
2021-02-16 10:58:06 +00:00
properties :
community_id :
$ref : '#/components/schemas/community_id'
modJoinResponse :
name : Forthcoming...
payload :
type : object
properties :
op :
type : string
pattern : '^ModJoin$'
default : 'ModJoin'
data :
properties :
joined :
$ref : '#/components/schemas/joined'
2021-02-17 15:47:42 +00:00
createPostRequest :
name : Request to create a new post
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^CreatePost$'
default : 'CreatePost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- name
- nsfw
- community_id
- auth
2021-02-17 15:47:42 +00:00
properties :
name :
$ref : '#/components/schemas/post_name'
url :
$ref : '#/components/schemas/url'
body :
$ref : '#/components/schemas/body'
nsfw :
$ref : '#/components/schemas/nsfw'
community_id :
$ref : '#/components/schemas/community_id'
auth :
$ref : '#/components/schemas/authStringSchema'
createPostResponse :
name : Response to request to create a new post
payload :
type : object
properties :
op :
type : string
pattern : '^CreatePost$'
default : 'CreatePost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
getPostRequest :
name : Request details of a post
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^GetPost$'
default : 'GetPost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- id
- auth
2021-02-17 15:47:42 +00:00
properties :
id :
$ref : '#/components/schemas/post_id'
auth :
$ref : '#/components/schemas/authStringSchema'
getPostResponse :
name : Details of a post
payload :
type : object
properties :
op :
type : string
pattern : '^GetPost$'
default : 'GetPost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
comments :
$ref : '#/components/schemas/comments'
community_view :
$ref : '#/components/schemas/community_view'
moderators :
$ref : '#/components/schemas/moderators'
getPostListRequest :
name : Request details of all posts
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^GetPosts$'
default : 'GetPosts'
data :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/list_request'
2021-02-17 15:47:42 +00:00
getPostListResponse :
name : Details of all posts
payload :
type : object
properties :
op :
type : string
pattern : '^GetPosts$'
default : 'GetPosts'
data :
type : object
properties :
posts :
type : array
items :
properties :
post_view :
$ref : '#/components/schemas/post_view'
createPostLikeRequest :
name : Forthcoming...
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^CreatePostLike$'
default : 'CreatePostLike'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- score
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
score :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/score_plus_minus'
2021-02-17 15:47:42 +00:00
auth :
$ref : '#/components/schemas/authStringSchema'
createPostLikeResponse :
name : Response to request to create a new post
payload :
type : object
properties :
op :
type : string
pattern : '^CreatePostLike$'
default : 'CreatePostLike'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
2021-02-22 15:48:59 +00:00
editPostRequest :
name : Request to edit an existing post
payload :
type : object
required :
- op
- data
properties :
op :
type : string
pattern : '^EditPost$'
default : 'EditPost'
data :
type : object
required :
- post_id
- name
- nsfw
- auth
properties :
post_id :
$ref : '#/components/schemas/post_id'
name :
$ref : '#/components/schemas/post_name'
url :
$ref : '#/components/schemas/url'
nsfw :
$ref : '#/components/schemas/nsfw'
auth :
$ref : '#/components/schemas/authStringSchema'
editPostResponse :
name : Response to request to edit a post
payload :
type : object
properties :
op :
type : string
pattern : '^EditPost$'
default : 'EditPost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
2021-02-17 15:47:42 +00:00
deletePostRequest :
name : Request that a post be deleted
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^DeletePost$'
default : 'DeletePost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- deleted
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
deleted :
$ref : '#/components/schemas/deleted'
auth :
$ref : '#/components/schemas/authStringSchema'
deletePostResponse :
name : Response to post deletion request
payload :
type : object
properties :
op :
type : string
pattern : '^DeletePost$'
default : 'DeletePost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
removePostRequest :
name : Request that a post be removed
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^RemovePost$'
default : 'RemovePost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- removed
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
removed :
$ref : '#/components/schemas/removed'
reason :
$ref : '#/components/schemas/reason'
auth :
$ref : '#/components/schemas/authStringSchema'
removePostResponse :
name : Response to post removal request
payload :
type : object
properties :
op :
type : string
pattern : '^RemovePost$'
default : 'RemovePost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
postLockRequest :
name : Request that a post be locked
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
2021-02-23 14:38:17 +00:00
pattern : '^LockPost$'
default : 'LockPost'
2021-02-17 15:47:42 +00:00
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- locked
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
locked :
$ref : '#/components/schemas/locked'
auth :
$ref : '#/components/schemas/authStringSchema'
postLockResponse :
name : Response to a 'post lock' request
payload :
type : object
properties :
op :
type : string
2021-02-23 14:38:17 +00:00
pattern : '^LockPost$'
default : 'LockPost'
2021-02-17 15:47:42 +00:00
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
stickyPostRequest :
name : Request that a post be made 'sticky'
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^StickyPost$'
default : 'StickyPost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- stickied
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
stickied :
$ref : '#/components/schemas/locked'
auth :
$ref : '#/components/schemas/authStringSchema'
stickyPostResponse :
name : Response to a request to make a post 'sticky'
payload :
type : object
properties :
op :
type : string
pattern : '^StickyPost$'
default : 'StickyPost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
savePostRequest :
name : Request to add a post to the user's list of saved posts
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^SavePost$'
default : 'SavePost'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- save
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
save :
$ref : '#/components/schemas/saved'
auth :
$ref : '#/components/schemas/authStringSchema'
savePostResponse :
name : Response to a request to add a post to the list of saved posts
payload :
type : object
properties :
op :
type : string
pattern : '^SavePost$'
default : 'SavePost'
data :
type : object
properties :
post_view :
$ref : '#/components/schemas/post_view'
postJoinRequest :
name : Forthcoming...
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^PostJoin$'
default : 'PostJoin'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
postJoinResponse :
name : Forthcoming...
payload :
type : object
properties :
op :
type : string
pattern : '^PostJoin$'
default : 'PostJoin'
data :
type : object
properties :
joined :
$ref : '#/components/schemas/joined'
createPostReportRequest :
name : Request to raise a report against a post
payload :
type : object
properties :
op :
type : string
pattern : '^CreatePostReport$'
default : 'CreatePostReport'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- post_id
- reason
- auth
2021-02-17 15:47:42 +00:00
properties :
post_id :
$ref : '#/components/schemas/post_id'
reason :
$ref : '#/components/schemas/reason'
auth :
$ref : '#/components/schemas/authStringSchema'
createPostReportResponse :
name : Response to raising a report against a post.
payload :
type : object
properties :
op :
type : string
pattern : '^CreatePostReport$'
default : 'CreatePostReport'
data :
type : object
properties :
success :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/success'
2021-02-17 15:47:42 +00:00
resolvePostReportRequest :
name : Request to resolve a report against a post
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^ResolvePostReport$'
default : 'ResolvePostReport'
data :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/resolve_request'
2021-02-17 15:47:42 +00:00
resolvePostReportResponse :
name : Response to request to resolve a report against a post
payload :
type : object
properties :
op :
type : string
pattern : '^ResolvePostReport$'
default : 'ResolvePostReport'
data :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/resolve_response'
2021-02-17 15:47:42 +00:00
listPostReportsRequest :
name : Request to list all reports against posts
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-17 15:47:42 +00:00
properties :
op :
type : string
pattern : '^ListPostReports$'
default : 'ListPostReports'
data :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/report_request'
2021-02-17 15:47:42 +00:00
listPostReportsResponse :
name : Response to a request to list all reports against posts
payload :
type : object
properties :
op :
type : string
pattern : '^ListPostReports$'
default : 'ListPostReports'
data :
type : object
properties :
posts :
type : array
items :
properties :
resolver :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/resolver_id'
2021-02-17 15:47:42 +00:00
community :
$ref : '#/components/schemas/community'
creator :
$ref : '#/components/schemas/creator'
post_creator :
$ref : '#/components/schemas/creator'
post :
$ref : '#/components/schemas/post'
post_report :
type : object
properties :
resolver_id :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/resolver_id'
2021-02-17 15:47:42 +00:00
original_post_body :
$ref : '#/components/schemas/body'
resolved :
$ref : '#/components/schemas/resolved'
published :
$ref : '#/components/schemas/published'
creator_id :
$ref : '#/components/schemas/creator_id'
reason :
$ref : '#/components/schemas/reason'
post_id :
$ref : '#/components/schemas/post_id'
id :
$ref : '#/components/schemas/report_id'
original_post_name :
$ref : '#/components/schemas/post_name'
updated :
description : Forthcoming...
type : string
nullable : true
original_post_url :
description : Forthcoming...
type : string
nullable : true
2021-02-19 13:32:34 +00:00
createCommentRequest :
name : Request to create a comment on a post
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^CreateComment$'
default : 'CreateComment'
data :
$ref : '#/components/schemas/comment_request'
createCommentResponse :
name : Response to a request to create a comment
payload :
type : object
properties :
op :
type : string
pattern : '^CreateComment$'
default : 'CreateComment'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
editCommentRequest :
name : Request to edit a comment
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^EditComment$'
default : 'EditComment'
data :
$ref : '#/components/schemas/comment_request'
editCommentResponse :
name : Response to a request to edit a comment
payload :
type : object
properties :
op :
type : string
pattern : '^EditComment$'
default : 'EditComment'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
deleteCommentRequest :
name : Request to delete a comment
payload :
type : object
properties :
op :
type : string
pattern : '^DeleteComment$'
default : 'DeleteComment'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- deleted
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
deleted :
$ref : '#/components/schemas/deleted'
auth :
$ref : '#/components/schemas/authStringSchema'
deleteCommentResponse :
name : Response to a request to delete a comment
payload :
type : object
properties :
op :
type : string
pattern : '^DeleteComment$'
default : 'DeleteComment'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
removeCommentRequest :
name : Request to permanently delete a comment
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^RemoveComment$'
default : 'RemoveComment'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- removed
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
removed :
$ref : '#/components/schemas/removed'
reason :
$ref : '#/components/schemas/reason'
auth :
$ref : '#/components/schemas/authStringSchema'
removeCommentResponse :
name : Response to a request to permanently delete a comment
payload :
type : object
properties :
op :
type : string
pattern : '^RemoveComment$'
default : 'RemoveComment'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
getCommentsRequest :
name : Request to retrieve all comments
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^GetComments$'
default : 'GetComments'
data :
$ref : '#/components/schemas/list_request'
getCommentsResponse :
name : Response to a request to retrieve all comments
payload :
type : object
properties :
op :
type : string
pattern : '^GetComments$'
default : 'GetComments'
data :
type : object
properties :
comments :
description : 'The list of comments'
type : array
items :
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
markCommentRequest :
name : Request to mark a commment as read
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^MarkCommentAsRead$'
default : 'MarkCommentAsRead'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- read
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
read :
$ref : '#/components/schemas/read'
auth :
$ref : '#/components/schemas/authStringSchema'
markCommentResponse :
name : Response to a request to mark a comment as read
payload :
type : object
properties :
op :
type : string
pattern : '^MarkCommentAsRead$'
default : 'MarkCommentAsRead'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
saveCommentRequest :
name : Request to save a commment
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^SaveComment$'
default : 'SaveComment'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- save
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
save :
$ref : '#/components/schemas/saved'
auth :
$ref : '#/components/schemas/authStringSchema'
saveCommentResponse :
name : Response to a request to save a comment
payload :
type : object
properties :
op :
type : string
pattern : '^SaveComment$'
default : 'SaveComment'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
createCommentLikeRequest :
name : Forthcoming...
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^CreateCommentLike$'
default : 'CreateCommentLike'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- score
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
score :
$ref : '#/components/schemas/score_plus_minus'
auth :
$ref : '#/components/schemas/authStringSchema'
createCommentLikeResponse :
name : Response to a request to save a comment
payload :
type : object
properties :
op :
type : string
pattern : '^CreateCommentLike$'
default : 'CreateCommentLike'
data :
type : object
properties :
comment_view :
$ref : '#/components/schemas/comment_view'
createCommentReportRequest :
name : Request to report a comment
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^CreateCommentReport$'
default : 'CreateCommentReport'
data :
type : object
2021-02-22 15:48:59 +00:00
required :
- comment_id
- reason
- auth
2021-02-19 13:32:34 +00:00
properties :
comment_id :
$ref : '#/components/schemas/comment_id'
reason :
$ref : '#/components/schemas/reason'
auth :
$ref : '#/components/schemas/authStringSchema'
createCommentReportResponse :
name : Response to raising a report against a comment
payload :
type : object
properties :
op :
type : string
pattern : '^CreateCommentReport$'
default : 'CreateCommentReport'
data :
type : object
properties :
success :
$ref : '#/components/schemas/success'
resolveCommentReportRequest :
name : Request to clear a report against a comment
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^ResolveCommentReport$'
default : 'ResolveCommentReport'
data :
$ref : '#/components/schemas/resolve_request'
resolveCommentReportResponse :
name : Response to a request to clear a report against a comment
payload :
type : object
properties :
op :
type : string
pattern : '^ResolveCommentReport$'
default : 'ResolveCommentReport'
data :
$ref : '#/components/schemas/resolve_response'
listCommentReportsRequest :
name : Request to list all reports against comments
payload :
type : object
2021-02-22 15:48:59 +00:00
required :
- op
- data
2021-02-19 13:32:34 +00:00
properties :
op :
type : string
pattern : '^ListCommemtReports$'
default : 'ListCommentReports'
data :
$ref : '#/components/schemas/report_request'
listCommentReportsResponse :
name : Response to a request to list all comment reports
payload :
type : object
properties :
op :
type : string
pattern : '^ListCommemtReports$'
default : 'ListCommentReports'
data :
type : object
properties :
comments :
type : array
items :
properties :
comment_report :
type : object
properties :
resolver_id :
$ref : '#/components/schemas/resolver_id'
published :
$ref : '#/components/schemas/published'
comment_id :
$ref : '#/components/schemas/comment_id'
creator_id :
$ref : '#/components/schemas/creator_id'
reason :
$ref : '#/components/schemas/reason'
original_comment_text :
$ref : '#/components/schemas/body'
id :
description : Forthcoming...
type : number
example : 2
resolved :
$ref : '#/components/schemas/resolved'
updated :
description : Forthcoming...
type : string
nullable : true
resolver :
$ref : '#/components/schemas/resolver_id'
community :
$ref : '#/components/schemas/community'
creator :
$ref : '#/components/schemas/creator'
post :
$ref : '#/components/schemas/post'
comment_creator :
$ref : '#/components/schemas/creator'
comment :
$ref : '#/components/schemas/comment'
2021-02-17 15:47:42 +00:00
schemas :
'actor_id' :
type : string
description : |-
URL for the user/community profile/home page, using the format :
- **User profile** - Site URL/u/username
- **Community home page** - Site URL/c/commmunity name
example : 'https:\/\/enterprise.lemmy.ml\/u\/griddle'
'added' :
description : Forthcoming...
type : boolean
example : true
'admin' :
type : boolean
description : 'Set to *true* if this person is the Lemmy server administrator'
example : false
'ap_id' :
type : string
description : The URL of this post, comment or message
example : 'https:\/\/enterprise.lemmy.ml\/post\/223'
2021-02-06 03:49:02 +00:00
'authSchema' :
type : object
2021-02-23 14:38:17 +00:00
description : 'The authentication string returned by **Login** and **Register**'
2021-02-06 03:49:02 +00:00
properties :
jwt :
$ref : '#/components/schemas/authStringSchema'
'authStringSchema' :
type : string
2021-02-10 13:35:06 +00:00
description : Authentication string for a user
2021-02-06 03:49:02 +00:00
example : 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6NzcsImlzcyI6ImVudGVycHJpc2UubGVtbXkubWwifQ.8UbfUE1v4mfH88s2diX2h6_5bzLHSa_5wIlpOZmHbMQ'
2021-02-10 13:35:06 +00:00
'avatar' :
type : string
nullable : true
description : Forthcoming...
2021-02-16 10:58:06 +00:00
'ban' :
description : |-
- If set to *true*, ban the user
- If set to *false*, do not ban them (use in combination with `remove_data` to restore comments and posts that were previously removed as part of a banning process)
type : boolean
example : true
'ban_view' :
type : object
properties :
user :
$ref : '#/components/schemas/user_view'
banned :
2021-02-23 14:38:17 +00:00
$ref : '#/components/schemas/banned'
2021-02-10 13:35:06 +00:00
'banned' :
type : boolean
description : 'Set to *true* if this account (username) has been banned from posting on the Lemmy server'
example : false
'banned_list' :
description : Forthcoming...
type : array
2021-02-06 03:49:02 +00:00
'banner' :
type : string
nullable : true
description : Forthcoming...
2021-02-10 13:35:06 +00:00
'bio' :
type : string
nullable : true
description : 'A self-written description of the user'
example : 'I am a watercolour artist. I am happy to share the paintings I am working on, give and receive critiques, and post resources such as tutorials.'
2021-02-17 15:47:42 +00:00
'body' :
2021-02-19 13:32:34 +00:00
description : 'The body text of the post or comment'
2021-02-17 15:47:42 +00:00
type : string
nullable : true
2021-02-10 13:35:06 +00:00
'category_id' :
type : number
minimum : 1
description : |-
Matches the dropdown list in a community's *Category* setting. 1 = the topmost element, 2 = the second element, and so on.
example : 15
2021-02-16 10:58:06 +00:00
'category_name' :
description : The category name
type : string
example : 'Politics'
2021-02-10 13:35:06 +00:00
'comment' :
type : object
properties :
creator_id :
$ref : '#/components/schemas/creator_id'
content :
$ref : '#/components/schemas/content'
id :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/comment_id'
2021-02-10 13:35:06 +00:00
read :
2021-02-17 15:47:42 +00:00
description : Is *true* if the author of the original post has read the comment
2021-02-10 13:35:06 +00:00
type : boolean
example : true
parent_id :
description : Forthcoming...
type : number
nullable : true
removed :
$ref : '#/components/schemas/removed'
post_id :
2021-02-19 13:32:34 +00:00
$ref : '#/components/schemas/post_id'
2021-02-10 13:35:06 +00:00
local :
$ref : '#/components/schemas/local'
updated :
description : Forthcoming...
type : string
nullable : true
ap_id :
$ref : '#/components/schemas/ap_id'
deleted :
$ref : '#/components/schemas/deleted'
published :
$ref : '#/components/schemas/published'
2021-02-16 10:58:06 +00:00
'comment_count' :
2021-02-17 15:47:42 +00:00
description : Total number of comments on the site or community
2021-02-16 10:58:06 +00:00
type : number
example : 231
2021-02-19 13:32:34 +00:00
'comment_id' :
description : The number (id) of a comment
type : number
example : 374
'comment_request' :
type : object
2021-02-22 15:48:59 +00:00
required :
- content
- post_id
- auth
2021-02-19 13:32:34 +00:00
properties :
content :
$ref : '#/components/schemas/content'
post_id :
$ref : '#/components/schemas/post_id'
form_id :
$ref : '#/components/schemas/form_id'
auth :
$ref : '#/components/schemas/authStringSchema'
'comment_view' :
type : object
properties :
community :
$ref : '#/components/schemas/community'
recipient :
$ref : '#/components/schemas/recipient'
counts :
$ref : '#/components/schemas/counts'
post :
ref : '#/components/schemas/post'
creator_banned_from_community :
$ref : '#/components/schemas/creator_banned_from_community'
saved :
$ref : '#/components/schemas/saved'
subscribed :
$ref : '#/components/schemas/subscribed'
my_vote :
$ref : '#/components/schemas/my_vote'
comment :
$ref : '#/components/schemas/comment'
creator :
$ref : '#/components/schemas/creator'
recipient_ids :
type : array
items :
recipient :
$ref : '#/components/schemas/recipient'
form_id :
$ref : '#/components/schemas/authStringSchema'
2021-02-10 13:35:06 +00:00
'comments' :
type : array
items :
properties :
comment :
$ref : '#/components/schemas/comment'
recipient :
$ref : '#/components/schemas/recipient'
post :
$ref : '#/components/schemas/post'
creator :
$ref : '#/components/schemas/user'
creator_banned_from_community :
$ref : '#/components/schemas/creator_banned_from_community'
subscribed :
$ref : '#/components/schemas/subscribed'
my_vote :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/my_vote'
2021-02-10 13:35:06 +00:00
counts :
$ref : '#/components/schemas/counts'
saved :
$ref : '#/components/schemas/saved'
community :
$ref : '#/components/schemas/community'
2021-02-06 03:49:02 +00:00
'community' :
type : object
properties :
updated :
type : string
description : Forthcoming...
example : '2020-11-14T13:35:10.270578'
name :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/community_name'
2021-02-06 03:49:02 +00:00
category_id :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/category_id'
2021-02-06 03:49:02 +00:00
icon :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/icon'
2021-02-06 03:49:02 +00:00
nsfw :
$ref : '#/components/schemas/nsfw'
deleted :
$ref : '#/components/schemas/deleted'
removed :
$ref : '#/components/schemas/removed'
published :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/published'
2021-02-06 03:49:02 +00:00
creator_id :
$ref : '#/components/schemas/creator_id'
id :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/community_id'
2021-02-06 03:49:02 +00:00
description :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/description'
2021-02-06 03:49:02 +00:00
actor_id :
$ref : '#/components/schemas/actor_id'
local :
$ref : '#/components/schemas/local'
title :
2021-02-22 15:48:59 +00:00
$ref : '#/components/schemas/title'
2021-02-06 03:49:02 +00:00
banner :
$ref : '#/components/schemas/banner'
'community_id' :
type : integer
2021-02-10 13:35:06 +00:00
format : int32 # Or int64? It's stated as both in different parts of the API docs
2021-02-16 10:58:06 +00:00
description : 'The id number for a community. The main/frontpage `community_id` is 0'
example : 2
2021-02-10 13:35:06 +00:00
'community_name' :
description : The name of a community
type : string
2021-02-16 10:58:06 +00:00
Example : 'main'
'community_view' :
type : object
properties :
subscribed :
$ref : '#/components/schemas/subscribed'
counts :
type : object
properties :
published :
$ref : '#/components/schemas/published'
community_id :
$ref : '#/components/schemas/community_id'
users_active_day :
$ref : '#/components/schemas/users_active_day'
id :
description : 'Forthcoming...'
type : number
example : 1
users_active_half_year :
$ref : '#/components/schemas/users_active_half_year'
comments :
$ref : '#/components/schemas/comment_count'
users_active_month :
$ref : '#/components/schemas/users_active_month'
subscribers :
description : The total number of community subscribers (members)
type : number
example : 41
posts :
$ref : '#/components/schemas/posts'
users_active_week :
$ref : '#/components/schemas/users_active_week'
community :
$ref : '#/components/schemas/community'
creator :
$ref : '#/components/schemas/creator'
category :
type : object
properties :
name :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/category_name'
2021-02-16 10:58:06 +00:00
id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/category_id'
2021-02-10 13:35:06 +00:00
'config_hjson' :
description : The configuration data for a Lemmy server (in JSON format)
type : string
example : |-
{\n # for more info about the config, check out the documentation\n # https://lemmy.ml/docs/administration_configuration.html\n\n setup : {\n # username for the admin user\n admin_username : \"lemmy\"\n # password for the admin user\n admin_password: \"lemmy\"\n # name of the site (can be changed later)\n site_name: \"lemmy-test\"\n }\n\n # the domain name of your instance (eg \"lemmy.ml\")\n hostname: \"localhost\"\n # address where lemmy should listen for incoming requests\n bind: \"0.0.0.0\"\n # port where lemmy should listen for incoming requests\n port: 8536\n # json web token for authorization between server and client\n jwt_secret: \"changeme\"\n # settings related to the postgresql database\n database: {\n # name of the postgres database for lemmy\n database: \"lemmy\"\n # username to connect to postgres\n user: \"lemmy\"\n # password to connect to postgres\n password: \"password\"\n # host where postgres is running\n host: \"postgres\"\n }\n# # optional: email sending configuration\n# email: {\n# # hostname and port of the smtp server\n# smtp_server: \"aspmx.l.google.com\"\n# # login name for smtp server\n# smtp_login: \"lemmmy@glemmy.com\"\n# # password to login to the smtp server\n# smtp_password: \"lemom\"\n# # address to send emails from, eg \"noreply@your-instance.com\"\n# smtp_from_address: \"noreply@lemmy.com\"\n# # whether or not smtp connections should use tls\n# use_tls: true\n# }\n}\n\n"
'content' :
description : The text of the comment or message
type : string
example : '> Communities\n\n\n![](https:\/\/enterprise.lemmy.ml\/pictrs\/image\/KZ7NoyJgxx.jpg)'
'counts' :
type : object
properties :
downvotes :
$ref : '#/components/schemas/downvotes'
published :
$ref : '#/components/schemas/published'
score :
$ref : '#/components/schemas/score'
comment_id :
type : number
description : Forthcoming...
id :
type : number
description : Forthcoming...
upvotes :
$ref : '#/components/schemas/upvotes'
'creator' :
type : object
properties :
preferred_username :
$ref : '#/components/schemas/preferred_username'
banned :
$ref : '#/components/schemas/banned'
matrix_user_id :
$ref : '#/components/schemas/matrix_user_id'
updated :
$ref : '#/components/schemas/user_updated'
id :
$ref : '#/components/schemas/user_id'
shared_inbox_url :
description : Forthcoming...
type : string
example : 'https:\/\/enterprise.lemmy.ml\/inbox'
published :
description : Forthcoming...
type : string
example : '2020-09-14T14:54:53.080949'
actor_id :
$ref : '#/components/schemas/actor_id'
deleted :
$ref : '#/components/schemas/deleted'
banner :
$ref : '#/components/schemas/banner'
name :
$ref : '#/components/schemas/user_name'
avatar :
$ref : '#/components/schemas/avatar'
inbox_url :
description : |-
The link to the inbox of the site's creator
type : string
example : 'https:\/\/enterprise.lemmy.ml\/u\/nutomic\/inbox'
local :
$ref : '#/components/schemas/local'
bio :
$ref : '#/components/schemas/bio'
admin :
$ref : '#/components/schemas/admin'
2021-02-06 03:49:02 +00:00
'creator_banned_from_community' :
type : boolean
description : Forthcoming...
example : false
'creator_id' :
type : number
2021-02-10 13:35:06 +00:00
description : The id of the person who created this site, community, post, comment or message
2021-02-06 03:49:02 +00:00
example : 20
2021-02-10 13:35:06 +00:00
'default_listing_type' :
type : integer
format : int16
minimum : 0
maximum : 2
description : |-
What type of listing to display by default :
0 . All
1 . Subscribed
2 . Community (Local)
example : 0
'default_sort_type' :
type : integer
format : int16
minimum : 0
maximum : 7
description : |-
This user's default sort type for listings :
0 . Active
1 . Hot
2 . New
3 . TopDay
4 . TopWeek
5 . TopMonth
6 . TopYear
7 . TopAll
example : 1
2021-02-06 03:49:02 +00:00
'deleted' :
type : boolean
2021-02-17 15:47:42 +00:00
description : |-
Set to *true* if this community, post, comment, message or user account should be or has been deleted. Unlike *removal*, deletion is not permanent. Deleted items can be recovered
2021-02-06 03:49:02 +00:00
example : false
2021-02-22 15:48:59 +00:00
'description' :
type : string
description : |-
The information in the community's **Sidebar** area
example : 'All about the Rolex/Björn Borg collaboration'
2021-02-06 03:49:02 +00:00
'downvotes' :
type : number
description : Forthcoming...
example : 0
2021-02-10 13:35:06 +00:00
'email' :
description : |-
The user's email address
type : string
format : email
example : 'jane.doe@humanity.org'
'enable_downvotes' :
2021-02-22 15:48:59 +00:00
description : Set to *true* if downvoting is allowed on this site
2021-02-10 13:35:06 +00:00
type : boolean
example : false
2021-02-16 10:58:06 +00:00
'expires' :
description : Forthcoming...
type : integer
format : int64
2021-02-10 13:35:06 +00:00
'federated_instances' :
type : object
properties :
blocked :
$ref : '#/components/schemas/instance'
allowed :
$ref : '#/components/schemas/instance'
linked :
$ref : '#/components/schemas/instance'
2021-02-19 13:32:34 +00:00
'form_id' :
description : Forthcoming... (so you know which message came back)
type : string
nullable : true
example : 'IMPORTANT'
2021-02-10 13:35:06 +00:00
'icon' :
type : string
nullable : true
description : Forthcoming...
'instance' :
type : array
items :
properties :
2021-02-23 14:38:17 +00:00
# COMMENT 'instance' is a guess at the name for this field. Unable to test federation
2021-02-10 13:35:06 +00:00
instance :
description : Forthcoming...
type : string
example : 'ds9.lemmy.ml'
2021-02-16 10:58:06 +00:00
'joined' :
description : '*true* if join request was successful'
type : boolean
example : true
2021-02-10 13:35:06 +00:00
'lang' :
description : |-
The language to display Lemmy's interface in
type : string
example : 'Browser Default'
2021-02-06 03:49:02 +00:00
'local' :
type : boolean
description : |-
- *true* if this is a local user
- *false* if this is a federated user
2021-02-17 15:47:42 +00:00
'locked' :
2021-02-19 13:32:34 +00:00
description : |-
Set to *true* if the post is already, or should be, locked. A locked post cannot receive comments
2021-02-17 15:47:42 +00:00
type : boolean
2021-02-06 03:49:02 +00:00
example : true
2021-02-10 13:35:06 +00:00
'limit' :
type : integer
format : int64
minimum : 1
description : Forthcoming...
example : 20
2021-02-19 13:32:34 +00:00
'list_request' :
type : object
2021-02-22 15:48:59 +00:00
required :
- type_
- sort
2021-02-19 13:32:34 +00:00
properties :
type_ :
$ref : '#/components/schemas/type_listing'
sort :
$ref : '#/components/schemas/sort'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
community_id :
$ref : '#/components/schemas/community_id'
community_name :
$ref : '#/components/schemas/community_name'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-10 13:35:06 +00:00
'matrix_user_id' :
type : string
nullable : true
description : 'The [Matrix](https://matrix.org/docs/projects/try-matrix-now/) id of the user'
'mentions' :
2021-02-22 15:48:59 +00:00
description : 'Forthcoming...'
2021-02-10 13:35:06 +00:00
type : object
2021-02-22 15:48:59 +00:00
required :
- user_mention_id
- read
- auth
properties :
user_mention_id :
description : Forthcoming...
type : integer
format : int32
read :
$ref : '#/components/schemas/read'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-17 15:47:42 +00:00
'moderators' :
description : The list of moderators for each community
type : array
items :
properties :
moderator :
$ref : '#/components/schemas/user'
community :
$ref : '#/components/schemas/community'
2021-02-10 13:35:06 +00:00
'my_user' :
type : object
2021-02-22 15:48:59 +00:00
required :
- show_nsfw
2021-02-10 13:35:06 +00:00
properties :
show_nsfw :
$ref : '#/components/schemas/show_nsfw'
preferred_username :
$ref : '#/components/schemas/preferred_username'
default_sort_type :
$ref : '#/components/schemas/default_sort_type'
banned :
$ref : '#/components/schemas/banned'
default_listing_type :
$ref : '#/components/schemas/default_listing_type'
updated :
$ref : '#/components/schemas/user_updated'
matrix_user_id :
$ref : '#/components/schemas/matrix_user_id'
id :
$ref : '#/components/schemas/user_id'
show_avatars :
$ref : '#/components/schemas/show_avatars'
actor_id :
$ref : '#/components/schemas/actor_id'
deleted :
$ref : '#/components/schemas/deleted'
published :
$ref : '#/components/schemas/published'
banner :
$ref : '#/components/schemas/banner'
name :
$ref : '#/components/schemas/user_name'
avatar :
$ref : '#/components/schemas/avatar'
email :
$ref : '#/components/schemas/email'
lang :
$ref : '#/components/schemas/lang'
local :
$ref : '#/components/schemas/local'
bio :
$ref : '#/components/schemas/bio'
last_refreshed_at :
description : Forthcoming...
type : string
example : '2021-01-21T16:19:08.725191'
send_notifications_to_email :
$ref : '#/components/schemas/send_notifications_to_email'
theme :
$ref : '#/components/schemas/theme'
admin :
$ref : '#/components/schemas/admin'
2021-02-06 03:49:02 +00:00
'my_vote' :
type : number
description : Forthcoming...
example : 1
'nsfw' :
type : boolean
description : 'Set to *true* if this commmunity, post or comment is deemed [NSFW](https://en.wikipedia.org/wiki/Not_safe_for_work) (hence invisble to users who have the NSFW option selected in their profile'
example : false
2021-02-10 13:35:06 +00:00
'online' :
description : Number of registered users who are currently on the system
type : number
example : 1
'open_registration' :
2021-02-22 15:48:59 +00:00
description : Forthcoming...
2021-02-10 13:35:06 +00:00
type : boolean
example : true
'page' :
type : integer
format : int64
minimum : 1
description : Forthcoming...
example : 1
2021-02-22 15:48:59 +00:00
'password' :
2021-02-10 13:35:06 +00:00
type : string
description : '*Exact* password'
example : 'lemmy'
2021-02-06 03:49:02 +00:00
'post' :
type : object
properties :
updated :
type : string
description : Forthcoming...
nullable : true
community_id :
$ref : '#/components/schemas/community_id'
embed_title :
type : string
nullable : true
description : 'If the **url** for an associated post was provided, this will be the *<title>* data from that URL'
example: 'Covid : Novichok scientist invents vaccine | The Independent'
nsfw :
$ref : '#/components/schemas/nsfw'
deleted :
$ref : '#/components/schemas/deleted'
removed :
$ref : '#/components/schemas/removed'
locked :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/locked'
2021-02-06 03:49:02 +00:00
url :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/url'
2021-02-06 03:49:02 +00:00
published :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/published'
2021-02-06 03:49:02 +00:00
stickied :
type : boolean
description : 'Set to *true* if this post has been made *sticky* (that is, it is presented at the top of a list of posts)'
example : false
body :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/body'
2021-02-06 03:49:02 +00:00
embed_html :
type : string
nullable : true
description : Forthcoming...
creator_id :
$ref : '#/components/schemas/creator_id'
thumbnail_url :
type : string
nullable : true
description : Forthcoming...
id :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/post_id'
2021-02-06 03:49:02 +00:00
ap_id :
$ref : '#/components/schemas/ap_id'
embed_description :
type : string
nullable : true
description : 'If the **url** for an associated post was provided, this will be the *meta name="description"* data from that URL'
example : 'Scientist Leonid Rink has a murky past and is well-known for selling nerve agents to criminals'
local :
$ref : '#/components/schemas/local'
name :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/post_name'
'post_id' :
type : number
description : The post number
example : 223
'post_name' :
type : string
description : 'The title of the post'
example : 'Pot. Kettle. Black.'
'post_view' :
type : object
properties :
community :
$ref : '#/components/schemas/community'
read :
$ref : '#/components/schemas/read'
counts :
type : object
properties :
score :
$ref : '#/components/schemas/score'
comments :
description : The number of comments on this post
type : number
example : 0
published :
$ref : '#/components/schemas/published'
post_id :
$ref : '#/components/schemas/post_id'
upvotes :
$ref : '#/components/schemas/upvotes'
id :
description : Forthcoming...
type : number
example : 117
newest_comment_time :
description : 'The date and time of the most recent comment (in [ISO8601 format](https://www.w3.org/TR/NOTE-datetime))'
type : string
example : '2021-02-16T11:22:27.615111'
2021-02-23 14:38:17 +00:00
newest_comment_time_necro :
description : Forthcoming...
type : string
example : '2021-02-23T13:26:54.956691'
2021-02-17 15:47:42 +00:00
stickied :
$ref : '#/components/schemas/stickied'
downvotes :
$ref : '#/components/schemas/downvotes'
post :
$ref : '#/components/schemas/post'
creator_banned_from_community :
type : boolean
saved :
type : boolean
subscribed :
type : boolean
my_vote :
type : number
creator :
$ref : '#/components/schemas/creator'
2021-02-16 10:58:06 +00:00
'posts' :
description : Total number of posts on the site or community
type : number
example : 115
2021-02-10 13:35:06 +00:00
'preferred_username' :
type : string
description : 'If set, this is the name shown instead of, or as well as, *username* in some contexts (also known as **Display name**)'
example : 'Queen of the Griddle'
'private_message' :
type : object
properties :
read :
$ref : '#/components/schemas/unread_only'
creator_id :
$ref : '#/components/schemas/creator_id'
id :
description : Forthcoming...
type : number
example : 16
ap_id :
$ref : '#/components/schemas/ap_id'
published :
$ref : '#/components/schemas/published'
recipient_id :
$ref : '#/components/schemas/recipient'
local :
$ref : '#/components/schemas/local'
content :
$ref : '#/components/schemas/content'
deleted :
$ref : '#/components/schemas/deleted'
updated :
description : Forthcoming...
type : string
nullable : true
'private_message_id' :
description : The id of the private message
type : integer
format : int32
example : 17
'private_message_view' :
type : object
properties :
private_message :
$ref : '#/components/schemas/private_message'
creator :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/user'
2021-02-10 13:35:06 +00:00
recipient :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/user'
2021-02-10 13:35:06 +00:00
'published' :
2021-02-06 03:49:02 +00:00
type : string
2021-02-10 13:35:06 +00:00
description : 'The date this site, community, post, comment or message was created (in [ISO8601 format](https://www.w3.org/TR/NOTE-datetime))'
example : '2021-01-21T16:42:39.897148'
'read' :
type : boolean
2021-02-19 13:32:34 +00:00
description : Set to *true* if this post, comment or message has been read (or should be marked as being read)
2021-02-10 13:35:06 +00:00
example : false
2021-02-16 10:58:06 +00:00
'reason' :
2021-02-17 15:47:42 +00:00
description : Give a reason for the action. Why was this post deleted? Why was this user banned?
2021-02-16 10:58:06 +00:00
type : string
example : 'Breach of terms and conditions'
2021-02-10 13:35:06 +00:00
'recipient' :
description : Forthcoming...
type : number
example : 77
2021-02-16 10:58:06 +00:00
'remove_data' :
description : |-
- If set to *true*, also delete that user's comments and posts
- If set *false*, *restore* that user's comments and posts
type : boolean
example : false
2021-02-06 03:49:02 +00:00
'removed' :
type : boolean
2021-02-17 15:47:42 +00:00
description : |-
Set to *true* if this community, post, comment or message should be or has been *permanently* deleted.
Only admin and moderator roles can do this.
2021-02-06 03:49:02 +00:00
example : false
2021-02-10 13:35:06 +00:00
'replies' :
type : array
items :
properties :
my_vote :
$ref : '#/components/schemas/my_vote'
post :
$ref : '#/components/schemas/post'
creator :
$ref : '#/components/schemas/user'
creator_banned_from_community :
$ref : '#/components/schemas/creator_banned_from_community'
community :
$ref : '#/components/schemas/community'
saved :
$ref : '#/components/schemas/saved'
counts :
$ref : '#/components/schemas/counts'
recipient :
$ref : '#/components/schemas/recipient'
comment :
$ref : '#/components/schemas/comment'
subscribed :
$ref : '#/components/schemas/subscribed'
'repliesMentionsRequest' :
type : object
2021-02-22 15:48:59 +00:00
required :
- sort
- unread_only
- auth
2021-02-10 13:35:06 +00:00
properties :
sort :
$ref : '#/components/schemas/sort'
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
unread_only :
$ref : '#/components/schemas/unread_only'
auth :
$ref : '#/components/schemas/authStringSchema'
2021-02-17 15:47:42 +00:00
'report_id' :
description : The number (id) of a raised report
type : integer
format : int32
example : 1
2021-02-19 13:32:34 +00:00
'report_request' :
type : object
properties :
page :
$ref : '#/components/schemas/page'
limit :
$ref : '#/components/schemas/limit'
community :
$ref : '#/components/schemas/community_id'
auth :
$ref : '#/components/schemas/authStringSchema'
'resolve_request' :
type : object
2021-02-22 15:48:59 +00:00
required :
- report_id
- resolved
- auth
2021-02-19 13:32:34 +00:00
properties :
report_id :
$ref : '#/components/schemas/report_id'
resolved :
$ref : '#/components/schemas/resolved'
auth :
$ref : '#/components/schemas/authStringSchema'
'resolve_response' :
type : object
properties :
report_id :
$ref : '#/components/schemas/report_id'
resolved :
$ref : '#/components/schemas/resolved'
2021-02-17 15:47:42 +00:00
'resolved' :
description : Forthcoming...
type : boolean
example : true
2021-02-19 13:32:34 +00:00
'resolver_id' :
description : The user_id of the person who resolved the report
type : number
nullable : true
2021-02-06 03:49:02 +00:00
'saved' :
2021-02-19 13:32:34 +00:00
description : |-
*true* if this post or comment has been or should be saved on the user's profile
2021-02-06 03:49:02 +00:00
type : boolean
example : false
'score' :
type : number
description : Forthcoming...
example : 1
2021-02-19 13:32:34 +00:00
'score_plus_minus' :
description : Forthcoming...
type : integer
format : int16
example : 1
minimum : -1
maximum : 1
2021-02-10 13:35:06 +00:00
'send_notifications_to_email' :
description : 'If set to *true*, the user will receive email notifications for any username mentions, post and comment replies'
type : boolean
example : false
'show_avatars' :
description : |-
If set to *true*, displays other user's avatar images by their username in listings
type : boolean
example : true
'show_nsfw' :
type : boolean
description : |-
2021-02-22 15:48:59 +00:00
Set to *true* if you wish [NSFW](https://en.wikipedia.org/wiki/Not_safe_for_work) content to be viewable by this person/site
2021-02-10 13:35:06 +00:00
example : false
default : false
'site' :
type : object
2021-02-22 15:48:59 +00:00
required :
- show_nsfw
2021-02-10 13:35:06 +00:00
properties :
description :
$ref : '#/components/schemas/site_description'
banner :
2021-02-17 15:47:42 +00:00
$ref : '#/components/schemas/banner'
2021-02-10 13:35:06 +00:00
enable_downvotes :
$ref : '#/components/schemas/enable_downvotes'
published :
$ref : '#/components/schemas/published'
enable_nsfw :
$ref : '#/components/schemas/show_nsfw'
id :
type : number
name :
$ref : '#/components/schemas/site_name'
updated :
description : Forthcoming...
type : string
nullable : true
example : '2020-09-14T14:58:23.598513'
icon :
$ref : '#/components/schemas/icon'
open_registration :
$ref : '#/components/schemas/open_registration'
creator_id :
$ref : '#/components/schemas/creator_id'
'site_counts' :
type : object
properties :
users_active_week :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/users_active_week'
2021-02-10 13:35:06 +00:00
posts :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/posts'
2021-02-10 13:35:06 +00:00
comments :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/comment_count'
2021-02-10 13:35:06 +00:00
communities :
description : Total number of communities on the site
type : number
example : 14
site_id :
desciption : Forthcoming...
type : number
example : 1
users :
description : Total number of registered users on the site
type : number
example : 51
id :
desciption : Forthcoming...
type : number
example : 1
users_active_day :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/users_active_day'
2021-02-10 13:35:06 +00:00
users_active_month :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/users_active_month'
2021-02-10 13:35:06 +00:00
users_active_half_year :
2021-02-16 10:58:06 +00:00
$ref : '#/components/schemas/users_active_half_year'
2021-02-10 13:35:06 +00:00
'site_description' :
description : |-
A brief overview of the site's purpose
type : string
example : 'Federation test instance'
'site_name' :
2021-02-22 15:48:59 +00:00
description : The name of this site
2021-02-10 13:35:06 +00:00
type : string
example : 'Enterprise'
'site_properties' :
type : object
2021-02-22 15:48:59 +00:00
required :
- name
- auth
- enable_downvotes
- open_registration
- enable_nsfw
2021-02-10 13:35:06 +00:00
properties :
name :
$ref : '#/components/schemas/site_name'
enable_downvotes :
$ref : '#/components/schemas/enable_downvotes'
open_registration :
$ref : '#/components/schemas/open_registration'
enable_nsfw :
$ref : '#/components/schemas/show_nsfw'
description :
$ref : '#/components/schemas/site_description'
icon :
$ref : '#/components/schemas/icon'
banner :
$ref : '#/components/schemas/banner'
auth :
$ref : '#/components/schemas/authStringSchema'
'site_view' :
type : object
properties :
counts :
$ref : '#/components/schemas/counts'
site :
$ref : '#/components/schemas/site'
creator :
$ref : '#/components/schemas/creator'
'sort' :
type : string
description : |-
Sort the response from the server according to one of the following criteria :
- *Active* - the hottest posts/communities, depending on votes, and newest comment publish date
- *Hot* - the hottest posts/communities, depending on votes and publish date
- *New* - the newest posts/communities
- *TopDay* - the most upvoted posts/communities of the current day
- *TopWeek* - the most upvoted posts/communities of the current week
- *TopMonth* - the most upvoted posts/communities of the current month
- *TopYear* - the most upvoted posts/communities of the current year
- *TopAll* - the most upvoted posts/communities on the server.
enum :
- Active
- Hot
- New
- TopDay
- TopWeek
- TopMonth
- TopYear
- TopAll
2021-02-17 15:47:42 +00:00
'stickied' :
description : |-
Set to *true* if the post is 'sticky'
type : boolean
example : true
2021-02-06 03:49:02 +00:00
'subscribed' :
type : boolean
description : Forthcoming...
example : true
2021-02-19 13:32:34 +00:00
'success' :
description : '*true* if report request was successful'
type : boolean
example : true
2021-02-10 13:35:06 +00:00
'theme' :
description : 'The theme style to use'
type : string
example : 'darkly'
enum :
- Browser Default
- cyborg
- darkly
- i386
- journal
- litely
- litera
- materia
- minty
- sketchy
- solar
- united
- vaporwave
- vaporwave-dark
2021-02-22 15:48:59 +00:00
'title' :
type : string
description : |-
The title (**Display name**) of this community.
If set, this is the name shown instead of, or as well as, *name* in some contexts
example : 'BorgWatch'
2021-02-10 13:35:06 +00:00
'type_' :
description : What is the scope of the search?
type : string
example : 'All'
enum :
- All
- Comments
- Posts
- Communities
- Users
- Url
2021-02-19 13:32:34 +00:00
'type_listing' :
description : Choose from one of three types of listing
type : string
example : 'All'
enum :
- All
- Subscribed
- Community
2021-02-10 13:35:06 +00:00
'unread_only' :
description : If *true*, only fetch unread comments or messages
type : boolean
example : false
2021-02-06 03:49:02 +00:00
'upvotes' :
type : number
description : Forthcoming...
example : 1
2021-02-17 15:47:42 +00:00
'url' :
type : string
description : The link to the URL associated with the post
nullable : true
example : 'https:\/\/www.independent.co.uk\/news\/world\/europe\/covid-vaccine-novichok-russia-navalny-b1792778.html'
2021-02-06 03:49:02 +00:00
'user' :
type : object
properties :
user :
type : object
properties :
updated :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/user_updated'
2021-02-06 03:49:02 +00:00
bio :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/bio'
2021-02-06 03:49:02 +00:00
admin :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/admin'
2021-02-06 03:49:02 +00:00
preferred_username :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/preferred_username'
2021-02-06 03:49:02 +00:00
deleted :
$ref : '#/components/schemas/deleted'
banned :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/banned'
2021-02-06 03:49:02 +00:00
published :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/published'
2021-02-06 03:49:02 +00:00
matrix_user_id :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/matrix_user_id'
2021-02-06 03:49:02 +00:00
avatar :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/avatar'
2021-02-06 03:49:02 +00:00
id :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/user_id'
2021-02-06 03:49:02 +00:00
actor_id :
$ref : '#/components/schemas/actor_id'
local :
$ref : '#/components/schemas/local'
banner :
$ref : '#/components/schemas/banner'
name :
2021-02-10 13:35:06 +00:00
$ref : '#/components/schemas/user_name'
'user_id' :
description : |-
That user's id number
type : integer
format : int32
example : 77
'user_name' :
type : string
description : The user's username
example : 'griddle'
'user_updated' :
type : string
description : 'The last time this user profile was updated (in [ISO8601 format](https://www.w3.org/TR/NOTE-datetime))'
example : '2021-01-21T16:26:16.285610'
2021-02-16 10:58:06 +00:00
'user_view' :
type : object
properties :
counts :
$ref : '#/components/schemas/counts'
user :
$ref : '#/components/schemas/user'
'users_active_day' :
desciption : Number of 'active' users in the previous 24 hours
type : number
example : 2
'users_active_half_year' :
desciption : Number of 'active' users in the previous six months
type : number
example : 10
'users_active_month' :
desciption : Number of 'active' users in the previous 28 days
type : number
example : 10
'users_active_week' :
description : Number of 'active' users in the previous seven days
type : number
example : 5
2021-02-10 13:35:06 +00:00
'version' :
description : The version of the software running the Lemmy server
type : string
2021-02-17 15:47:42 +00:00
example : '0.9.6'