Hello, does anyone know if the
--to-files option added to
ipfs add in kubo v0.16 was implemented to ipfs-http-client & js-ipfs?
Because the options list has not been updated on the GitHub doc, hence I’m wondering js-ipfs/FILES.md at master · ipfs/js-ipfs · GitHub
--to-files option has not added to js-ipfs.
I suggest checking out the following blog post about the state of IPFS in JS. Specifically, the section about Go and JS Development Decoupling.
The TL;DR relevant here:
- If you want to control a Kubo node via JS, use the Kubo-specific library js-kubo-rpc-client
(instead of ipfs-http-client). Eventually, this library should add support for
--to-files seeing as it’s part of Kubo’s RPC API.
pomegrante may include this functionality somewhere down the line.
Hope that helps!
Thanks for the reply, the option is indeed mentioned in the Kubo RPC API doc.
One thing I wonder, is the js-kubo-rpc-client currently usable in the same fashion as the ipfs-http-client?
More precisely, can we assume that the Core API is already supported by js-kubo-rpc-client, and that command can be sent the same way, e.g.
I’m asking that because as to what I could read, the work on js-kubo-rpc-client is not finished yet, full integration of core API components not certain, and the doc not written yet.
Thus, given the lack of doc, I could go and wonder that
--to-files would be
toFiles and all the other command be operated as with ipfs-http-client, but if the underlying Regular Files API is not fully operational in the js-kubo-rpc-client then I’ve got an issue.
Same for the MFS files API,Key, Name, and other Core API Components. In that case, I would be forced to stick with ipfs-http-client.
Should be – it is literally a very fresh fork of ipfs-http-client that now Kubo-only and goes its own way (see Create js-kubo-rpc-client library · Issue #9125 · ipfs/kubo · GitHub for timeline and more info).
If you want to see
--to-files implemented in js-kubo-rpc-client sooner than later, PR against GitHub - ipfs/js-kubo-rpc-client: A client library for the Kubo RPC API is welcome.