It’s possible request the gateway port to show the files ?
By default the gateway port is 8080, but many gateways change
In this case, they use port 80.
It’s possible to request this port using the ipfs api ?
Can returns something like
Sorry, I didn’t get your question.
Edited. I would like to know if it’s possible request the gateway port with ipfs API.
You can always change the port for the gateway.
So, yes, it’s possible to host a gateway using any port and hence get data from it.
You can request the entire config using
I think the question is not about configuring one’s gateway, but to know on what port connecting to a remote, out-of-our-control getaway.
I have no control over ipfs.infura.io but I know it’s a getaway. Connecting to ipfs.infura.io:8080 gives an error (because it should be port 80). I guess the question is: how can I ask Infura.io to tell me on what port I should connect to it (so it answers “Connect on port 80. The default 8080 won’t work”)?
Thank you,! this works in my local node.
But unfortunally does not work with some remote nodes, like this: https://ipfs.infura.io:5001/api/v0/config/show
They’re probably limiting which parts of the API they expose over the network. In that case, there’s really nothing you can do.