celestiaorg / celestia-app

Celestia consensus node
https://celestiaorg.github.io/celestia-app/
Apache License 2.0
345 stars 292 forks source link

Curls are not working for me. #4032

Closed shaswatsaloni closed 2 hours ago

shaswatsaloni commented 1 week ago

curl --location 'http://:1317/cosmos/bank/v1beta1/balances/celestia1w73c9lh4hc2s4fgrq3t526ggq0yw467xtf4wps' \ --header 'x-cosmos-block-height: 2767245'

I have a archival celestia consensus node setup. But this doesn't seems to be working for me?

But these are working.

curl --location 'http://10.213.56.73:1317/status'

any help would be appreciated.

Thanks, Saloni.

rootulp commented 1 week ago

The IP address is absent from your first command. Does the following command work?

curl --location 'http://10.213.56.73:1317/cosmos/bank/v1beta1/balances/celestia1w73c9lh4hc2s4fgrq3t526ggq0yw467xtf4wps'
--header 'x-cosmos-block-height: 2767245'
rootulp commented 3 days ago

Please re-open if this is still an issue.

shaswatsaloni commented 2 days ago

No, i checked with the IP also, but that doesn't seems to work, Please help me out.

rootulp commented 2 days ago

Can you please provide:

  1. more details on the error you're observing?
  2. more information on the networking between the place you're invoking curl and the archival node?
  3. when you started the consensus node, did you enable the API via --api.enable?
  4. when you started the consensus node, did you override the default API port via --api.address?

A variant of your command works if I use a community API endpoint:

$ curl --location 'https://celestia-rpc.brightlystake.com/api/cosmos/bank/v1beta1/balances/celestia1w73c9lh4hc2s4fgrq3t526ggq0yw467xtf4wps' --header 'x-cosmos-block-height: 2826293'
{
  "balances": [
    {
      "denom": "utia",
      "amount": "52215"
    }
  ],
  "pagination": {
    "next_key": null,
    "total": "1"
  }
}%