mirror of
https://github.com/LemmyNet/joinlemmy-site.git
synced 2024-11-22 12:21:16 +00:00
Added links to API reference and HTTP API pages
This commit is contained in:
parent
6ab288526b
commit
941351e6b1
1 changed files with 13 additions and 2 deletions
|
@ -7,17 +7,25 @@ info:
|
||||||
url: https://mastodon.social/@LemmyDev
|
url: https://mastodon.social/@LemmyDev
|
||||||
description: |-
|
description: |-
|
||||||
### About Lemmy
|
### About Lemmy
|
||||||
|
|
||||||
[**Lemmy**](https://github.com/LemmyNet/lemmy) is a decentralized alternative to proprietary link aggregators such as Reddit.
|
[**Lemmy**](https://github.com/LemmyNet/lemmy) is a decentralized alternative to proprietary link aggregators such as Reddit.
|
||||||
|
|
||||||
#### More information...
|
#### More information...
|
||||||
|
|
||||||
- [Install your own server](https://join.lemmy.ml/docs/en/administration/administration.html)
|
- [Install your own server](https://join.lemmy.ml/docs/en/administration/administration.html)
|
||||||
- [API reference](link_here)
|
- [API reference](https://join.lemmy.ml/docs/en/contributing/api_reference.html)
|
||||||
|
- [HTTP API](https://join.lemmy.ml/docs/en/contributing/http_api.html)
|
||||||
|
|
||||||
### How to use this WebSocket API document
|
### How to use this WebSocket API document
|
||||||
|
|
||||||
You can either use it to:
|
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 client).
|
- **Interactively browse the WebSocket API.** Browse the *Channels*, check out the responses and examples (tailor the *PUBLISH* requests to suit with your favorite WebSocket client).
|
||||||
For testing purposes, either [set up your own server](https://join.lemmy.ml/docs/en/administration/administration.html) or use the Enterprise server (*ws://enterprise.lemmy.ml/api/v2/ws*)
|
For testing purposes, either [set up your own server](https://join.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).
|
- **[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).
|
||||||
|
|
||||||
Connect to <code>ws://***host***/api/v2/ws</code> to get started. If the server supports secure connections, you can use `wss://**server**/api/v1/ws`.
|
Connect to <code>ws://***host***/api/v2/ws</code> to get started. If the server supports secure connections, you can use `wss://**server**/api/v1/ws`.
|
||||||
|
|
||||||
#### Testing with websocat
|
#### Testing with websocat
|
||||||
|
|
||||||
For example a simple test using [websocat](https://github.com/vi/websocat) might be:
|
For example a simple test using [websocat](https://github.com/vi/websocat) might be:
|
||||||
|
@ -42,12 +50,15 @@ info:
|
||||||
```
|
```
|
||||||
|
|
||||||
### Structure of this document
|
### Structure of this document
|
||||||
|
|
||||||
- **Channels** - Documents the requests (marked with the PUBLISH button) and responses (marked with SUBSCRIBE) for each endpoint (*channel*)
|
- **Channels** - Documents the requests (marked with the PUBLISH button) and responses (marked with SUBSCRIBE) for each endpoint (*channel*)
|
||||||
- **Servers** - Lists some publicly-accessible test servers
|
- **Servers** - Lists some publicly-accessible test servers
|
||||||
- **Messages** - A summary of the requests and responses (a duplication of the information in **Channels**)
|
- **Messages** - A summary of the requests and responses (a duplication of the information in **Channels**)
|
||||||
- **Schemas** - An alphabetical list of the most commonly accessed data structures in the API.
|
- **Schemas** - An alphabetical list of the most commonly accessed data structures in the API.
|
||||||
|
|
||||||
### The HTTP API
|
### The HTTP API
|
||||||
Lemmy also has an [HTTP API](link_here) which is almost identical to the WebSocket API; however, this WebSocket API is the primary source since it also details the specifics of HTTP API calls.
|
|
||||||
|
Lemmy also has an [HTTP API](https://join.lemmy.ml/docs/en/contributing/http_api.html) which is almost identical to the WebSocket API; however, this WebSocket API is the primary source since it also details the specifics of HTTP API calls.
|
||||||
|
|
||||||
license:
|
license:
|
||||||
name: AGPL
|
name: AGPL
|
||||||
|
|
Loading…
Reference in a new issue