With IPFS JS when I run this:

const ipfsNode = await IPFS.create();
const addresses = await ipfsNode.swarm.localAddrs();

I get this:

Swarm listening on /ip4/
Swarm listening on /ip4/
Swarm listening on /ip4/

But all of these are local/LAN addresses. How do I get a public ID so that from another node I can connect to this node over the internet like so: jsipfs swarm connect PUBLIC ADDRESS HERE?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.