Add Documentation#2
Conversation
topi314
left a comment
There was a problem hiding this comment.
not bad for a start, but I prefer to have tables with field descriptions, feel free to link to https://lavalink.dev for common types
| Response: | ||
|
|
||
| ```json5 | ||
| { | ||
| "type": "normal", | ||
| "tracks": [ | ||
| { | ||
| "encoded": "...", | ||
| "info": "{}", | ||
| "pluginInfo": "{}", | ||
| "userData": "{}" | ||
| } | ||
| ] | ||
| } | ||
| ``` |
There was a problem hiding this comment.
responses should have a table and then a <details> with a json example
Co-authored-by: Toπ <git@topi.wtf>
|
Alright, I've added tables and descriptors for types and their custom objects, as well as wrapped the JSON examples in |
| <details> | ||
| <summary>Example Payload</summary> | ||
|
|
||
| ```json5 | ||
| { | ||
| "type": "normal", | ||
| "tracks": [ | ||
| { | ||
| "encoded":"QAAAjQIAJVJpY2sgQXN0bGV5IC0gTmV2ZXIgR29ubmEgR2l2ZSBZb3UgVXAADlJpY2tBc3RsZXlWRVZPAAAAAAADPCAAC2RRd" | ||
| } | ||
| ] | ||
| } | ||
| ``` | ||
| </details> |
|
Alright, I've tried to make the changes you've asked. |
|
if you solved something feel free to mark it as resolved |
topi314
left a comment
There was a problem hiding this comment.
maybe the following structure would fit better:
- Installation
- API
- Common Types
- Endpoints
- ...
- Events
- ...
| ```json5 | ||
| { | ||
| [ | ||
| { | ||
| "encoded": "QAAAjQIAJVJpY2sgQXN0bGV5IC0gTmV2ZXIgR29ubmEgR2l2ZSBZb3UgVXAADlJpY2tBc3RsZXlWRVZPAAAAAAADPCAAC2RRd" | ||
| } | ||
| ] | ||
| } | ||
| ``` |
There was a problem hiding this comment.
this payload doesn't look correct to me
There was a problem hiding this comment.
I mean, I couldn't figure out how else it wanted the payload. All that worked for me was taking an array of encoded tracks and then converting it directly to JSON
There was a problem hiding this comment.
you showed an object which contains an array, that's not valid json
it shiuld just be an array of objects
|
Update: 👋 I’m still around to work on this. Ideally, I’ll be able to apply your feedback sometime next week. Apologies for the delay |
| ```json5 | ||
| { | ||
| [ | ||
| { | ||
| "encoded": "QAAAjQIAJVJpY2sgQXN0bGV5IC0gTmV2ZXIgR29ubmEgR2l2ZSBZb3UgVXAADlJpY2tBc3RsZXlWRVZPAAAAAAADPCAAC2RRd" | ||
| } | ||
| ] | ||
| } | ||
| ``` |
There was a problem hiding this comment.
you showed an object which contains an array, that's not valid json
it shiuld just be an array of objects
Co-authored-by: Toπ <git@topi.wtf>
|
just as a note, if you resolve something please also resolve the conversation |
Summary
So, this is my attempt at documentation. I mainly attempted to reference the docs for LavaSrc and the SponsorBlock plugin. If there's anything that's incorrect, please feel free to let me know. I'll attempt to correct it.