matrix-js-sdk
matrix-js-sdk copied to clipboard
Add guide how to use this package
Hi, I tried to use this library, but it is absolutely not possible with no any guideline.
Currently i can found only generated SDK API http://matrix-org.github.io/matrix-js-sdk/ that is pretty useless, because does not explain any concepts, any high level library design and does not provide any information about typical use cases.
I tried to implement a trivial scenario where a bot automatically join to any chat and respond with echo. But i have a lot of problems and questions like
- how i can get messages? okay, it looks i have to listen events and filter it by type
m.room.message
- why i don't see any messages? I know that i sent it to bot. Ohh, okay, it looks this SDK can't decrypt it, it make sense, how i can setup cryptography?
- okay, I've installed
olm
and i do(global as any).Olm = olm.default
which is pretty bad design, but how I can setup cryptography from my recovery key?
Finally, i decided to pause my exploration of this SDK, because it have a pretty low quality due to lack of documentation.
Could you provide some guide with:
- SDK high level design explanation
- trivial examples, like "echo client that join invites and answer to ecnrypted messages"