Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation Searchability #6279

Open
garymoon opened this issue Nov 30, 2024 · 4 comments
Open

Documentation Searchability #6279

garymoon opened this issue Nov 30, 2024 · 4 comments
Labels

Comments

@garymoon
Copy link

Hi DC team,

I'm using @deltachat/napi-jsonrpc. I understand after a little bit of sleuthing that the relevant docs are at https://js.jsonrpc.delta.chat/classes/RawClient.html, but they don't seem to be indexed by Google. If I search for "miscSendMsg" there's only one result from the changelog. As to why this is, nothing jumps out at me from devtools and lighthouse doesn't complain either 🤷‍♂️ Perhaps Google Search Console might provide some insights.

image

There is also a similar problem within the Github org, where if I search for "miscSendMsg" there's again only one result from the changelog. Perhaps generated code and docs could be pushed to their respective repos at build time to aid searchability.

image

Big ups for putting together the cosmos 👾 And thanks for DeltaChat 💙

@link2xt
Copy link
Collaborator

link2xt commented Nov 30, 2024

I'm using @deltachat/napi-jsonrpc.

Not related directly to the issue, but napi-jsonrpc is archived: https://github.com/deltachat/napi-jsonrpc
I suggest that you switch to using @deltachat/jsonrpc-client and @deltachat/stdio-rpc-server directly.
This is what Delta Chat Desktop is using.
You can look at nodejs_stdio_jsonrpc in https://github.com/deltachat-bot/echo/ or https://github.com/link2xt/xdcterm/ for an example.

@garymoon
Copy link
Author

garymoon commented Nov 30, 2024

Thanks @link2xt, I saw that while tracking down the napi docs, but was going to go for an if-it-ain't-broke approach. Bad move? 😅

Edit: Also not directly related, but thanks for https://github.com/link2xt/xdcterm/ 💙 The echo bot was how I found out about the newer api, but it's not a complete enough implementation to give one an idea of the scope of change.

@link2xt
Copy link
Collaborator

link2xt commented Nov 30, 2024

It should be easy to port if you already started with napi, JSON-RPC API is the same. The difference is that stdio approach is simply starting deltachat core as a subprocess and communicates with it over standard input and standard output, while napi runs the core in the same process and requires Node.js addon built with https://napi.rs/.

Every time we tag a new core release, new @deltachat/stdio-rpc-server is published, but https://npm.io/package/@deltachat/napi-jsonrpc is stuck at v0.101.1 published two years ago.

I opened deltachat-bot/echo#72 to remove old examples.

@garymoon
Copy link
Author

Ooooh, thank you for the clarification, I've caught a mistake. I have a project using the go client which takes the stdio approach, and I'd conflated them. I was thinking stdio-rpc-server was a second iteration of the same approach, but I see now I'm wrong. I'll test out and do the upgrade soon, thank you mate 💙

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants